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

Add 'mnesia_table_loading_retry_timeout' and 'mnesia_table_loading_retry_limit' parameter(s) support #1038

Open
alphamonkey79 opened this issue Jan 22, 2025 · 3 comments

Comments

@alphamonkey79
Copy link

alphamonkey79 commented Jan 22, 2025

refs:
rabbit.schema#L1552-L1563

Schema Syncing from Online Peers:

A restarted node will sync the schema and other information from its peers on boot. Before this process completes, the node won't be fully started and functional.
A stopping node picks an online cluster member (only disc nodes will be considered) to sync with after restart. Upon restart the node will try to contact that peer 10 times by default, with 30 second response timeouts.

In case the peer becomes available in that time interval, the node successfully starts, syncs what it needs from the peer and keeps going.

If the peer does not become available, the restarted node will give up and voluntarily stop. Such condition can be identified by the timeout (timeout_waiting_for_tables) warning messages in the logs that eventually lead to node startup failure:

This window of time can be adjusted using two configuration settings:

# wait for 60 seconds instead of 30
mnesia_table_loading_retry_timeout = 60000

# retry 15 times instead of 10
mnesia_table_loading_retry_limit = 15

By adjusting these settings and tweaking the time window in which known peer has to come back it is possible to account for cluster-wide redeployment scenarios that can be longer than 5 minutes to complete.

@alphamonkey79 alphamonkey79 changed the title Add 'mnesia_table_loading' parameter(s) support Add 'mnesia_table_loading_retry_timeout' and 'mnesia_table_loading_retry_limit' parameter(s) support Jan 22, 2025
@wyardley
Copy link
Contributor

Are these settings that can be set via config_variables?

@alphamonkey79
Copy link
Author

@wyardley
I believe so.
Found these references in source:
https://github.com/rabbitmq/rabbitmq-server/blob/2f89bd91227cfbdf4a2024a4414cb3b93607bf69/deps/rabbit/priv/schema/rabbit.schema#L1552-L1563

I am working on a PR for adding and testing that functionality.

alphamonkey79 added a commit to alphamonkey79/puppet-rabbitmq that referenced this issue Jan 23, 2025
@wyardley
Copy link
Contributor

Sounds great! You answered my next question 😉

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

No branches or pull requests

2 participants