Skip to content

Commit 0165a06

Browse files
Leandro PachecoJan Lindström
authored andcommitted
result of wsrep logic in queue_for_group_commit was being ignored
This could cause out of order wsrep checkpoints due wsrep specific leader code not being executed in `MYSQL_BIN_LOG::write_transaction_to_binlog_events`. Move original result assignment to before wsrep logic to prevent that. Reviewed-by: Jan Lindström <jan.lindstrom@mariadb.com>
1 parent ca2ea4f commit 0165a06

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

sql/log.cc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7768,6 +7768,8 @@ MYSQL_BIN_LOG::queue_for_group_commit(group_commit_entry *orig_entry)
77687768
cur= entry->thd->wait_for_commit_ptr;
77697769
}
77707770

7771+
result= orig_queue == NULL;
7772+
77717773
#ifdef WITH_WSREP
77727774
if (wsrep_is_active(entry->thd) &&
77737775
wsrep_run_commit_hook(entry->thd, entry->all))
@@ -7791,7 +7793,6 @@ MYSQL_BIN_LOG::queue_for_group_commit(group_commit_entry *orig_entry)
77917793

77927794
DBUG_PRINT("info", ("Queued for group commit as %s",
77937795
(orig_queue == NULL) ? "leader" : "participant"));
7794-
result= orig_queue == NULL;
77957796

77967797
end:
77977798
if (backup_lock_released)

0 commit comments

Comments
 (0)