Class SetBucketVersioningConfigurationRequest

java.lang.Object
com.amazonaws.AmazonWebServiceRequest
com.amazonaws.services.s3.model.SetBucketVersioningConfigurationRequest
All Implemented Interfaces:
ReadLimitInfo, Serializable, Cloneable

public class SetBucketVersioningConfigurationRequest extends AmazonWebServiceRequest implements Serializable

Contains options for setting the versioning configuration for a bucket.

A bucket's versioning configuration can be in one of three possible states:

By default, new buckets are created in the BucketVersioningConfiguration.OFF state. Once versioning is enabled for a bucket, its status can never be reverted to off.

Objects created before versioning is enabled or while versioning is suspended will be given the default null version ID (see Constants.NULL_VERSION_ID). Note that the null version ID is a valid version ID and is not the same as having no version ID.

The versioning configuration of a bucket has different implications for each operation performed on that bucket or for objects within that bucket. When versioning is enabled, a PutObject operation creates a unique object version ID for the object being uploaded. The PutObject operation guarantees that if versioning is enabled for a bucket at the time of the request, the new object can only be permanently deleted by calling the DeleteVersion operation and can never be overwritten.

Additionally, the PutObject operation guarantees that if versioning is enabled for a bucket at the time of the request, no other object will be overwritten by that request. Refer to the documentation sections for individual APIs for information on how versioning status affects the semantics of that particular API.

Amazon S3 is eventually consistent. It may take time for the versioning status of a bucket to be propagated throughout the system.

See Also: