Details
-
Bug
-
Status: Closed (View Workflow)
-
Critical
-
Resolution: Fixed
-
10.3.4
-
None
-
bb-10.3-temporal ea49441c41
Description
system_versioning_alter_history should either be GLOBAL-only, or be included into binlog events.
ALTER TABLE for a versioned table can now break replication too easily, since system_versioning_alter_history can be changed by any user in a session (of course, not any user is allowed to ALTER a table, but still). Given the obvious effect that it has on replication, I think the value should be either included into the binary log, or only be modifiable globally. It would still break replication if it's modified globally, but the exposure would be not that big.
The test case is obvious:
--source include/master-slave.inc
|
|
create or replace table t1 (a int) with system versioning; |
set system_versioning_alter_history= KEEP; |
alter table t1 add column b int; |
--sync_slave_with_master
|
|
# Cleanup
|
--connection master
|
drop table t1; |
--source include/rpl_end.inc |
Last_Errno 4118
|
Last_Error Error 'Not allowed for system-versioned `test`.`t1`. Change @@system_versioning_alter_history to proceed with ALTER.' on query. Default database: 'test'. Query: 'alter table t1 add column b int'
|
Attachments
Issue Links
- relates to
-
MDEV-16877 system_versioning_alter_history with galera corruption
- Closed
-
MDEV-24273 System versioning replication fails when adding column on master
- Closed