question

JohnB-6622 avatar image
0 Votes"
JohnB-6622 asked ·

Need help configuring webjob autoscale rule based on service bus queue length

I'd like to set up an autoscale rule that is basically:

"For each 50 messages in the service bus queue, have one instance of our webjob up until we have 10 max instances."

I'm looking at the UI for this in Azure and I can't make heads or tails out of it.

69744-image.png

Is this type of rule possible?



Thanks!

azure-webapps-webjobs
image.png (80.2 KiB)
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

ryanchill avatar image
0 Votes"
ryanchill answered ·

Hi @JohnB-6622,

I don't see Messages Processed/instance (avg) metric listed on https://docs.microsoft.com/en-us/azure/service-bus-messaging/service-bus-metrics-azure-monitor#message-metrics. Therefore, I'm not sure what type of messages (e.g. scheduled, deferred, scheduled) would be included. If you use this metric, you may find your scaling not behaving as expected.

I will reach out to the product for further clarification and update the doc as necessary, but I would advise sticking with the metrics that are documented to determine your auto scaling rules and the using graphs as indicator. With regards to your rule in question, I would recommend starting with Active Message average as a guide for increasing your instance count. You may have to tweak your targets as the average count could be spread across all instances.

Regards,
Ryan


· 1 ·
10 |1000 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Great, thanks Ryan. I have a support ticket open as well. I think the issue is that I'm seeing different options than everyone else, apparently.

JB

0 Votes 0 ·