We know that the default cooldown period is 5 mins for scaling policlies. And AWS docs says:
After the cooldown period ends, any scaling activities initiated by simple scaling policies can resume
But I don’t quite the the idea how cooldown period prevents unnessarey scale activities for ASG. Let’s say I have two scaling policies, the first policy is to scale-out one EC2 instance when average CPU usage is great than 50% and the second scaling policy is to scale-out one EC2 instance when average RAM usage is great than 50%.
When the target group of EC2 instance is under stress, let’s CPU usage spike first then memory usage spike after. So the first scaling activity (CPU usage is great than 50%) initiated , then the second activity initiated (RAM usage is great than 50%).
According to the AWS docs, when the first scaling activity is in effect, ASG scale-out one EC2 instance and comes into cooldown period, so even second scaling activity arrives, ASG would suspend it. After 5 mins, second scaling activity is resumed
Here is the thing I probably only need one extra EC2 instance to make average CPU and memory usage stabilized, but now there are 2 EC2 instances created, cooldown period of 5 mins just delay the scale-out of the second EC2 instance after 5 mins. But what I want is the second scaling activity to be cancelled after the cooldown period, not “resumed” after cooldown period?