1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

MDEV-15794 Fix and re-enable test galera_var_retry_autocommit

The test was not deterministic and would occasionally fail, due to the
use of `sleep`.
This patch is a complete rewrite of the test using proper sync points.
This commit is contained in:
Daniele Sciascia
2018-04-26 12:56:24 +02:00
parent dc0613edc4
commit 58c03e8f30
4 changed files with 165 additions and 93 deletions

View File

@ -7187,6 +7187,15 @@ static void wsrep_mysql_parse(THD *thd, char *rawbuf, uint length,
com_statement_info[thd->get_command()].m_key);
MYSQL_SET_STATEMENT_TEXT(thd->m_statement_psi, thd->query(),
thd->query_length());
DBUG_EXECUTE_IF("sync.wsrep_retry_autocommit",
{
const char act[]=
"now "
"SIGNAL wsrep_retry_autocommit_reached "
"WAIT_FOR wsrep_retry_autocommit_continue";
DBUG_ASSERT(!debug_sync_set_action(thd, STRING_WITH_LEN(act)));
});
}
mysql_parse(thd, rawbuf, length, parser_state);