S3 artifact stores and provenance
Exam alignment: DOP-C02 Domain 1 task statements for pipelines, testing, artifacts, or deployment.
Learning objective
Protect generic build artifacts with versioning, encryption, checksums, manifests, and lifecycle rules.
| Difficulty / Schwierigkeitsgrad | Intermediate |
| Study time / Lernzeit | 120 minutes |
| Prerequisites / Voraussetzungen | Previous lessons in this volume |
Professional scenario
Packages are manually renamed latest.zip, so the running source revision cannot be proven.
Core concepts
- S3 transfers generic files between pipeline actions.
- Versioning protects object history.
- KMS controls encrypted access.
- A manifest links commit, build, tests, artifact version, and checksum.
Architecture flow
- Identify the release input and immutable identity.
- Select the managed AWS control plane and least-privilege role.
- Execute build, test, artifact, or deployment work.
- Collect service events, logs, reports, and runtime metrics.
- Stop, retry, or roll back according to explicit rules.
Decision matrix
| Requirement | Preferred choice | Reason |
|---|---|---|
| Generic package | S3 | Object artifact |
| Strong traceability | Manifest and checksum | Proves source and integrity |
| Retention control | Lifecycle by artifact class | Protect releases, expire temporary data |
Failure modes and troubleshooting
- Mutable name is overwritten.
- S3 allows read but KMS denies.
- Lifecycle deletes rollback artifact.
Security and operations
- Use short-lived service roles and least privilege.
- Encrypt artifacts and protect logs from secret exposure.
- Record changes and approvals for audit.
Hands-on lab
Goal / Ziel: Create an encrypted versioned bucket and release manifest.
Tasks
- Create the smallest safe test architecture.
- Implement or simulate the main workflow.
- Introduce one controlled failure.
- Diagnose it from service evidence.
- Document cleanup and one improvement.
Validation
- The workflow uses an immutable version.
- A required failure blocks promotion.
- The diagnosis identifies the first failed transition.
Cost control / Kostenkontrolle: Keep resources short lived; read cleanup before starting.
Cleanup
- Delete pipeline/build/deployment resources.
- Delete temporary artifacts, images, logs, and roles.
Exam traps
- Using
latestas identity. - One lifecycle rule for all content.
Key takeaways
- S3 transfers generic files between pipeline actions.
- A manifest links commit, build, tests, artifact version, and checksum.
- Decisions must be justified by requirements and failure behavior.
Review questions
- What is the immutable release identity?
- Which evidence proves failure or success?
- What is the safest recovery action?
Answers
- A version, digest, or uniquely versioned artifact.
- Service events, logs, reports, health checks, and runtime metrics.
- Restore the known-good version using the configured rollback path.