Home > Enterprise >  Configure Azure App Service Automatic Scaling based on incoming traffic
Configure Azure App Service Automatic Scaling based on incoming traffic

Time:03-16

We are trying to use elastic scale feature of Azure App service which is automatically scale out the number of running instances of your application to keep up with the flow of incoming HTTP requests, and automatically scale in your application by reducing the number of running instances when incoming request traffic slows down. Below is the Azure CLI command.

az resource update -g <<resource group name>> -n <<app service plan name>> --set properties.ElasticScaleEnabled=1 --resource-type Microsoft.Web/serverfarms

Now the question is, do we have any specific number for incoming traffic like after how many incoming requests its deciding to add more instances or remove instances? Is this something that we can configure or control on our end?

CodePudding user response:

According to this article, I would understand that the scaling decisions are taken by the service and cannot be influenced by the user. If you want to have more fine-grained control, you can use the classical AppService AutoScaling.

CodePudding user response:

how many incoming requests its deciding to add more instances or remove instances?

Configure the Autoscale setting for an app service for autoscaling:

Open the Autoscale blade in Azure Monitor and select a resource that you want to scale.

Provide a name for the scale setting, and then click Add a rule.

By default, this sets the option to scale your instance count by 1 if the CPU percentage of the resource exceeds 70 percent But not based upon the number of incoming requests.

Its Always recommended to use a scale-out and scale-in rule combination that performs an increase and decrease.

If you use only one part of the combination, autoscale will only take action in a single direction (scale out, or in) until it reaches the maximum, or minimum instance counts.

This is not optimal, ideally you want your resource to scale up at times of high usage to ensure availability. Similarly, at times of low usage you want your resource to scale down, so you can realize cost savings.

Please refer this Document to know more about Autoscaling.

  • Related