SAA-C03 Question 112
Single answerYou are designing a microservices-based application on AWS. One of the services processes thousands of independent requests daily and does not require storing session data between requests. What is the most appropriate design approach for this service?
- A
Design the service as a stateless workload and use Amazon SQS to decouple request processing.
- B
Design the service as a stateful workload and store session data in Amazon RDS for each request.
- C
Design the service as a stateless workload and use Amazon ElastiCache to store session data temporarily.
- D
Design the service as a stateful workload and use Amazon DynamoDB for session data persistence.
Show answer and explanation
Correct answer: A
Explanation
In a microservices architecture, stateless workloads are preferred for independent requests as they simplify scaling and reduce dependency on external storage for maintaining state. Amazon SQS is an excellent choice to decouple services, enabling asynchronous communication and reliable processing of requests. Stateful designs are unnecessarily complex and costly for this scenario.
- A. Correct.
This is the correct answer. Stateless workloads are ideal for handling independent requests, and Amazon SQS is commonly used to decouple microservices, ensuring scalability and reliability.
- B. Incorrect.
Incorrect. Stateful workloads store session data, which is unnecessary for this scenario as the requests are independent. Using Amazon RDS would add unnecessary complexity and cost.
- C. Incorrect.
Incorrect. While Amazon ElastiCache can store session data temporarily, this approach still introduces statefulness, which is not required for independent requests.
- D. Incorrect.
Incorrect. Using a stateful workload with Amazon DynamoDB would also introduce unnecessary complexity and is not suitable for stateless processing.