Courseiva
Storing the Data →mediumMultiple Choice

PDE Storing the Data Practice Question

A data engineer needs to store raw sensor data in Cloud Storage and automatically transition it to a lower-cost storage class after 30 days, then delete it after 365 days. What should they configure?

⚠ Common exam trap

Google Cloud often tests the distinction between lifecycle management (which automates transitions and deletions) and retention policies (which only prevent deletion/overwrites), leading candidates to confuse the two.

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

✓

Configure a lifecycle rule with SetStorageClass to Nearline after 30 days and Delete after 365 days.

Cloud Storage lifecycle management rules allow you to automatically transition objects to a lower-cost storage class (such as Nearline) after a specified number of days and then delete them after another period. This is the native, serverless way to manage object lifecycle without external scripts or compute resources.

Answer analysis

Option-by-option breakdown

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

  • ✗

    Use Cloud Pub/Sub notifications to trigger a Cloud Function that moves objects.

    Why it's wrong here

    Cloud Pub/Sub notifications trigger a Cloud Function only on object creation or deletion events, but the requirement is for automatic, time-based transitions between storage classes and deletion after a fixed period, which Cloud Storage’s native Object Lifecycle Management handles without any external compute. This option is tempting because Pub/Sub with Cloud Functions is a common pattern for reacting to storage events, and it would be correct if the engineer needed custom processing—such as transforming or analysing sensor data—at the moment of upload, rather than applying scheduled, policy-driven transitions.

  • ✗

    Use gsutil rewrite command in a cron job.

    Why it's wrong here

    A scheduled rewrite changes each object's storage class on demand but implements no lifecycle automation, and deleting at 365 days needs separate scripting. It is tempting because rewrite does move objects between classes, and would be correct for one-off bulk class changes.

  • ✓

    Configure a lifecycle rule with SetStorageClass to Nearline after 30 days and Delete after 365 days.

    Why this is correct

    A single lifecycle rule with age-based conditions performs both transitions automatically: SetStorageClass to Nearline at 30 days, then Delete at 365 days. This satisfies both the cost-tiering and retention constraints without manual intervention or separate rules.

  • ✗

    Set a bucket retention policy with a retention period of 365 days.

    Why it's wrong here

    A retention policy only prevents deletion or overwriting until the period expires; it cannot transition objects to a colder class at 30 days. It is tempting because retention policies do govern object lifetime, and would be correct for compliance holds requiring immutability.

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

Courseiva writes every PDE question from scratch — 747 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or 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 PDE practice question is part of Courseiva's free Google Cloud 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 PDE exam.