- Le plus récent
- Le plus de votes
- La plupart des commentaires
i will suggest you check your AWS CloudWatch Alarms because auto-scaling behavior is often triggered by CloudWatch alarms. If there are any alarms set up based on CPU usage, they might be scaling your service. Also you could refer to this AWS documentation https://docs.aws.amazon.com/AmazonECS/latest/developerguide/troubleshoot-service-auto-scaling.html to better troubleshoot your issue
Hope it clarifies and if it does I would appreciate answer to be accepted so that community can benefit for clarity, thanks ;)
Sometimes, Fargate tasks need to be replaced spontaneously. This can happen due to several causes:
- An underlying hardware degradation has occurred, and so the task must be migrated to a replacement instance
- To ensure customers are secure, we must periodically apply patches to the underlying hardware, OS, and/or container runtime. Sometimes these require tasks to be migrated to a replacement instance or restarted.
Fargate will make every effort to respect your service's deployment rules, so one thing you can do is to set your deployment configuration's maximumPercent to 100, and set its minimumHealthyPercent to 0. However, this is not a completely safe solution, as there are still situations in which more than one task could be running. For so-called singleton services such as yours, we strongly advise customers to employ a distributed lock (basically, a mutex shared across different tasks) so that only one task is able to process work simultaneously. An inexpensive distributed lock pattern that uses DynamoDB can be found here. Redis, via AWS ElastiCache, can also be used to implement a distributed lock.
Thanks, I'll add the percentage config and look into setting up a lock.
Contenus pertinents
- demandé il y a un an
- demandé il y a 9 mois
- AWS OFFICIELA mis à jour il y a 2 ans
- AWS OFFICIELA mis à jour il y a 9 mois
- AWS OFFICIELA mis à jour il y a 2 ans
Good suggestion, but there are no alarms configured for this service.