I am using selenium KEDA for auto-scaling. When I check the HPA logs - it says FAILED to get a Metrics error. Can someone please guide me about the issue here?
Asked
Active
Viewed 151 times
0
-
Can you provide the following commnads output: **kubectl get pod -n custom-metrics, kubectl logs pod/
-n custom-metrics > out.log, kubectl get --raw "/apis/external.metrics.k8s.io", kubectl api-resources | grep -i metric, kubectl get svc -A, kubectl get apiservices | grep metrics.k8s.io.** – Veera Nagireddy May 31 '23 at 13:05 -
Inspect the YAML of the **custom-metrics-stackdriver-adapter**. Check the yaml and image being used and compare it to the OSS YAML and check if you see any differences. If the image is different or older than the OSS YAML, then match the version and try again. Refer to the similar [SO](https://stackoverflow.com/questions/67073909),which may help to resolve your issue. – Veera Nagireddy Jun 01 '23 at 09:10
-
There is no custom-metrics namespace. Everything is under the default namespace. Here the K8s files -> https://github.com/DeepKandey/POMFramework/tree/master/k8s – Deepak Rai Jun 01 '23 at 15:59
1 Answers
0
I was able to solve my issue. The problem was in the selenium graphql URL that I was using in the KEDA scaled object yaml I needed to append the namespace in the URL. And that did the trick.
apiVersion: keda.sh/v1alpha1 kind: ScaledObject metadata: name: selenium-chrome-scaledobject namespace: default labels: deploymentName: selenium-node-chrome spec: minReplicaCount: 0 maxReplicaCount: 8 scaleTargetRef: name: node-chrome-deployment triggers: - type: selenium-grid metadata: url: 'http://selenium-hub.default:4444/graphql' browserName: 'chrome' unsafeSsl : 'true'

Deepak Rai
- 171
- 1
- 1
- 10