How to automate S3 object tagging after delayed third-party content audit?
A photo sharing application uses Amazon S3 to store image files. All user images are manually audited for inappropriate content by a third-party company. The audits are completed 1-24 hours after user upload and the results are written to an Amazon DynamoDB table, which uses the S3 object key as a primary key. The database items can be queried by using a REST API created by the third-party company. An application developer needs to implement an automated process to tag all S3 objects with the results of the content audit. What should the developer do to meet these requirements in the MOST operationally efficient way?
Community Votes
57% 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 tests the ability to decouple an asynchronous, long-running external process from an S3 upload event using AWS Step Functions, specifically leveraging a Wait state to handle the 1–24 hour audit delay without polling or managing infrastructure.
This DVA-C02 question tests how to orchestrate a delayed, event-driven workflow using AWS Step Functions to tag S3 objects after a third-party audit. Community debate centers on whether a scheduled Lambda (Option C) or a Step Functions Wait state (Option B) is the most operationally efficient approach.
Many candidates choose Option C (EventBridge + scheduled Lambda) because it appears simpler and avoids a 24-hour wait, but it fails to efficiently tie the tagging action to the specific S3 object upload event and results in repeated, wasteful API calls to the REST API for objects not yet audited.
Community Discussion (15 comments)
Comments & Corrections
No comments yet — spotted an error or have a note? Share it below.
Expert Analysis
Understanding the Scenario
The workflow involves three distinct phases:
1. S3 Upload – A user uploads an image. 2. External Audit – A third-party company audits the image, taking 1–24 hours. 3. Tagging – After the audit, the S3 object must be tagged with the result.
The key constraint is the asynchronous, long-running external process. The system must wait for the audit to complete before tagging.
Why Option B is Correct
Option B uses an AWS Lambda function triggered by the s3:ObjectCreated event, which then starts an AWS Step Functions standard workflow. The workflow includes a Wait state set to 24 hours, after which a second Lambda retrieves the audit result from the REST API and tags the S3 object.
This is the most operationally efficient solution because:
- Event-driven: Tagging is tied directly to the upload event, not a blind schedule.
- No infrastructure management: Step Functions and Lambda are fully managed serverless services.
- Precise orchestration: The Wait state cleanly handles the 1–24 hour delay without polling or maintaining state in a database.
- Scalable: Each upload spawns its own workflow instance, avoiding batch-processing bottlenecks.
Why the Other Options are Wrong
- Option A (SQS with 24-hour visibility timeout): SQS visibility timeouts are not designed for precise, long delays. A message would become visible again after 24 hours, but if the audit takes less than 24 hours, the system still waits the full timeout. If it takes longer, the message reappears prematurely. This is a misuse of SQS.
- Option C (EventBridge scheduled Lambda): While serverless, this approach polls the REST API at regular intervals for all untagged objects. This is inefficient because:
- Option D (EC2 + crontab): This requires managing an EC2 instance, deploying scripts, and maintaining a crontab. It is the least operationally efficient option due to the operational overhead of infrastructure management, patching, and scaling.
Community Insight
The debate between B and C highlights a common confusion: event-driven orchestration vs. scheduled polling. While C seems simpler, it violates the principle of operational efficiency by introducing unnecessary API calls and latency. Step Functions (Option B) is purpose-built for this exact scenario.
Official Reference
Exam Strategy
When a question emphasizes 'operationally efficient' and involves a long-running, asynchronous external process, look for serverless orchestration tools like AWS Step Functions. Avoid solutions that require managing infrastructure (EC2) or polling (scheduled Lambda) unless the scenario explicitly calls for batch processing.
Related Analysis
Practice All DVA-C02 Questions
Access 100 questions with complete answers and detailed explanations.
View Full DVA-C02 Practice Test →