diff options
author | Kristian Nielsen <knielsen@knielsen-hq.org> | 2017-04-25 10:01:33 +0200 |
---|---|---|
committer | Kristian Nielsen <knielsen@knielsen-hq.org> | 2017-04-25 10:01:33 +0200 |
commit | 59bab556a04e5945d540ec618a97fa1f818b5d1f (patch) | |
tree | 5233dba0a5830512c4ff2c54c16f2f98cd27b246 /sql/rpl_gtid.cc | |
parent | 89aad233de9371476d9424c7df72d66c37c23e8a (diff) | |
download | mariadb-git-59bab556a04e5945d540ec618a97fa1f818b5d1f.tar.gz |
MDEV-12179: Per-engine mysql.gtid_slave_pos table
Intermediate commit.
Fix record_gtid()'s choice of mysql.gtid_slave_pos* table to only consider
engines that participated in the transaction with write operations (ie.
ignore read-only participation).
Diffstat (limited to 'sql/rpl_gtid.cc')
-rw-r--r-- | sql/rpl_gtid.cc | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sql/rpl_gtid.cc b/sql/rpl_gtid.cc index d0f5694fb5a..83b1b402272 100644 --- a/sql/rpl_gtid.cc +++ b/sql/rpl_gtid.cc @@ -489,8 +489,12 @@ rpl_slave_state::select_gtid_pos_table(THD *thd, LEX_STRING *out_tablename) Ha_trx_info *ha_info= thd->transaction.all.ha_list; while (ha_info) { - void *trx_hton= ha_info->ht(); + void *trx_hton; table_entry= list; + + if (!ha_info->is_trx_read_write()) + continue; + trx_hton= ha_info->ht(); while (table_entry) { if (table_entry->table_hton == trx_hton) |