putBucketIntelligentTieringConfiguration method
- required String bucket,
- required String id,
- required IntelligentTieringConfiguration intelligentTieringConfiguration,
Puts a S3 Intelligent-Tiering configuration to the specified bucket.
The S3 Intelligent-Tiering storage class is designed to optimize storage costs by automatically moving data to the most cost-effective storage access tier, without additional operational overhead. S3 Intelligent-Tiering delivers automatic cost savings by moving data between access tiers, when access patterns change.
The S3 Intelligent-Tiering storage class is suitable for objects larger than 128 KB that you plan to store for at least 30 days. If the size of an object is less than 128 KB, it is not eligible for auto-tiering. Smaller objects can be stored, but they are always charged at the frequent access tier rates in the S3 Intelligent-Tiering storage class.
If you delete an object before the end of the 30-day minimum storage duration period, you are charged for 30 days. For more information, see Storage class for automatically optimizing frequently and infrequently accessed objects.
Operations related to
PutBucketIntelligentTieringConfiguration
include:
- DeleteBucketIntelligentTieringConfiguration
- GetBucketIntelligentTieringConfiguration
- ListBucketIntelligentTieringConfigurations
Parameter bucket
:
The name of the Amazon S3 bucket whose configuration you want to modify or
retrieve.
Parameter id
:
The ID used to identify the S3 Intelligent-Tiering configuration.
Parameter intelligentTieringConfiguration
:
Container for S3 Intelligent-Tiering configuration.
Implementation
Future<void> putBucketIntelligentTieringConfiguration({
required String bucket,
required String id,
required IntelligentTieringConfiguration intelligentTieringConfiguration,
}) async {
ArgumentError.checkNotNull(bucket, 'bucket');
ArgumentError.checkNotNull(id, 'id');
ArgumentError.checkNotNull(
intelligentTieringConfiguration, 'intelligentTieringConfiguration');
final $query = <String, List<String>>{
'id': [id],
};
await _protocol.send(
method: 'PUT',
requestUri: '/${Uri.encodeComponent(bucket)}?intelligent-tiering',
queryParams: $query,
payload: intelligentTieringConfiguration
.toXml('IntelligentTieringConfiguration'),
exceptionFnMap: _exceptionFns,
);
}