Closed adeturner closed 3 months ago
Not sure if you have already solved this bug, but I am experimenting with a similar setup (custom kafka scale rule connecting to Azure Event Hub with "KafkaEnabled"). I had to add a trigger parameter for tls in my rule to make it work. So my auth section of the rule looks like:
"auth":
[
{
"secretRef": "event-hub-sasl",
"triggerParameter": "sasl"
},
{
"secretRef": "event-hub-sasl-username",
"triggerParameter": "username"
},
{
"secretRef": "event-hub-sasl-password",
"triggerParameter": "password"
},
{
"secretRef": "event-hub-tls",
"triggerParameter": "tls"
}
]
And the value for tls is 'enable'.
Hope this helps, Andreas
This seems resolved, please reopen if it still exists. Closing now.
This issue is a: (mark with an x)
Issue description
Firstly I'd like to say that I'm really excited by the promise of containerapps, and thank you it is taking an excellent direction.
I'm trying to implement a custom scale rule with kafka keda settings against an eventhub with kafka enabled.
My go/librdkafka container starts, polls the topic, writes any events it finds to a blob, loops if there are more events, then exits. It works fine in test.
At deployment time the topic is empty
I hit a side issue - az cli doesnt work with scale rules currently; --scale-rules has disappeared which I reported against https://github.com/microsoft/azure-container-apps/issues/152.
I switched to deployment templates (ARM) reproduced below. Note the "scale" section with "minReplicas=0" and the custom rule.
The template deploys ok, but I'm getting container crash loops.
The logs show the container starting and stopping repeatedly, with no errors as this is expected behaviour when there are no events to process.
My assumption is that it should be waiting for the KEDA to start it up
Checking:
In the JSON View in the portal for the containerapp, the scale settings are visible.
In the JSON View in the portal for the revision, the scale settings are missing
Also in the portal revision page the scale section is empty:
Running
produces mostly expected output but without any scale section at all.
Second side issue: if we can get this to work, maybe we can add some more examples of complex templates to the docs
Steps to reproduce
For anyone following these are the eventhub kafka parameter values:
Expected behavior [What you expected to happen.]
Container deploys and waits for KEDA to start
Actual behavior [What actually happened.]
Crash loop
Screenshots
n/a
Additional context