Skip to content

Commit 8bccba1

Browse files
author
Jan Lindström
committed
MDEV-30465 : Galera test galera_sr.MDEV-27615 takes 5mins
After d7d3ad6 we should use KILL_CONNECTION_HARD to interrupt debug_sync waits. Test case uses debug_sync and then disconnects connection from cluster.
1 parent 2ba6f3d commit 8bccba1

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

sql/wsrep_mysqld.cc

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2795,7 +2795,9 @@ static my_bool have_client_connections(THD *thd, void*)
27952795
{
27962796
DBUG_PRINT("quit",("Informing thread %lld that it's time to die",
27972797
(longlong) thd->thread_id));
2798-
if (is_client_connection(thd) && thd->killed == KILL_CONNECTION)
2798+
if (is_client_connection(thd) &&
2799+
(thd->killed == KILL_CONNECTION ||
2800+
thd->killed == KILL_CONNECTION_HARD))
27992801
{
28002802
WSREP_DEBUG("Informing thread %lld that it's time to die",
28012803
thd->thread_id);
@@ -2807,7 +2809,7 @@ static my_bool have_client_connections(THD *thd, void*)
28072809

28082810
static void wsrep_close_thread(THD *thd)
28092811
{
2810-
thd->set_killed(KILL_CONNECTION);
2812+
thd->set_killed(KILL_CONNECTION_HARD);
28112813
MYSQL_CALLBACK(thread_scheduler, post_kill_notification, (thd));
28122814
mysql_mutex_lock(&thd->LOCK_thd_kill);
28132815
thd->abort_current_cond_wait(true);
@@ -2843,13 +2845,13 @@ static my_bool kill_all_threads(THD *thd, THD *caller_thd)
28432845
if (is_client_connection(thd) && thd != caller_thd)
28442846
{
28452847
if (is_replaying_connection(thd))
2846-
thd->set_killed(KILL_CONNECTION);
2848+
thd->set_killed(KILL_CONNECTION_HARD);
28472849
else if (!abort_replicated(thd))
28482850
{
28492851
/* replicated transactions must be skipped */
28502852
WSREP_DEBUG("closing connection %lld", (longlong) thd->thread_id);
28512853
/* instead of wsrep_close_thread() we do now soft kill by THD::awake */
2852-
thd->awake(KILL_CONNECTION);
2854+
thd->awake(KILL_CONNECTION_HARD);
28532855
}
28542856
}
28552857
return 0;

0 commit comments

Comments
 (0)