Courseiva

DVA-C02 Development with AWS Services Practice Question

A developer wants to trigger an AWS Lambda function every time a new object is created in an Amazon S3 bucket. Which S3 event notification configuration should be used?

⚠ Common exam trap

The trap here is that candidates might confuse `s3:ObjectCreated:*` with `s3:ObjectRemoved:*` or `s3:ObjectRestore:*`, thinking any object state change triggers the function, but only creation events are relevant for the 'new object' requirement.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

✓

s3:ObjectCreated:*

The `s3:ObjectCreated:*` event type captures all object creation events in an S3 bucket, including PUT, POST, COPY, and multipart upload completions. This is the appropriate event notification to trigger an AWS Lambda function when a new object is created.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✓

    s3:ObjectCreated:*

    Why this is correct

    This event notification type, `s3:ObjectCreated:*`, is a wildcard that encompasses all actions resulting in a new object being stored in an S3 bucket. It includes specific events like `s3:ObjectCreated:Put`, `s3:ObjectCreated:Post`, `s3:ObjectCreated:Copy`, and `s3:ObjectCreated:CompleteMultipartUpload`. This makes it the most comprehensive and appropriate choice for triggering a Lambda function whenever any new file is successfully added to S3, regardless of the specific upload method used.

  • ✗

    s3:ObjectRestore:*

    Why it's wrong here

    The `s3:ObjectRestore:*` event specifically triggers when an object previously archived in S3 Glacier or Glacier Deep Archive is restored and made available in its original S3 bucket. This indicates that a temporary copy of the archived object has been retrieved and is ready for access. It does not fire when a *new* object is initially uploaded or created, making it unsuitable for the requirement of triggering on *every* object creation.

  • ✗

    s3:ReducedRedundancyLostObject:*

    Why it's wrong here

    The `s3:ReducedRedundancyLostObject:*` event type is specifically generated by Amazon S3 when it detects the loss of an object stored using the now-deprecated Reduced Redundancy Storage (RRS) class. RRS was designed for non-critical, reproducible data with lower durability. This event signifies data loss for a particular, legacy storage class, not the creation of new objects, and is largely irrelevant for modern S3 usage as RRS is no longer recommended or widely used.

  • ✗

    s3:ObjectRemoved:*

    Why it's wrong here

    The `s3:ObjectRemoved:*` event notification type is triggered when an object is deleted from an S3 bucket, either explicitly via `s3:ObjectRemoved:Delete` or implicitly through versioning (`s3:ObjectRemoved:DeleteMarkerCreated`). It specifically signals the removal or logical deletion of an object, which is the opposite action of creating an object. Therefore, it cannot be used to trigger a Lambda function upon the *creation* of new objects.

Quick reference

AWS S3 Storage Class Comparison

Storage ClassMin DurationRetrievalUse Case
S3 StandardNoneImmediateFrequently accessed data
S3 Standard-IA30 daysImmediateInfrequent access, rapid retrieval
S3 One Zone-IA30 daysImmediateNon-critical infrequent data
S3 Intelligent-TieringNoneImmediate–hoursUnknown or changing access patterns
S3 Glacier Instant90 daysMillisecondsArchive with instant retrieval
S3 Glacier Flexible90 daysMinutes–hoursArchive, flexible retrieval
S3 Glacier Deep Archive180 daysHoursLong-term compliance archive

About these practice questions

This DVA-C02 question is part of Courseiva's 1,135-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This DVA-C02 practice question is part of Courseiva's free Amazon Web Services certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the DVA-C02 exam.