A fleet management company is designing a serverless alert processing pipeline. IoT devices in fleet vehicles send diagnostic alert events via HTTPS to an API endpoint. The traffic is highly unpredictable, with long periods of inactivity followed by sudden, high-volume bursts during peak driving hours. The alerts from each unique vehicle must be processed in the exact chronological order they were generated to ensure accurate event tracking. Each alert requires a brief, 3-second validation and database write operation. The company wants to minimize costs and eliminate idle compute expenses.
Which combination of two actions will meet these requirements most cost-effectively? (Select TWO.)
- Route incoming HTTPS requests from Amazon API Gateway directly to an Amazon SQS FIFO queue.Cevap
- Configure an AWS Lambda function to poll the Amazon SQS FIFO queue and process the alerts.Cevap
- CRoute incoming HTTPS requests from Amazon API Gateway to a standard Amazon SQS queue.
- DConfigure an AWS Lambda function to run continuously in a loop using a recursive invocation pattern to poll a standard Amazon SQS queue.
- EDeploy the processing logic on Amazon ECS using AWS Fargate tasks configured to run continuously to poll the queue.
Cevap
Routing incoming HTTPS requests from Amazon API Gateway directly to an Amazon SQS FIFO queue and configuring an AWS Lambda function to poll the Amazon SQS FIFO queue and process the alerts.
Routing incoming HTTPS requests from Amazon API Gateway directly to an Amazon SQS FIFO queue and configuring AWS Lambda to poll the queue is the most cost-effective solution. API Gateway provides a serverless frontend that scales automatically and charges only per request. Direct integration with SQS FIFO buffers the messages and guarantees order processing per vehicle ID using the MessageGroupId. AWS Lambda scales to zero during idle periods, ensuring that compute costs are only incurred during the 3-second execution time when processing alerts.
Adım Adım Çözüm
Anahtar Kavram
Serverless and Automated Scaling Architectures for Cost Efficiency
Tahmini Süre:2m 0s