1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

MDEV-33655 Remove alter_algorithm

Remove alter_algorithm but keep the variable as no-op (with a warning).

The reasons for removing alter_algorithm are:
- alter_algorithm was introduced as a replacement for the
  old_alter_table that was used to force the usage of the original
  alter table algorithm (copy) in the cases where the new alter
  algorithm did not work. The new option was added as a way to force
  the usage of a specific algorithm when it should instead have made
  it possible to disable algorithms that would not work for some
  reason.
- alter_algorithm introduced some cases where ALTER TABLE would not
  work without specifying the ALGORITHM=XXX option together with
  ALTER TABLE.
- Having different values of alter_algorithm on master and slave could
  cause slave to stop unexpectedly.
- ALTER TABLE FORCE, as used by mariadb-upgrade, would not always work
  if alter_algorithm was set for the server.
- As part of the MDEV-33449 "improving repair of tables" it become
  clear that alter- algorithm made it harder to provide a better and
  more consistent ALTER TABLE FORCE and REPAIR TABLE and it would be
  better to remove it.
This commit is contained in:
Monty
2024-03-12 13:54:30 +02:00
committed by Sergei Golubchik
parent 6254fcf84a
commit 2464ee758a
58 changed files with 1171 additions and 2205 deletions

View File

@ -405,19 +405,6 @@ update mysql.db set Delete_history_priv='Y' where db like 'test%';
drop table mysql.global_priv;
rename table mysql.global_priv_bak to mysql.global_priv;
--echo #
--echo # MDEV-16735 Upgrades only work if 'alter_algorithm' is 'DEFAULT'
--echo # or 'COPY'. Test that the session value 'DEFAULT' in mysql_upgrade
--echo # properly overrides the potentially incompatible global value.
--echo #
SET GLOBAL alter_algorithm='INPLACE';
SHOW GLOBAL VARIABLES LIKE 'alter_algorithm';
--exec $MYSQL_UPGRADE --force 2>&1
SET GLOBAL alter_algorithm=DEFAULT;
SHOW GLOBAL VARIABLES LIKE 'alter_algorithm';
--remove_file $MYSQLD_DATADIR/mariadb_upgrade_info
--echo # End of 10.3 tests
--source include/switch_to_mysql_user.inc