[MDEV-574] Multi-source: sync_with_master without the 2nd parameter always attempts to synchronize with connection '', regardless the current default_master_connection Created: 2012-10-04  Updated: 2022-09-08

Status: Open
Project: MariaDB Server
Component/s: None
Fix Version/s: None

Type: Task Priority: Minor
Reporter: Elena Stepanova Assignee: Michael Widenius
Resolution: Unresolved Votes: 0
Labels: None

Issue Links:
Relates

 Description   

sync_with_master, if it's called without the explicit connection name, always attempts to execute master_pos_wait(binlog, position, timeout, ''), even if default_master_connection is set to something other than ''. It causes the command and the entire test fail if there is no '' connection, and can lead to more subtle problems if there is the connection, since the synchronization won't work as expected.

10.0-base revno 3438

Test case (you need to pull the revision as mentioned above to run the test, since it uses the new include file only introduced in this revision):

--connect (slave,127.0.0.1,root,,,$SERVER_MYPORT_3)
 
set default_master_connection = 'm1';
 
--replace_result $SERVER_MYPORT_1 MYPORT_1
eval change master to
master_port=$SERVER_MYPORT_1,
master_host='127.0.0.1',
master_user='root';
 
start slave;
--source include/wait_for_slave_to_start.inc
 
--connect (master1,127.0.0.1,root,,,$SERVER_MYPORT_1)
--save_master_pos
 
--connection slave
--sync_with_master
 
# Cleanup
 
--source reset_master_slave.inc
--disconnect slave
 
--connection master1
--source reset_master_slave.inc
--disconnect master1


Generated at Thu Feb 08 06:29:46 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.