Which solution will meet these requirements?
Create an Amazon Simple Notification Service (Amazon SNS) topic to send the jobs that need to be processed. Create an Auto Scaling group by using the launch template with the scaling policy set to add and remove EC2 instances based on CPU usage.
Create an Amazon Simple Queue Service (Amazon SQS) queue to hold the jobs that need to be processed. Create an Auto Scaling group by using the launch template with the scaling policy set to add and remove EC2 instances based on network usage.
Create an Amazon Simple Queue Service (Amazon SQS) queue to hold the jobs that need to be processed. Create an Auto Scaling group by using the launch template with the scaling policy set to add and remove EC2 instances based on the number of items in the SQS queue.
Create an Amazon Simple Notification Service (Amazon SNS) topic to send the jobs that need to be processed. Create an Auto Scaling group by using the launch template with the scaling policy set to add and remove EC2 instances based on the number of messages published to the SNS topic.
Explanations:
Amazon SNS is not designed for durable message storage; it pushes messages to subscribers, which may lead to loss if subscribers fail to process them. This does not meet the requirement for durable job storage.
While SQS can hold jobs that need to be processed, using network usage as a scaling policy is not ideal for this scenario. Network usage may not correlate directly with job processing demand, leading to inefficient scaling.
Using SQS allows for durable storage of job items, and an Auto Scaling group based on the number of items in the SQS queue can dynamically adjust the number of EC2 instances needed to process jobs in parallel, effectively meeting the requirement for scalability and loose coupling.
SNS is not designed for durable job storage; it does not queue messages for later processing. Additionally, scaling based on the number of messages published to the SNS topic does not relate to the processing load, making it less effective for this scenario.