exam questions

Exam AWS Certified Solutions Architect - Professional All Questions

View all questions & answers for the AWS Certified Solutions Architect - Professional exam

Exam AWS Certified Solutions Architect - Professional topic 1 question 458 discussion

An organization has two Amazon EC2 instances:
✑ The first is running an ordering application and an inventory application.
The second is running a queuing system.

During certain times of the year, several thousand orders are placed per second. Some orders were lost when the queuing system was down. Also, the organization's inventory application has the incorrect quantity of products because some orders were processed twice.
What should be done to ensure that the applications can handle the increasing number of orders?

  • A. Put the ordering and inventory applications into their own AWS Lambda functions. Have the ordering application write the messages into an Amazon SQS FIFO queue.
  • B. Put the ordering and inventory applications into their own Amazon ECS containers, and create an Auto Scaling group for each application. Then, deploy the message queuing server in multiple Availability Zones.
  • C. Put the ordering and inventory applications into their own Amazon EC2 instances, and create an Auto Scaling group for each application. Use Amazon SQS standard queues for the incoming orders, and implement idempotency in the inventory application.
  • D. Put the ordering and inventory applications into their own Amazon EC2 instances. Write the incoming orders to an Amazon Kinesis data stream. Configure AWS Lambda to poll the stream and update the inventory application.
Show Suggested Answer Hide Answer
Suggested Answer: C 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
nitinz
Highly Voted 3 years, 9 months ago
Correct answer is C.
upvoted 28 times
...
Juan21
Highly Voted 3 years, 9 months ago
Correct answer is A. With FIFO you avoid the problem of duplicate processing in the queue.
upvoted 17 times
user0001
3 years, 2 months ago
A is right
upvoted 1 times
...
StelSen
3 years, 8 months ago
To me A is immediate failure. Moving an application from EC2 to lambda without knowing what was the application stack is not a good choice. Although lambda can run simple PHP web application with the help of API GATEWAY, there is no mention of API GAteway, So A failed in this case.
upvoted 2 times
...
student22
3 years, 8 months ago
Answer is C SQS + Idempotency
upvoted 5 times
user0001
3 years, 2 months ago
there is no such thing called Idempotency, it made up here
upvoted 1 times
...
Eric0909
2 years, 11 months ago
Agree! I was rocketMQ prudcut support before.
upvoted 1 times
...
...
hbrand
3 years, 8 months ago
Changing to C I originally thought it was A but seeing this "FIFO queues are different. The ordering imposes a real throughput limit – currently 300 requests per second per queue...Fortunately, our conversations with customers have told us that FIFO applications are generally lower-throughput—10 messages per second or lower." changes mine to C. Sure it can go to 3,000/s with batching but this is not mentioned. Along with this they mention in the question that the orders are in several thousands per second. https://aws.amazon.com/blogs/developer/how-the-amazon-sqs-fifo-api-works/
upvoted 6 times
...
...
marszalekm
Most Recent 1 year, 5 months ago
FIFO supports higher limits now https://aws.amazon.com/about-aws/whats-new/2023/08/amazon-sqs-increased-throughput-quota-fifo-high-throughput-mode/
upvoted 1 times
...
mrgreatness
2 years, 8 months ago
several thousand per second so C
upvoted 1 times
...
mrgreatness
2 years, 8 months ago
C: FIFO queues help you avoid sending duplicates to a queue. If you retry the SendMessage action within the 5-minute deduplication interval, Amazon SQS doesn't introduce any duplicates into the queue.
upvoted 1 times
...
Netaji
2 years, 8 months ago
there is a difference between FIFO and a standard queue of SQS -- https://jayendrapatil.com/aws-sqs-standard-vs-fifo-queue/ so the answer should be "A"
upvoted 1 times
...
superuser784
2 years, 8 months ago
Selected Answer: C
Could be A, but we do not know how long the total process could take (maybe more than 15 min) and the SQS FiFo is not for this use case, the keyword here is "Idempotency" which means you have to build your application making sure you do not process the same message twice. so the correct option is C
upvoted 1 times
...
sg0206
2 years, 8 months ago
A is the correct answer - FIFO Queues High Throughput: By default, FIFO queues support up to 300 messages per second (300 send, receive, or delete operations per second). When you batch 10 messages per operation (maximum), FIFO queues can support up to 3,000 messages per second. If you require higher throughput, you can enable high throughput mode for FIFO on the Amazon SQS console, which will support up to 30,000 messages per second with batching, or up to 3,000 messages per second without batching. Exactly-Once Processing: A message is delivered once and remains available until a consumer processes and deletes it. Duplicates aren't introduced into the queue. First-In-First-Out Delivery: The order in which messages are sent and received is strictly preserved (i.e. First-In-First-Out).
upvoted 1 times
...
dmscountera
2 years, 9 months ago
Selected Answer: C
Based on all comments
upvoted 2 times
...
li_qiyang
2 years, 9 months ago
Selected Answer: A
How about This? https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/FIFO-queues-exactly-once-processing.html
upvoted 2 times
...
Dionenonly
2 years, 9 months ago
Selected Answer: C
Keyword: Process twice SQS prevents duplicate processes Answer: C
upvoted 1 times
...
Mechanic
3 years, 3 months ago
Selected Answer: C
Answer is C. Key concepts: 1. Hight availability 2. Thousands of requests/s 3. Duplication in processes EC2 ASG & SQS solve all of that.
upvoted 2 times
...
bfal
3 years, 3 months ago
Correct answer is C C addresses the issues highlighted in the question. One of queueing message going down, and losing orders, and the last one is duplicate processor certain orders. Amazon SQS address the issue of messaging Implement idempotency in the application resolves the issue of processing duplicate order - aka At-least-once delivery (Design your applications to be idempotent (they should not be affected adversely when processing the same message more than once). https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/standard-queues.html#standard-queues-at-least-once-delivery
upvoted 1 times
...
Alexey79
3 years, 4 months ago
Selected Answer: D
Why D: Can hadle more than 300 messages w/o loosing them. Will treat idempotency problem. It’s AWS sudgested topology. Why NOT A: “Put the ordering and inventory applications into their own AWS Lambda” … Lambda doesn’t support hosting application, API Gateway is required for that and it’s not mentioned. A is wrong. --SQS FIFO queues can only support 300 send, receive, or delete operations per second. and the question satats many thousand orders /second Why NOT C: no one mentioned about "idempotency" term from C - this one requires a control database to check the value for duplicates. I do not see this in C.
upvoted 1 times
...
jyrajan69
3 years, 4 months ago
All answering C , focused on the high number of orders, but there is an issue with duplication, standard queues cannot handle this. Only FIFO can handle this part, so unless there is an answer to this, the answer is A
upvoted 1 times
...
robsonchirara
3 years, 4 months ago
Selected Answer: C
Decoupling systems and growing demand. Definitely SQS and EC2 ASG.
upvoted 1 times
...
RVivek
3 years, 5 months ago
Answer C A is wrong. --SQS FIFO Que can handle only 300 messages per second and the question satats many thousand orders /second
upvoted 1 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...