
Explanation:
The correct answer is D. The first rule is designed to delete any object that is older than 30 days and is not the latest version (not live). However, since the bucket does not have versioning enabled, this rule has no effect. The second rule changes the storage class of live objects from Multi-regional to Coldline for objects older than 365 days.
Refer to the GCP documentation on Object Lifecycle Management for more details. The conditions supported for a lifecycle rule include:
true, the condition matches only live objects; if false, it matches only archived objects. Objects in non-versioned buckets are always considered live.STANDARD and DURABLE_REDUCED_AVAILABILITY in the condition to cover all objects of similar storage class.Why not the others?
Ultimate access to all questions.
No comments yet.
A SysOps admin has set up a lifecycle rule on a multi-regional bucket with object versioning disabled. What will be the effect of the following lifecycle configuration?
{
"rule": [
{
"action": {"type": "Delete"},
"condition": {"age": 30, "isLive": false}
},
{
"action": {"type": "SetStorageClass", "storageClass": "COLDLINE"},
"condition": {"age": 365, "matchesStorageClass": "MULTI_REGIONAL"}
}
]
}
{
"rule": [
{
"action": {"type": "Delete"},
"condition": {"age": 30, "isLive": false}
},
{
"action": {"type": "SetStorageClass", "storageClass": "COLDLINE"},
"condition": {"age": 365, "matchesStorageClass": "MULTI_REGIONAL"}
}
]
}
A
Archive objects older than 30 days and transition objects to Coldline Storage after 365 days if they are in the Multi-regional storage class.
B
Remove objects older than 30 days and transition objects to Coldline Storage after 365 days if they are in the Multi-regional storage class.
C
Delete archived objects older than 30 days and transition objects to Coldline Storage after 365 days if they are in the Multi-regional storage class.
D
Transition objects to Coldline Storage after 365 days if they are in the Multi-regional storage class. The first rule has no effect on the bucket.