Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃悰 Add reconciler watch for when pool capacity becomes available #253

Merged

Conversation

flawedmatrix
Copy link
Contributor

What this PR does / why we need it:
This PR adds a watch to the IPAddressClaim reconciler to allow it to progress claims that are still waiting for an available IP address when free addresses become available in the pool. It accomplishes this by adding a predicate only in the case where Free addresses in the Pool status are increased from 0.

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #179

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels May 11, 2024
@flawedmatrix flawedmatrix force-pushed the trigger-stuck-claims-on-deletes branch from 17193ac to 87185c3 Compare May 11, 2024 00:50

// Sleep 5 seconds to give the reconciler time to stop retrying
// on the newly created claim.
time.Sleep(5 * time.Second)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not ideal, but I guess there is no other way

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah I didn't want to add this either but it wouldn't reproduce the issue otherwise.

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: flawedmatrix, schrej

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:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label May 15, 2024
@schrej
Copy link
Member

schrej commented May 21, 2024

Will need to be rebased after #250 is in for the tests to pass.

And explicitly do not check return value in test function deleteClaimUnchecked

Signed-off-by: Edwin Xie <[email protected]>
@flawedmatrix flawedmatrix force-pushed the trigger-stuck-claims-on-deletes branch from 9316cfc to 794ebb2 Compare May 22, 2024 20:25
@schrej
Copy link
Member

schrej commented May 23, 2024

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label May 23, 2024
@k8s-ci-robot k8s-ci-robot merged commit 1a00921 into kubernetes-sigs:main May 23, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
3 participants