-
Notifications
You must be signed in to change notification settings - Fork 5
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
Refine yawollet health check in keepailved #280
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
timebertt
reviewed
Jan 22, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a few nits
timebertt
changed the title
WIP: Refine Yawollet health check in keepailved
Refine Yawollet health check in keepailved
Jan 22, 2024
timebertt
requested review from
dergeberl,
einfachnuralex and
Kumm-Kai
as code owners
January 22, 2024 13:27
timebertt
previously approved these changes
Jan 22, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
maboehm
changed the title
Refine Yawollet health check in keepailved
Refine yawollet health check in keepailved
Jan 22, 2024
MichaelEischer
approved these changes
Jan 22, 2024
timebertt
previously approved these changes
Jan 22, 2024
timebertt
approved these changes
Jan 22, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Currently, the keepalived priority is influenced by a
track_file
which is supposed to represent that the LBM matches the latest revision. This allows for a rolling update, since all older instances will have a lower priority.However, the track file is not always removed correctly, for example if the yawollet cannot reach the API-Server at all. So this change replaces the file-based check with a health endpoint, which is checked by keepalived via
track_script
. This now covers 3 conditions:The last check is essentially a check if we can reach the API-Server. We could call the
/healthz
endpoint, but that might cause unnecessary load. By checking the conditions that the yawollet should be writing itself, we check both that we can write and read (watch) successfully from the API-Server without causing additional calls.