Question

Difficulty: EasyConfigure Azure Monitor Autoscale Rules and Metrics

A company hosts a web application on an Azure App Service plan that currently runs on 22 instances. You configure an autoscale rule to add 11 instance (scale out) when the average CPU Percentage exceeds 75%75\%. If the CPU load is evenly distributed, the CPU percentage per instance drops to 50%50\% immediately after scaling out to 33 instances. To prevent autoscale flapping, which configuration should you apply for the scale-in rule?

  1. Set the scale-in threshold to 40%40\% CPU Percentage.Answer
  2. B
    Set the scale-in threshold to 60%60\% CPU Percentage.
  3. C
    Set the scale-in threshold to 80%80\% CPU Percentage.
  4. D
    Change the App Service plan tier to Free (F1) to enable automatic scale-in without configuring thresholds.

Answer

Set the scale-in threshold to 40%40\% CPU Percentage.
Setting the scale-in threshold to 40%40\% CPU Percentage prevents flapping. Since the CPU percentage drops to 50%50\% immediately after scaling out to 33 instances, the scale-in threshold must be lower than 50%50\% (e.g., 40%40\%) so that the newly added instance is not immediately removed.

Step-by-Step Solution

1
Determine the CPU level immediately after the scale-out event.
The CPU level drops to 50%50\% per instance when a third instance is added.
To analyze when the scale-in rule might trigger relative to the scale-out outcome.
2
Compare the potential scale-in thresholds with the post-scale-out CPU level.
A scale-in threshold of 40%40\% is below 50%50\%, whereas 60%60\% and 80%80\% are above 50%50\%.
If the scale-in threshold is higher than or equal to the post-scale-out level, the system will immediately scale back in.
3
Select the threshold that ensures the system does not immediately trigger scale-in.
The 40%40\% threshold prevents immediate scale-in.
This avoids flapping by ensuring a buffer exists between the post-scale-out state and the scale-in trigger.

Key Concept

Autoscale flapping occurs when a scale action causes the metric to cross the threshold for the opposite scale action, triggering a continuous cycle of scaling up and down.
Rate this question