feat: collector-based rule_matched_nodes and typed failure reasons - #286
feat: collector-based rule_matched_nodes and typed failure reasons#286rawadhossain wants to merge 2 commits into
Conversation
✅ Deploy Preview for node-readiness-controller ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
Hi @rawadhossain. Thanks for your PR. I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with Regular contributors should join the org to skip this step. Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
406dde6 to
11900ae
Compare
AvineshTripathi
left a comment
There was a problem hiding this comment.
Thanks for the PR! Left a few comments.
11900ae to
12ab0d9
Compare
|
@AvineshTripathi PTAL. I'll commit the changes once you approve. |
|
@rawadhossain I left one comment PHAL and maybe remove the Bootstrap duration metrics till we merge #224 |
12ab0d9 to
8fcbeca
Compare
8fcbeca to
3051634
Compare
|
@AvineshTripathi I have made the changes. PTAL. |
|
/ok-to-test |
|
/lgtm cc @ajaysundark for final look |
|
updated the description. Thanks. |
|
/lgtm /assign @ajaysundark |
db7d7e2 to
4bc164e
Compare
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: rawadhossain The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
4bc164e to
0034c33
Compare
|
@rawadhossain can you please resolve the conflicts? |
0034c33 to
aa9c0a4
Compare
|
@AvineshTripathi resolved the conflicts. GitHub was down for quite a while 😥 |
|
@ajaysundark if everything looks right here, can we get it merged? |
aa9c0a4 to
4ea706d
Compare
|
@ajaysundark made the changes based on scrape time collector and updated the description. Could we get #431 |
|
@ajaysundark made the adjustments here after 431 landed. I think this should be good to merge. |
|
/lgtm |
4ab42a3 to
5278d1d
Compare
|
New changes are detected. LGTM label has been removed. |
| } | ||
| } | ||
|
|
||
| matched, err := c.lister.ListRuleMatchedNodes(ctx, nodes, rules) |
There was a problem hiding this comment.
@rawadhossain Could you check if we are scraping these metrics as a single-pass instead of scraping the cache individually for each of these scrape time metrics?
There was a problem hiding this comment.
Yeah, checked it. All three scrape time metrics scrape the node and rule cache only once, not three individual cache reads. Also tested it on a live cluster to double check, and everything matched up correctly.
Description
Adds
node_readiness_rule_matched_nodesmetric to the scrape-time collector pattern introduced in #398.The metric is computed on each scrape from the cached Node list, sharing the same snapshot as
node_readiness_rule_nodes. Dry-run and deleting rules are also included.(exisitng)
node_readiness_failures_total(new reason:AnnotationPatchFailed)Also adds
AnnotationPatchFailedas a new reason for the existingnode_readiness_failures_totalmetric. Tracks failures when writing the bootstrap-completion annotation, keeping all failure reporting under the existingfailures_totalcounter.Changes
node_readiness_rule_matched_nodesto the scrape-timeReadinessCollector.node_readiness_rule_nodes.AnnotationPatchFailedtonode_readiness_failures_total.EvaluationError,AddTaintError,RemoveTaintError,AnnotationPatchFailed) are now defined as a type with named constants.Related to #397
Type of Change
/kind feature
Testing
make test,make lint,go test ./... -raceall passChecklist
make testpassesmake lintpasses