summaryrefslogtreecommitdiff
path: root/mysql-test/suite/innodb/t/innodb-alter.test
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2020-11-10 17:21:16 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2020-11-11 11:15:11 +0200
commit9bc874a594edbc0e124131d0ff30b44f5fade52d (patch)
tree38fd225df9573771fe967174e07151721663b3cd /mysql-test/suite/innodb/t/innodb-alter.test
parentc498250888ec126fddda2867d1239b2a7734482f (diff)
downloadmariadb-git-9bc874a594edbc0e124131d0ff30b44f5fade52d.tar.gz
MDEV-23497 Make ROW_FORMAT=COMPRESSED read-only by default
Let us introduce the parameter innodb_read_only_compressed that is ON by default, making any ROW_FORMAT=COMPRESSED tables read-only. I developed the ROW_FORMAT=COMPRESSED format based on Heikki Tuuri's rough design between 2005 and 2008. It might have been a good idea back then, but no proper benchmarks were ever run to validate the design or the implementation. The format has been more or less obsolete for years. It limits innodb_page_size to 16384 bytes (the default), and instant ALTER TABLE is not supported. This is the first step towards deprecating and removing write support for ROW_FORMAT=COMPRESSED tables.
Diffstat (limited to 'mysql-test/suite/innodb/t/innodb-alter.test')
-rw-r--r--mysql-test/suite/innodb/t/innodb-alter.test7
1 files changed, 7 insertions, 0 deletions
diff --git a/mysql-test/suite/innodb/t/innodb-alter.test b/mysql-test/suite/innodb/t/innodb-alter.test
index f72935ebc3c..70174a98d77 100644
--- a/mysql-test/suite/innodb/t/innodb-alter.test
+++ b/mysql-test/suite/innodb/t/innodb-alter.test
@@ -617,6 +617,10 @@ eval DROP DATABASE $dest_db;
--echo # ORPHANED DUE TO RENAME TABLE
--echo #
CREATE DATABASE db1; USE db1;
+--disable_query_log
+SET @save_innodb_read_only_compressed=@@GLOBAL.innodb_read_only_compressed;
+SET GLOBAL innodb_read_only_compressed=OFF;
+--enable_query_log
CREATE TABLE notes (
id int(11) NOT NULL AUTO_INCREMENT,
body text COLLATE utf8_unicode_ci,
@@ -627,6 +631,9 @@ ROW_FORMAT=COMPRESSED;
ALTER TABLE notes ADD FULLTEXT INDEX index_ft_body (body(255));
DROP INDEX index_ft_body ON notes;
+--disable_query_log
+SET GLOBAL innodb_read_only_compressed=@save_innodb_read_only_compressed;
+--enable_query_log
CREATE DATABASE db2;
RENAME TABLE db1.notes TO db2.notes;