Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added replication section to main configuration #46

Merged

Conversation

percona-ysorokin
Copy link
Collaborator

Added 'easymysql::replication_config' class with two fields:

  • 'server_id' - the ID of the MySQL pseudo server that will be send to the server when switching connection to replication mode.
  • 'idle_time' - the number of seconds the utility will wait between reconnection attempts.
    Both parameters can be specified both in JSON configuration file and via command line arguments.
    Sample JSON configuration file ('main_config.json') and 'binlog_streaming.binsrv' MTR test case updated correspondingly.

After this change the replication connection (after reading all available binlog events) will wait for '<connection.read_timeout>' seconds, then will close the connection and will wait for '<replication.idle_time>' seconds before trying to reconnect.

Logging of connection configuration info and replication configuration info moved from the 'main()' into separate functions:

  • 'log_connection_config_info()'
  • 'log_replication_info()'

Added 'easymysql::replication_config' class with two fields:
* 'server_id' - the ID of the MySQL pseudo server that will be send
to the server when switching connection to replication mode.
* 'idle_time' - the number of seconds the utility will wait between
reconnection attempts.
Both parameters can be specified both in JSON configuration file
and via command line arguments.
Sample JSON configuration file ('main_config.json') and
'binlog_streaming.binsrv' MTR test case updated correspondingly.

After this change the replication connection (after reading all available
binlog events) will wait for '<connection.read_timeout>' seconds, then
will close the connection and will wait for '<replication.idle_time>'
seconds before trying to reconnect.

Logging of connection configuration info and replication configuration
info moved from the 'main()' into separate functions:
* 'log_connection_config_info()'
* 'log_replication_info()'
@percona-ysorokin percona-ysorokin merged commit f0f62ef into Percona-Lab:main May 16, 2024
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant