Description:
On the performance schema table, replication_connection_status, the field that shows the received transactions sometimes shows garbage.
This happens after executing a reset slave all and a change master, right before the slave start.
On this point, the user can check the table, but replication is not yet start so it's fields should be empty.
How to repeat:
Run the following test:
--source include/master-slave.inc
connection master;
create table test.t1(a int) engine=innodb;
insert into test.t1 values (1);
sync_slave_with_master;
query_vertical SELECT * FROM performance_schema.replication_connection_status;
--source include/stop_slave.inc
RESET SLAVE ALL;
--disable_query_log
eval CHANGE MASTER TO MASTER_USER='root', MASTER_CONNECT_RETRY=1, MASTER_HOST='127.0.0.1', MASTER_PORT=$MASTER_MYPORT;
--enable_query_log
query_vertical SELECT * FROM performance_schema.replication_connection_status;
--source include/start_slave.inc
connection master;
DROP TABLE t1;
sync_slave_with_master;
--source include/rpl_end.inc
Suggested fix:
Look for possible unclean structures and improve the test for detecting if the retrieved GITD set is empty or not.
AFAIK, this condition:
if ((m_row.received_transaction_set_length=
io_gtid_set->to_string(&m_row.received_transaction_set)) < 0)
{
is not met on this case.
Description: On the performance schema table, replication_connection_status, the field that shows the received transactions sometimes shows garbage. This happens after executing a reset slave all and a change master, right before the slave start. On this point, the user can check the table, but replication is not yet start so it's fields should be empty. How to repeat: Run the following test: --source include/master-slave.inc connection master; create table test.t1(a int) engine=innodb; insert into test.t1 values (1); sync_slave_with_master; query_vertical SELECT * FROM performance_schema.replication_connection_status; --source include/stop_slave.inc RESET SLAVE ALL; --disable_query_log eval CHANGE MASTER TO MASTER_USER='root', MASTER_CONNECT_RETRY=1, MASTER_HOST='127.0.0.1', MASTER_PORT=$MASTER_MYPORT; --enable_query_log query_vertical SELECT * FROM performance_schema.replication_connection_status; --source include/start_slave.inc connection master; DROP TABLE t1; sync_slave_with_master; --source include/rpl_end.inc Suggested fix: Look for possible unclean structures and improve the test for detecting if the retrieved GITD set is empty or not. AFAIK, this condition: if ((m_row.received_transaction_set_length= io_gtid_set->to_string(&m_row.received_transaction_set)) < 0) { is not met on this case.