fix(health): treat nil return from Lua health status script as n/a instead of unknown#28269
Open
snorwin wants to merge 1 commit into
Open
fix(health): treat nil return from Lua health status script as n/a instead of unknown#28269snorwin wants to merge 1 commit into
snorwin wants to merge 1 commit into
Conversation
✅ Preview Environment deployed on Bunnyshell
See: Environment Details | Pipeline Logs Available commands (reply to this comment):
|
Bundle ReportBundle size has no change ✅ |
…stead of unknown Signed-off-by: Norwin Schnyder <norwin.schnyder+github@gmail.com>
dae1d59 to
90788d6
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #28269 +/- ##
==========================================
- Coverage 64.82% 64.81% -0.02%
==========================================
Files 425 425
Lines 59092 59092
==========================================
- Hits 38306 38299 -7
- Misses 17222 17233 +11
+ Partials 3564 3560 -4 ☔ View full report in Codecov by Harness. |
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.
Custom Lua health check scripts currently have no way to indicate that no health status should apply to a resource. This is extremely useful for generic health checks covering multiple resources in an API group, where some resources shouldn't report a health status at all.
Actual behavior
return nilfrom a Lua health check script results in the resource's health status being reported asUnknown.Expected behavior
return nilshould result in the health status being absent, i.e., equivalent to there being no health check defined for the object.Note: As far as I've checked, none of the currently built-in health check scripts would be affected by this change.
Checklist: