New Year Sale 2026! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

Amazon DVA-C02 Exam - Topic 4 Question 58 Discussion

Actual exam question for Amazon's DVA-C02 exam
Question #: 58
Topic #: 4
[All DVA-C02 Questions]

A developer is using an AWS Lambda function to generate avatars for profile pictures that are uploaded to an Amazon S3 bucket. The Lambda function is automatically invoked for profile pictures that are saved under the /original/ S3 prefix. The developer notices that some pictures cause the Lambda function to time out. The developer wants to implement a fallback mechanism by using another Lambda function that resizes the profile picture.

Which solution will meet these requirements with the LEAST development effort?

Show Suggested Answer Hide Answer
Suggested Answer: A

The solution that will meet the requirements with the least development effort is to set the image resize Lambda function as a destination of the avatar generator Lambda function for the events that fail processing. This way, the fallback mechanism is automatically triggered by the Lambda service without requiring any additional components or configuration. The other options involve creating and managing additional resources such as queues, topics, state machines, or rules, which would increase the complexity and cost of the solution.


Contribute your Thoughts:

0/2000 characters
Dewitt
5 hours ago
I think option A is the easiest. Just set the destination for failures.
upvoted 0 times
...
Gail
5 days ago
Wait, can Lambda functions really time out like that?
upvoted 0 times
...
Tambra
11 days ago
I think B could be more reliable in the long run.
upvoted 0 times
...
Salina
16 days ago
Option D with the SNS topic is an interesting idea, but it feels a bit more complex than the SQS queue approach in Option B.
upvoted 0 times
...
Gary
21 days ago
Option C with the Step Functions state machine seems a bit overkill for this use case. The other options are simpler and get the job done.
upvoted 0 times
...
Gail
26 days ago
I agree, Option B looks like the least development effort. Queueing the failed events and having a separate function handle the resizing is a clean solution.
upvoted 0 times
...
Ezekiel
1 month ago
Option B seems like the easiest solution. Using an SQS queue as a buffer and having the resize function poll from it is a straightforward approach.
upvoted 0 times
...
Mitsue
1 month ago
I think option D with SNS could work, but it seems like it might require more setup than just using a direct destination like in option A.
upvoted 0 times
...
German
1 month ago
I practiced a similar question where Step Functions were involved, but it felt like overkill for this scenario. I wonder if option C is really the best choice here.
upvoted 0 times
...
Terina
2 months ago
I'm not entirely sure, but I think using SQS in option B might add unnecessary complexity compared to just chaining the functions directly.
upvoted 0 times
...
Izetta
2 months ago
I like the idea of using an SNS topic in option D, but I'm not sure if that's the least development effort. The SQS queue in option B seems like it might require a bit less setup and configuration. I'll need to do some more research on the relative complexity of these options.
upvoted 0 times
...
Kimberlie
2 months ago
Option A seems the most straightforward, but I'm worried about the potential for the avatar generator function to keep failing and overwhelming the resize function. Option B with the SQS queue might be a better way to decouple the two functions and handle failures more gracefully.
upvoted 0 times
...
Susy
2 months ago
I agree, A is definitely the least effort!
upvoted 0 times
...
Aleta
2 months ago
Option A sounds like the simplest solution.
upvoted 0 times
...
Carri
2 months ago
I remember that using destinations for Lambda functions is a straightforward way to handle failures, so option A seems like it could work well with minimal effort.
upvoted 0 times
...
Donte
3 months ago
Haha, imagine if the developer just used a single Lambda function that both generated and resized the avatars. Talk about a single point of failure!
upvoted 0 times
...
Gilbert
3 months ago
But what if the resize function fails too?
upvoted 0 times
...
Melina
3 months ago
I'm a bit confused by the different options. Option C with the Step Functions state machine seems a bit overkill for this use case. I'm leaning more towards option B or D, but I'll need to think through the pros and cons of each.
upvoted 0 times
...
Cristy
3 months ago
I think option B is the way to go here. Using an SQS queue as a buffer and having the resize function poll from it seems like the simplest approach to implement a fallback mechanism.
upvoted 0 times
...

Save Cancel