From 42f99d00eee0023184c6d985fa6f4e7a9717c3d8 Mon Sep 17 00:00:00 2001 From: Teemu Ollakka <teemu.ollakka@galeracluster.com> Date: Wed, 18 Mar 2015 21:17:31 +0200 Subject: [PATCH] codership/mysql-wsrep#67 - total order isolation for FLUSH The following FLUSH commands are now executed under total order isolation: * FLUSH DES_KEY_FILE * FLUSH HOSTS * FLUSH PRIVILEGES * FLUSH QUERY CACHE * FLUSH STATUS * FLUSH USER_RESOURCES This patch was backported from mysql-wsrep/5.6 commit cdea608d9a27701d76d0deec49976aa0a08b1a56 --- sql/sql_parse.cc | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/sql/sql_parse.cc b/sql/sql_parse.cc index c931a02661..1b965b080e 100644 --- a/sql/sql_parse.cc +++ b/sql/sql_parse.cc @@ -4119,6 +4119,21 @@ end_with_restore_list: break; } +#ifdef WITH_WSREP + if (lex->type & ( + REFRESH_GRANT | + REFRESH_HOSTS | + REFRESH_DES_KEY_FILE | +#ifdef HAVE_QUERY_CACHE + REFRESH_QUERY_CACHE_FREE | +#endif /* HAVE_QUERY_CACHE */ + REFRESH_STATUS | + REFRESH_USER_RESOURCES)) + { + WSREP_TO_ISOLATION_BEGIN(WSREP_MYSQL_DB, NULL, NULL) + } +#endif /* WITH_WSREP*/ + /* reload_acl_and_cache() will tell us if we are allowed to write to the binlog or not. -- 2.30.9