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

Remove Affinity Group dependency on owner ref #240

Closed
vignesh-goutham opened this issue May 5, 2023 · 1 comment · Fixed by #286
Closed

Remove Affinity Group dependency on owner ref #240

vignesh-goutham opened this issue May 5, 2023 · 1 comment · Fixed by #286
Labels
kind/bug Categorizes issue or PR as related to a bug.

Comments

@vignesh-goutham
Copy link
Contributor

vignesh-goutham commented May 5, 2023

/kind bug

Cloudstack machine spec accepts affinity group in two ways.

  1. Managed way where we can just say pro or anti and CAPC will create an affinity group accordingly for each node group. Ex. for KCP, Etcd, and each worker node group.
  2. Provide an already created list of affinity group IDs

In the managed way, CAPC gets the owner ref of CAPI machine and uses the owner name to identify and generate a unique name per node group. While this would work in most situations, owner ref of CAPI machines is not a solid or strict API spec to identify the node role or node group. For instance, ETCD machines can be owned by etcdamd controller, but when the controller chooses to delete old machines, it simply removes its ownership, at which point, CAPI cluster owns those old etcd machines.

An intermediary API that is responsible to track node roles along with affinity or anti-affinity status should be established from which affinity group names should be generated. This API should derive the affinity details during KCP/Cluster creation time.

@rohityadavcloud
Copy link
Member

Fixed by #286 cc @vignesh-goutham pl review and test, thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants