Repository navigation
fix: Report no healthy backends instead of an invalid rule - #1138
Merged
Merged
Conversation
A FailClosed rule whose every backend lacks a current Healthy probe result is not loaded, and its per-node Programmed condition said InvalidRule. That reason also covers malformed rules, so a tenant could not tell an outage of their backends from a broken rule. NSO surfaces this reason on the network load balancer's Ready condition, where it read as a configuration error. Key changes: - Add errNoHealthyBackends and map it to the NoHealthyBackends reason - Assert the reason in the fail-closed build and gateway tests
3 tasks
The backend health doc said a gateway's Programmed condition stays True for every health reason. A FailClosed rule with no healthy backend is now reported False with NoHealthyBackends and its VIPs are withdrawn. Key changes: - Document the FailClosed case in the backend health status section - Correct the backendProblemReasons comment, which said all are True
4 tasks
The fail-closed build test asserted errNoHealthyBackends for every case that serves nothing. With health filtering disabled the rule fails because health is unavailable, not because no backend is healthy, so it reports a different error. Key changes: - Expect errNoHealthyBackends only when health filtering is applied
kevwilliams
approved these changes
Oct 27, 2026
kevwilliams
left a comment
There was a problem hiding this comment.
Verified backendSelectionError unwraps to errNoHealthyBackends so programmedCondition matches it, and the withdraw-and-recover test now asserts the NoHealthyBackends reason.
privateip
approved these changes
Oct 27, 2026
This file contains hidden or 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
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.
Summary
When health checks take every backend of a fail-closed service out of rotation, the gateway reported the rule as invalid, the same reason a malformed rule gets.
A load balancer whose only backend went down told its owner the configuration was broken.
The gateway now reports that no backend is healthy in that case, and other rule errors keep their reason.
Test plan
Related to datum-cloud/network-services-operator#722
Related to datum-cloud/network-services-operator#755
Related to datum-cloud/network-services-operator#718