-
Alfranio Correia authored
The replication tables had the Master_Id column as the primary key. Despite the suggestive name, it was not supposed to store a server_id which is used to uniquely identify a server, including the master. The column was just an internal identifier. Unfortunately, a bug made the slave's server_id be stored instead of a const number such as "zero" thus causing confusion and leading to this bug report. To fix the problem, we have done what follows: . Made master_host and master_port slave_master_info's primary key. . Renamed slave_relay_log_info's Master_Id to Id. We also had taken the chance to improve the code as follows: . Removed duplicated code from Rpl_info_factory. . Refactored Rpl_info_handler's interface to avoid passing the primary key as parameter in all the functions. . Refactored the code to allow one to redefine the primary keys without changing the code.
Alfranio Correia authoredThe replication tables had the Master_Id column as the primary key. Despite the suggestive name, it was not supposed to store a server_id which is used to uniquely identify a server, including the master. The column was just an internal identifier. Unfortunately, a bug made the slave's server_id be stored instead of a const number such as "zero" thus causing confusion and leading to this bug report. To fix the problem, we have done what follows: . Made master_host and master_port slave_master_info's primary key. . Renamed slave_relay_log_info's Master_Id to Id. We also had taken the chance to improve the code as follows: . Removed duplicated code from Rpl_info_factory. . Refactored Rpl_info_handler's interface to avoid passing the primary key as parameter in all the functions. . Refactored the code to allow one to redefine the primary keys without changing the code.
Loading