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

Support labelSelectorPath for Etcd scale sub-resource #814

Open
shreyas-s-rao opened this issue Jun 24, 2024 · 0 comments
Open

Support labelSelectorPath for Etcd scale sub-resource #814

shreyas-s-rao opened this issue Jun 24, 2024 · 0 comments
Labels
area/usability Usability related kind/enhancement Enhancement, improvement, extension

Comments

@shreyas-s-rao
Copy link
Contributor

How to categorize this issue?

/area usability
/kind enhancement

What would you like to be added:

Etcd scale sub-resource should also define labelSelectorPath, to allow for selection of pods managed by the Etcd resource, such that autoscalers like HPA and VPA can directly work with Etcd resources.

Why is this needed:

With #777, scale sub-resource was re-introduced for the Etcd resource. But this only includes specReplicasPath and statusReplicasPath, but not labelSelectorPath. The reason for this was that the field that labelSelectorPath points to must have a serialised key-value string for the matching labels, and a complex LabelSelector struct/map will not work. While Etcd resource does have a status.labelSelector field, this is also a LabelSelector object, and not a serialised string of key-value pairs of matching labels, so it would not work for the scale sub-resource. The same holds true for spec.selector as well. Additionally, the spec may not always represent the current state of the etcd cluster, so any changes to the label selector in the spec that have not yet been reconciled by druid, would lead to errors when selecting pods matching the new label selector.

Finally, not defining the labelSelectorPath means that while we can now scale the etcd replicas using the scale sub-resource, via kubectl scale command, we still don't provide support for autoscalers like HPA and VPA to operate on the Etcd resource directly, since these require the labelSelectorPath to be defined for the scale sub-resource, in order to select the pods managed by the Etcd, and gather metrics for those pods and take horizontal/vertical scaling decisions based on those metrics.

@gardener-robot gardener-robot added area/usability Usability related kind/enhancement Enhancement, improvement, extension labels Jun 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/usability Usability related kind/enhancement Enhancement, improvement, extension
Projects
None yet
Development

No branches or pull requests

2 participants