medik8s / node-healthcheck-operator

K8s Node Health Check Operator
Apache License 2.0
91 stars 18 forks source link

Fix MHC node lease deletion #287

Closed slintes closed 8 months ago

slintes commented 9 months ago

Delete the node lease when MHC remediation is done

ECOPROJECT-1831

openshift-ci[bot] commented 9 months ago

Skipping CI for Draft Pull Request. If you want CI signal for your change, please convert it to an actual PR. You can still manually trigger a test run with /test all

slintes commented 9 months ago

/test 4.14-openshift-e2e

slintes commented 9 months ago

/test 4.14-openshift-e2e

slintes commented 9 months ago

/test 4.14-openshift-e2e

slintes commented 8 months ago

but I am not sure I undertand how the change in MHC reconcile are resolving the MHC node lease deletion issue

look at the HandleHealthyNode function, whose return values are better evaluated now. It will delete CRs, but only if no CRs are left it will also delete the lease in CleanUp. So we need to reconcile again until all CRs are gone.

openshift-ci[bot] commented 8 months ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: clobrano, slintes

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files: - ~~[OWNERS](https://github.com/medik8s/node-healthcheck-operator/blob/main/OWNERS)~~ [clobrano,slintes] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
clobrano commented 8 months ago

/hold

to let the other threads be closed, feel free to unhold

razo7 commented 8 months ago

So we need to reconcile again until all CRs are gone.

Gotcha, so as long HandleHealthyNode function returns that there are remaining remediation CRs we will requeue reconciliation. On the last time, it would be zero and the lease would be invalidated (from cleanup).

slintes commented 8 months ago

/hold cancel

slintes commented 8 months ago

/test all

razo7 commented 8 months ago

/lgtm

slintes commented 8 months ago

/test all

clobrano commented 8 months ago

/lgtm