It's unclear to me exactly how the underlying AWS Fargate cluster works under the covers.
Does the underlying cluster still scale up and down as needed when the tasks need more instances, and if so, where is that specified?
AWS Fargate, the serverless compute engine for Amazon Elastic Container Service (ECS) and Amazon Elastic Kubernetes Service (EKS), now enables customers to scale applications faster, improving performance and reducing wait time.
Autoscaling is very important to making sure that your services stay online when traffic increases unexpectedly. In both EC2 and AWS Fargate one way to ensure your service autoscales is to increase and decrease the number of copies of your application container that are running in the cluster.
Scaling to zero means you have to boot your container / OS / application, which means any request could time out before it's serviced.
Yes, Application Autoscaling works fine with Fargate.
Using CloudFormation:
AWS::ApplicationAutoScaling::ScalableTarget
and specify for RescoureId
your service/<cluster-name>/<service-name>
AWS::ApplicationAutoScaling::ScalingPolicy
and specify only the ScalingTargetId
(do not declare ScalableDimension
, ServiceNamespace
and RescoureId
)Add it will scale in/out your ECS service
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With