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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adapt scale test to not remove HA #56

Merged
merged 5 commits into from
Sep 20, 2024
Merged

Conversation

bschimke95
Copy link
Contributor

@bschimke95 bschimke95 commented Sep 15, 2024

This PR fixes a race condition that pops up if a workload cluster is scaled down. As part of the CK8s node removal, all services are stopped on the leaving node. This includes kubelet which causes the node to be reported as "not available" before the core CAPI controllers attempt to drain the node.

By setting the annotation, we ensure that CAPI takes full control of the nodes removal process.
Note that we could also change the existing skip-node-on-removal annotation but there might be another use-case for just stopping services (+backward-compatibility).

Requires:
canonical/k8s-snap#682
canonical/k8s-snap-api#8

@bschimke95 bschimke95 marked this pull request as ready for review September 18, 2024 19:35
@bschimke95 bschimke95 requested a review from a team as a code owner September 18, 2024 19:35
Copy link
Member

@berkayoz berkayoz left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@HomayoonAlimohammadi HomayoonAlimohammadi left a comment

Choose a reason for hiding this comment

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

Thanks a lot @bschimke95! LGTM

@bschimke95 bschimke95 merged commit 54b8866 into main Sep 20, 2024
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants