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

feat: adds configuration for primary leader node [DHIS2-16878] #17685

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jbee
Copy link
Contributor

@jbee jbee commented Jun 3, 2024

Summary

Adds a new configuration node.primary_leader that when set to true/on the node will unconditionally set itself as the leader (as opposed to only setting its ID when no other value is present). This means (eventually) the node should always take over the leader role in a cluster as all other nodes will only set their ID in case no ID is set. This way other nodes only take over the leader role if the primary leader is in fact not able to renew (maintain) its leader role by setting its ID.

@jbee jbee self-assigned this Jun 3, 2024
Copy link

sonarcloud bot commented Jun 3, 2024

Comment on lines +79 to +80
* When true, the node will unconditionally set its node ID during leader election causing it to
* win the election as long as it is alive.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know this isn't (yet) end user documentation but I would suggest using the word "cluster" somewhere just so that people not concerned with clusters will skip over it faster.

@jbee jbee requested a review from a team June 3, 2024 14:00
@jbee
Copy link
Contributor Author

jbee commented Jun 20, 2024

@jimgrace Any news on the testing of this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
4 participants