• Object Storage Service

obs
  1. Help Center
  2. Object Storage Service
  3. API Reference (OBS)
  4. Operations on Buckets
  5. GET Bucket lifecycle
  6. Responses

Responses

Syntax

HTTP/1.1 200 OK
Server: Server Name
x-amz-request-id: 90E2BA0A420C00000140ED9939AF099E
x-amz-id-2: UHQoAKndcsk628TszydX75G/Q2+I5MwYJ3IJYqzEkNInMkBMn96hunAVsoiMCHZh
x-reserved: amazon, aws and amazon web services are trademarks or registered trademarks of Amazon Technologies, Inc
Content-Type: application/xml
Date: Thu, 05 Sep 2015 10:09:36 GMT
Content-Length: 425

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<LifecycleConfiguration xmlns="http://obs.example.com/doc/2015-06-30/">
<Rule>
<ID>id</ID>
<Prefix>prefix</Prefix>
<Status>status</Status>
<Expiration>
<Date>date</Date>
</Expiration>
<NoncurrentVersionExpiration>
<NoncurrentDays>365</NoncurrentDays>
</NoncurrentVersionExpiration>
<Transition> 
<Date>date</Date> 
<StorageClass>STANDARD_IA</StorageClass> 
</Transition> 
<Transition> 
<Date>date</Date> 
<StorageClass>GLACIER</StorageClass> 
</Transition> 
<NoncurrentVersionTransition> 
<NoncurrentDays>30</NoncurrentDays> 
<StorageClass>STANDARD_IA</StorageClass> 
</NoncurrentVersionTransition> 
<NoncurrentVersionTransition> 
<NoncurrentDays>60</NoncurrentDays> 
<StorageClass>GLACIER</StorageClass> 
</NoncurrentVersionTransition>
</Rule>
</LifecycleConfiguration>

Response Headers

This response uses common headers. For details about common response headers, see section Common Response Headers.

Response Elements

This response contains elements to detail bucket lifecycle configuration. Table 1 describes the elements.

Table 1 Response elements for lifecycle configuration

Element

Description

Date

Indicates when the specified rule takes effect.

The date value must conform to ISO 8601 format. The time is always midnight UTC.

Type: String

Ancestor: Expiration, Transition

Days

Indicates the number of days after object creation when the specified rule takes effect.

Type: Positive integer

Ancestor: Expiration, Transition

StorageClass

Indicates the new storage class of the object.

Type: STANDARD_IA or GLACIER

Ancestor: Transition, NoncurrentVersionTransition

Transition

Indicates the element of the transition time and new storage class (applicable to the latest version of the object) in the lifecycle configuration.

Type: XML

Children: Date or Days

Ancestor: Rule

Expiration

Indicates the container for the object expiration rule.

Type: XML

Children: Date or Days

Ancestor: Rule

ID

Indicates the unique identifier of a rule. The value can contain a maximum of 255 characters.

Type: String

Ancestor: Rule

LifecycleConfiguration

Indicates the container for lifecycle rules. You can add multiple rules. The total size of the rules cannot exceed 20 KB.

Type: XML

Children: Rule

Ancestor: None

NoncurrentDays

Indicates the number of days after object is noncurrent when the specified rule takes effect.

Type: Positive integer

Ancestor: NoncurrentVersionExpiration, NoncurrentVersionTransition

NoncurrentVersionTransition

Indicates the element of the transition time and new storage class (applicable to historical versions) in the lifecycle configuration.

Type: XML

Children: NoncurrentDays, StorageClass

Ancestor: Rule

NoncurrentVersionExpiration

Indicates the container for the noncurrent object expiration rule. You set this lifecycle configuration action on a bucket that has versioning enabled (or suspended) to request that OBS delete noncurrent object versions which meet the expiration rule.

Type: XML

Children: NoncurrentDays

Ancestor: Rule

Prefix

Indicates the object key prefix identifying one or more objects to which the rule applies.

Type: String

Ancestor: Rule

Rule

Indicates the container for lifecycle rules.

Type: Container

Ancestor: LifecycleConfiguration

Status

Indicates whether the rule is enabled.

Type: String

Ancestor: Rule

Valid Values: Enabled, Disabled

Error Responses

This response contains common errors. For details, see Table 1. In addition, this response contains one special error, as described in Table 2.

Table 2 Special error

Error Code

Description

HTTP Status Code

NoSuchLifecycleConfiguration

Indicates that the bucket lifecycle configuration does not exist.

404 Not Found