Skip to content

Commit de3725a

Browse files
author
Jan Lindström
authored
Merge pull request #654 from codership/MDEV-13549-fixes-for-galera_var_max_ws_rows
MDEV-13549 Fix for test galera.galera_var_max_ws_rows
2 parents 866ddbe + 59c313c commit de3725a

File tree

2 files changed

+0
-34
lines changed

2 files changed

+0
-34
lines changed

mysql-test/suite/galera/disabled.def

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ lp1376747 : MDEV-13549 Galera test failures
4444
galera_toi_ddl_nonconflicting : MDEV-13549 Galera test failures
4545
galera_parallel_simple : MDEV-13549 Galera test failures
4646
galera_admin : MDEV-13549 Galera test failures
47-
galera_var_max_ws_rows : MDEV-13549 Galera test failures 10.1
4847
galera_as_master: MDEV-13549 Galera test failures 10.1
4948
galera_pc_ignore_sb : MDEV-13549 Galera test failures 10.1
5049
galera_lock_table : MDEV-13549 Galera test failures 10.1

sql/handler.cc

Lines changed: 0 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -5771,8 +5771,6 @@ static int write_locked_table_maps(THD *thd)
57715771

57725772
typedef bool Log_func(THD*, TABLE*, bool, const uchar*, const uchar*);
57735773

5774-
static int check_wsrep_max_ws_rows();
5775-
57765774
static int binlog_log_row(TABLE* table,
57775775
const uchar *before_record,
57785776
const uchar *after_record,
@@ -5826,13 +5824,6 @@ static int binlog_log_row(TABLE* table,
58265824
bool const has_trans= thd->lex->sql_command == SQLCOM_CREATE_TABLE ||
58275825
table->file->has_transactions();
58285826
error= (*log_func)(thd, table, has_trans, before_record, after_record);
5829-
5830-
/*
5831-
Now that the record has been logged, increment wsrep_affected_rows and
5832-
also check whether its within the allowable limits (wsrep_max_ws_rows).
5833-
*/
5834-
if (error == 0)
5835-
error= check_wsrep_max_ws_rows();
58365827
}
58375828
}
58385829
return error ? HA_ERR_RBR_LOGGING_FAILED : 0;
@@ -5943,30 +5934,6 @@ int handler::ha_reset()
59435934
}
59445935

59455936

5946-
static int check_wsrep_max_ws_rows()
5947-
{
5948-
#ifdef WITH_WSREP
5949-
if (wsrep_max_ws_rows)
5950-
{
5951-
THD *thd= current_thd;
5952-
5953-
if (!WSREP(thd))
5954-
return 0;
5955-
5956-
thd->wsrep_affected_rows++;
5957-
if (thd->wsrep_exec_mode != REPL_RECV &&
5958-
thd->wsrep_affected_rows > wsrep_max_ws_rows)
5959-
{
5960-
trans_rollback_stmt(thd) || trans_rollback(thd);
5961-
my_message(ER_ERROR_DURING_COMMIT, "wsrep_max_ws_rows exceeded", MYF(0));
5962-
return ER_ERROR_DURING_COMMIT;
5963-
}
5964-
}
5965-
#endif /* WITH_WSREP */
5966-
return 0;
5967-
}
5968-
5969-
59705937
int handler::ha_write_row(uchar *buf)
59715938
{
59725939
int error;

0 commit comments

Comments
 (0)