diff options
author | Jan Lindström <jan.lindstrom@mariadb.com> | 2019-03-12 15:44:10 +0200 |
---|---|---|
committer | Jan Lindström <jan.lindstrom@mariadb.com> | 2019-03-13 10:18:12 +0200 |
commit | d0ebb155fe68924848b92cbc0e6f5e9958acdab8 (patch) | |
tree | a61ff9a3604ad91f055dc4e7a9e72fae2cefdbf3 /sql/wsrep_thd.cc | |
parent | 20928e2e960454ff7f9dee0094a464b1a6fdb195 (diff) | |
download | mariadb-git-d0ebb155fe68924848b92cbc0e6f5e9958acdab8.tar.gz |
MDEV-18577: Indexes problem on import dump SQL
Problem was that we skipped background persistent statistics calculation
on applier nodes if thread is marked as high priority (a.k.a BF).
However, on applier nodes all DDL which is replicate will be executed
as high priority i.e BF.
Fixed by allowing background persistent statistics calculation on
applier nodes even when thread is marked as BF. This could lead
BF lock waits but for queries on that node needs that statistics.
Diffstat (limited to 'sql/wsrep_thd.cc')
-rw-r--r-- | sql/wsrep_thd.cc | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/sql/wsrep_thd.cc b/sql/wsrep_thd.cc index a3d1961ade2..dab9f91b381 100644 --- a/sql/wsrep_thd.cc +++ b/sql/wsrep_thd.cc @@ -698,3 +698,13 @@ void wsrep_thd_auto_increment_variables(THD* thd, *increment= thd->variables.auto_increment_increment; } } + +my_bool wsrep_thd_is_applier(MYSQL_THD thd) +{ + my_bool is_applier= false; + + if (thd && thd->wsrep_applier) + is_applier= true; + + return (is_applier); +} |