mariadb/storage/tokudb/mysql-test/tokudb_rpl
Kristian Nielsen 34f11b06e6 Move deletion of old GTID rows to slave background thread
This patch changes how old rows in mysql.gtid_slave_pos* tables are deleted.
Instead of doing it as part of every replicated transaction in
record_gtid(), it is done periodically (every @@gtid_cleanup_batch_size
transaction) in the slave background thread.

This removes the deletion step from the replication process in SQL or worker
threads, which could speed up replication with many small transactions. It
also decreases contention on the global mutex LOCK_slave_state. And it
simplifies the logic, eg. when a replicated transaction fails after having
deleted old rows.

With this patch, the deletion of old GTID rows happens asynchroneously and
slightly non-deterministic. Thus the number of old rows in
mysql.gtid_slave_pos can temporarily exceed @@gtid_cleanup_batch_size. But
all old rows will be deleted eventually after sufficiently many new GTIDs
have been replicated.
2018-12-07 07:10:40 +01:00
..
include Move tokudb_rpl to rpl-tokudb suite 2017-08-03 22:15:19 +03:00
r Move deletion of old GTID rows to slave background thread 2018-12-07 07:10:40 +01:00
t Move deletion of old GTID rows to slave background thread 2018-12-07 07:10:40 +01:00
disabled.def Merge branch '10.0' into 10.1 2016-12-11 09:53:42 +01:00
suite.opt MDEV-10408 run the tokudb_rpl.rpl_rfr_disable_on_expl_pk_absence test. Add control files. Fixup result file for mariadb 2016-11-02 13:45:18 +01:00