Architecture Design and Implementation Built for the Cloud

A team runs a long-lived HTTP microservice on Amazon ECS with AWS Fargate. It needs three running task replicas and automatic replacement of failed tasks; which deployment approach should it use?

Show the answer

Correct answerC. Create an ECS service with a desired task count of three.

AWhy not this: Scheduled launches do not reconcile running replicas and can create overlapping tasks.

BWhy not this: A capacity provider base controls task placement distribution, not the desired number of service replicas.

CWhy this is right: The ECS service scheduler maintains the desired count and replaces failed tasks.

DWhy not this: Standalone tasks are not automatically replaced to maintain a desired replica count.

An ECS service maintains its desired task count and replaces failed tasks. Standalone tasks can run the application, but they do not provide a service scheduler that maintains three replicas.