How to Concurrently Invoke Independent Lambda Functions on an Event?

A developer is building an ecommerce application. When there is a sale event, the application needs to concurrently call three third-party systems to record the sale. The developer wrote three AWS Lambda functions. There is one Lambda function for each third-party system, which contains complex integration logic. These Lambda functions are all independent. The developer needs to design the application so each Lambda function will run regardless of others' success or failure. Which solution will meet these requirements?

  1. Publish the sale event from the application to an Amazon Simple Queue Service (Amazon SQS) queue. Configure the three Lambda functions to poll the queue.
  2. Publish the sale event from the application to an Amazon Simple Notification Service (Amazon SNS) topic. Subscribe the three Lambda functions to be triggered by the SNS topic. Source Reference Answer
  3. Publish the sale event from the application to an Application Load Balancer (ALB). Add the three Lambda functions as ALB targets.
  4. Publish the sale event from the application to an AWS Step Functions state machine. Move the logic from the three Lambda functions into the Step Functions state machine.

Community Votes

B
100%

100% of anonymous learners picked answer B. Votes are pick records left by other test-takers — they are not the verified answer.

Community Insight

The question evaluates understanding of publish/subscribe architectures versus queue-based processing, with the common trap being the misuse of SQS or Step Functions for truly independent, fire-and-forget invocations.

This scenario tests AWS event-driven patterns for concurrent, independent function execution using Amazon SNS fan-out. The community unanimously agrees that SNS subscriptions are the optimal solution for decoupling publishers from multiple independent consumers.

Option A (SQS) is frequently chosen incorrectly because candidates confuse message queuing with event broadcasting; SQS delivers messages to only one consumer by default, failing the requirement for concurrent independent execution across all three functions.

Community Discussion (3 comments)

tomchandler077 👍 5
B Given the requirements to concurrently call three independent third-party systems when there is a sale event, and ensuring that each Lambda function runs regardless of the success or failure of the others, the best solution is to use Amazon Simple Notification Service (SNS).
albert_kuo 👍 4 Selected: B
1. create sns topic aws sns create-topic --name SaleEvents 2. create three lambda function to subscribe sns topic aws sns subscribe --topic-arn arn:aws:sns:region:account-id:SaleEvents --protocol lambda --notification-endpoint arn:aws:lambda:region:account-id:function:Function1 aws sns subscribe --topic-arn arn:aws:sns:region:account-id:SaleEvents --protocol lambda --notification-endpoint arn:aws:lambda:region:account-id:function:Function2 aws sns subscribe --topic-arn arn:aws:sns:region:account-id:SaleEvents --protocol lambda --notification-endpoint arn:aws:lambda:region:account-id:function:Function3
siheom 👍 1 Selected: B
Definitely B

Comments & Corrections

No comments yet — spotted an error or have a note? Share it below.

Log in to comment, report an error, or add a note about this question.

Submitted for moderation before publishing. Keep it helpful and respectful.

Expert Analysis

Why the Answer Is Correct

Amazon SNS implements a true publish/subscribe model that automatically fans out events to all subscribed endpoints simultaneously. By subscribing each Lambda function directly to an SNS topic, the sale event triggers all three functions concurrently without any dependency on each other's outcomes. This architecture natively satisfies the requirement for independent execution regardless of success or failure. It also provides built-in retry mechanisms and dead-letter queue support for failed deliveries.

Why the Other Options Are Wrong

Option A uses SQS, which follows a point-to-point delivery model where a message is consumed by only one recipient, breaking the concurrency requirement. Option C leverages an Application Load Balancer, which routes HTTP traffic but lacks native event-fan-out capabilities for background Lambda invocations. Option D introduces AWS Step Functions, which adds unnecessary orchestration overhead and couples the functions into a single workflow state machine rather than keeping them independent.

Community Comment Notes

Candidates overwhelmingly select option B, confirming that SNS subscriptions directly invoke Lambda functions as intended. One contributor provided exact AWS CLI commands to create the topic and subscribe the functions, highlighting the straightforward implementation [2]. Another user confirmed that this pattern eliminates custom routing logic, making it the most efficient design choice [1]. The community consensus firmly aligns with AWS documentation on decoupled serverless architectures.

Official Reference

Exam Strategy

When a question specifies concurrent, independent execution triggered by a single event, immediately consider SNS fan-out over SQS or Step Functions. Remember that SQS is for single-consumer or worker pool patterns, while SNS is designed for one-to-many asynchronous broadcasting.

Related Analysis

Practice All DVA-C02 Questions

Access 100 questions with complete answers and detailed explanations.

View Full DVA-C02 Practice Test →

← Back to DVA-C02 Study Guide