summaryrefslogtreecommitdiff
path: root/mysql-test/suite/vcol/t
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2021-08-31 13:55:02 +0300
committerMarko Mäkelä <marko.makela@mariadb.com>2021-08-31 13:55:02 +0300
commit9608773f75e2ca21491ef6825c3616cdc96d1ca5 (patch)
treeec2c4a8d43eb051a395ff1aaa4be06fe345082db /mysql-test/suite/vcol/t
parent45a05fda27dc7058ce8a89f14b1daa56352adf6b (diff)
downloadmariadb-git-9608773f75e2ca21491ef6825c3616cdc96d1ca5.tar.gz
MDEV-4750 follow-up: Reduce disabling innodb_stats_persistent
This essentially reverts commit 4e89ec6692786bc1cbdce64d43d8e85a5d247dab and only disables InnoDB persistent statistics for tests where it is desirable. By design, InnoDB persistent statistics will not be updated except by ANALYZE TABLE or by STATS_AUTO_RECALC. The internal transactions that update persistent InnoDB statistics in background tasks (with innodb_stats_auto_recalc=ON) may cause nondeterministic query plans or interfere with some tests that deal with other InnoDB internals, such as the purge of transaction history.
Diffstat (limited to 'mysql-test/suite/vcol/t')
-rw-r--r--mysql-test/suite/vcol/t/vcol_select_innodb.test4
-rw-r--r--mysql-test/suite/vcol/t/vcol_view_innodb.test4
2 files changed, 8 insertions, 0 deletions
diff --git a/mysql-test/suite/vcol/t/vcol_select_innodb.test b/mysql-test/suite/vcol/t/vcol_select_innodb.test
index 606801a213a..5b04096a5a5 100644
--- a/mysql-test/suite/vcol/t/vcol_select_innodb.test
+++ b/mysql-test/suite/vcol/t/vcol_select_innodb.test
@@ -36,6 +36,8 @@
# Set the session storage engine
--source include/have_innodb.inc
eval SET @@session.default_storage_engine = 'InnoDB';
+SET @save_stats_persistent=@@GLOBAL.innodb_stats_persistent;
+SET GLOBAL innodb_stats_persistent=0;
##### Workarounds for known open engine specific bugs
# none
@@ -47,6 +49,8 @@ eval SET @@session.default_storage_engine = 'InnoDB';
#------------------------------------------------------------------------------#
# Execute storage engine specific tests
+SET GLOBAL innodb_stats_persistent=@save_stats_persistent;
+
#------------------------------------------------------------------------------#
# Cleanup
--source suite/vcol/inc/vcol_cleanup.inc
diff --git a/mysql-test/suite/vcol/t/vcol_view_innodb.test b/mysql-test/suite/vcol/t/vcol_view_innodb.test
index fd77489f5dc..3b869425ecb 100644
--- a/mysql-test/suite/vcol/t/vcol_view_innodb.test
+++ b/mysql-test/suite/vcol/t/vcol_view_innodb.test
@@ -35,6 +35,8 @@
# Set the session storage engine
--source include/have_innodb.inc
eval SET @@session.default_storage_engine = 'InnoDB';
+SET @save_innodb_stats_persistent=@@GLOBAL.innodb_stats_persistent;
+SET GLOBAL innodb_stats_persistent=0;
##### Workarounds for known open engine specific bugs
# none
@@ -46,6 +48,8 @@ eval SET @@session.default_storage_engine = 'InnoDB';
#------------------------------------------------------------------------------#
# Execute storage engine specific tests
+SET GLOBAL innodb_stats_persistent=@save_innodb_stats_persistent;
+
#------------------------------------------------------------------------------#
# Cleanup
--source suite/vcol/inc/vcol_cleanup.inc