You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
kindPlural := fmt.Sprintf("%ss", strings.ToLower(kind))
This always adds 's' to kind. But in case of CRD resource like logstash, the plural is logstashes and not logstashs. This is causing it to fail
To Reproduce
Steps to reproduce the behavior:
Deploy logstash CRD
Use scaleTargetRef as '{"kind": "Logstash", "name": "logstash", "apiVersion": "logstash.k8s.elastic.co/v1alpha1"}'
See error
Expected behavior
find correct resource
Kubernetes Details (kubectl version):
1.32
The text was updated successfully, but these errors were encountered:
Thanks for raising this - I always knew this was a bit of a hack when it was first implemented but it seemed to work for the use cases I could think of; I'll investigate the correct way of getting the plural kind.
Maybe just simple retry with +"es" when it fails on getting the resource. I am currently working on task where I require this, so probably I will just try to fix it with some hack, but would rather use your image, since I would need to build it completely. I wanted to rewrite that specific file in docker container but then found out its a binary :)
Describe the bug
kindPlural := fmt.Sprintf("%ss", strings.ToLower(kind))
This always adds 's' to kind. But in case of CRD resource like logstash, the plural is logstashes and not logstashs. This is causing it to fail
To Reproduce
Steps to reproduce the behavior:
Expected behavior
find correct resource
Kubernetes Details (
kubectl version
):1.32
The text was updated successfully, but these errors were encountered: