liveBook · Manning

Version

As explained in Amazon Web Services in Action, Third Edition: An in-depth guide to AWS

An object version is a distinct stored revision of an object identified by the same object key.

An object version is a distinct stored revision of an object identified by the same object key. S3 disables versioning for buckets by default: uploading new data under an existing key replaces the previously accessible data. Enabling versioning preserves earlier revisions for retrieval. section 7.3

Use AWS CLI commands to preserve and inspect revisions:

  • Enable versioning with aws s3api put-bucket-versioning and Status=Enabled. section 7.3
  • List stored objects and their versions with aws s3api list-object-versions. section 7.3
  • Download all versions to restore earlier data. section 7.3

Preserving successive uploads

Upload data 1 under key A, then upload data 2 under the same key. Without versioning, downloading A returns data 2 and data 1 is no longer accessible. With versioning enabled, both revisions remain available. This supports backup and archiving, but each new version increases billable bucket size. section 7.3

$ aws s3api put-bucket-versioning --bucket awsinaction-$yourname \
 --versioning-configuration Status=Enabled

Enable versioning on a named S3 bucket with the AWS CLI. section 7.3

$ aws s3api list-object-versions --bucket awsinaction-$yourname

Inspect all objects and stored revisions in the bucket. section 7.3

How Amazon Web Services in Action, Third Edition: An in-depth guide to AWS covers it

How deep it goes
Defines overwrite behavior, demonstrates preservation and retrieval, and notes storage-cost growth without covering lifecycle management.
Examples
Uses repeated uploads of data 1 and data 2 under object key A, followed by listing and downloading versions.
What it assumes
Assumes an S3 bucket and object-key familiarity while teaching versioning from its default disabled state.
What you can do after
Apply versioning via AWS CLI, list revisions, and restore earlier object data.
How it connects
Connects object versions with Amazon S3 buckets, object keys, backups, archiving, restoration, and storage cost.

Also explained in

Compare how 5 books explain version →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Amazon Web Services in Action, Third Edition: An in-depth guide to AWS. The section links point to the parts of the book it draws on.