Bucket object lifecycles
With object lifecycles, you can configure automatic actions on individual objects or groups of objects in a bucket at specified points in time.
Note
In buckets with logging enabled, actions performed on objects as part of the object lifecycle are not logged.
Types of actions include:
- Change the storage class of objects or their non-current versions to a colder one. You can configure the change to the
ICE
class using the YC CLI, AWS CLI, Terraform, and the API. - Delete objects or their non-current versions.
- Delete incomplete multipart uploads.
Filters for grouping objects include:
- Object key prefix.
- Minimum or maximum object size.
- Object label; unavailable in the management console
. AND
logical operator that allows you to group objects using a combination of multiple filters.
You can only specify one filter per lifecycle rule. To specify more than one filter type for a lifecycle at a time, use the logical AND
. For more information, see Lifecycle configuration.
If you use the S3 API, specify the lifecycle configuration in XML format. Various tools with the S3 API support may require other configuration formats. The AWS CLI, for example, uses the JSON format.
You can only configure object lifecycles for each individual bucket, not for a bucket group, folder, or cloud.
Object lifecycles are updated daily at 00:00 UTC. This operation takes a few hours to complete.