Exam SAP-C02 All QuestionsBrowse all questions from this exam
Question 180

A company runs a processing engine in the AWS Cloud. The engine processes environmental data from logistics centers to calculate a sustainability index. The company has millions of devices in logistics centers that are spread across Europe. The devices send information to the processing engine through a RESTful API.

The API experiences unpredictable bursts of traffic. The company must implement a solution to process all data that the devices send to the processing engine. Data loss is unacceptable.

Which solution will meet these requirements?

    Correct Answer: B

    In this scenario, using Amazon API Gateway HTTP API integrated with Amazon Simple Queue Service (SQS) is the optimal solution. API Gateway provides a scalable interface to handle bursts of traffic efficiently. SQS acts as a buffer to store incoming data, ensuring that no data is lost during traffic spikes. AWS Lambda can then process the messages from the SQS queue, providing a serverless compute solution that scales automatically as needed. This combination guarantees data durability and reliable processing without loss.

Discussion
momo3321Option: B

Option A is incorrect because Application Load Balancer (ALB) can't directly target an Amazon SQS queue. Option C is incorrect because while Amazon API Gateway and EC2 Auto Scaling can handle high loads, they don't provide a built-in mechanism to ensure that all messages are processed without loss. Option D is incorrect because Amazon CloudFront is a content delivery network (CDN), and it is not typically used to handle incoming API requests. It is primarily used to cache and deliver content to users.

bjexamprepOption: B

In real life, I wouldn't trust SQS to handle such large amount of data.

Littleboy95Option: B

B is correct, you can integrate SQS with API Gateway HTTP. I have checked it in AWS API Gateway Console https://repost.aws/knowledge-center/api-gateway-rest-api-sqs-errors A is incorrect because you can not set SQS queue as the target of ALB C is incorrect because a fleet of EC2 instances and ASG can lead instances to terminated unexpectedly → data loss D is incorrect because Kinesis Data Streams is a provisioned service, It can not handle unpredictable bursts

youngmanaws

KDS has on-demand mode. https://docs.aws.amazon.com/streams/latest/dev/how-do-i-size-a-stream.html

Littleboy95

Yes, KDS has on-demand mode, my wrong. But according to the above link, KDS on-demand can only accommodate up to double the peak write throughput observed in the previous 30 days. While SQS standard Queue has Unlimited Throughput https://aws.amazon.com/sqs/features/

nzin4x

but normally API gateway can not handle high burst request. it will make 429 too many requests error.

severlightOption: B

yes you can integrate API Gateway HTTP Api with SQS

rbm2023Option: B

I agree with B https://aws.amazon.com/blogs/architecture/things-to-consider-when-you-build-rest-apis-with-amazon-api-gateway/ This pattern can decouple the data ingestion from the data processing. "you should look for opportunities to design an asynchronous, loosely coupled architecture. A decoupled architecture separates the data ingestion from the data processing and allows you to scale each system separately"

AMEJackOption: B

Kinesis DataStreams can't be the origin for the CloudFront

vip2Option: B

Restful API is not REST API, so HTTP API-GW + SQS

career360guruOption: B

Option B

career360guruOption: B

Option B

SK_TyagiOption: B

KDS need to implement Sharding for unpredictable bursts

rxhan

Similar to #179

NikkyDickyOption: B

B is right

Roontha

Answer : B

mrfretzOption: D

Kinesis retention

mrfretzOption: B

Kinesis retention

mrfretz

Answer D, sorry typo

Sarutobi

B is the best option.