AWS Certified Solutions Architect – Associate (SAA-C03) — Question 773
A company is migrating a legacy application from an on-premises data center to AWS. The application relies on hundreds of cron jobs that run between 1 and 20 minutes on different recurring schedules throughout the day.
The company wants a solution to schedule and run the cron jobs on AWS with minimal refactoring. The solution must support running the cron jobs in response to an event in the future.
Which solution will meet these requirements?
Answer options
- A. Create a container image for the cron jobs. Use Amazon EventBridge Scheduler to create a recurring schedule. Run the cron job tasks as AWS Lambda functions.
- B. Create a container image for the cron jobs. Use AWS Batch on Amazon Elastic Container Service (Amazon ECS) with a scheduling policy to run the cron jobs.
- C. Create a container image for the cron jobs. Use Amazon EventBridge Scheduler to create a recurring schedule. Run the cron job tasks on AWS Fargate.
- D. Create a container image for the cron jobs. Create a workflow in AWS Step Functions that uses a Wait state to run the cron jobs at a specified time. Use the RunTask action to run the cron job tasks on AWS Fargate.
Correct answer: C
Explanation
AWS Fargate is the ideal serverless compute option because some cron jobs execute for up to 20 minutes, which exceeds the 15-minute maximum execution limit of AWS Lambda. Amazon EventBridge Scheduler provides a highly scalable, managed way to trigger these tasks on recurring schedules and handles future one-time events natively. Using AWS Step Functions or AWS Batch for this workload would introduce unnecessary operational complexity and configuration overhead.