I am currently trying to use Keda to start a job after having received an event from Azure Event Hub. When I deploy my scaledjob, I see the message (with kubectl describe):
Warning KEDAScalerFailed 4m29s (x17 over 9m57s) scale-handler unable to get eventhub metadata: no storage connection string given
Here is the scaledjob I’m using, it is from the sample we can find in keda’s website
apiVersion: keda.sh/v1alpha1
kind: ScaledJob
metadata:
name: pi-az-consumer
namespace: default
spec:
jobTargetRef:
template:
spec:
containers:
- name: pi
image: perl:5.34.0
command: ["perl", "-Mbignum=bpi", "-wle", "print bpi(2000)"]
restartPolicy: Never
backoffLimit: 4
pollingInterval: 10 # Optional. Default: 30 seconds
maxReplicaCount: 30 # Optional. Default: 100
successfulJobsHistoryLimit: 3 # Optional. Default: 100. How many completed jobs should be kept.
failedJobsHistoryLimit: 2 # Optional. Default: 100. How many failed jobs should be kept.
scalingStrategy:
strategy: "custom" # Optional. Default: default. Which Scaling Strategy to use.
customScalingQueueLengthDeduction: 1 # Optional. A parameter to optimize custom ScalingStrategy.
customScalingRunningJobPercentage: "0.5" # Optional. A parameter to optimize custom ScalingStrategy.
triggers:
- type: azure-eventhub
metadata:
connectionFromEnv: "Endpoint=sb://{...}.servicebus.windows.net/;SharedAccessKeyName={...};SharedAccessKey={...};EntityPath={...}"
storageConnectionFromEnv: "DefaultEndpointsProtocol=https;AccountName={...};AccountKey={...};EndpointSuffix=core.windows.net"
consumerGroup: $Default
unprocessedEventThreshold: '64'
activationUnprocessedEventThreshold: '10'
blobContainer: '{...}'
From what I’ve found on the internet, the connections are what I should have used. Is the problem with my connections? is it elsewhere?
I was expecting a connection or an authentication error but I do not understand why I am told that I did not give the connection string.
Thank you if you have any idea where the problem can come from, I will be keeping this question updated if I find the answer.
samy mhenni is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.