enum BucketNamespace
| Language | Type name |
|---|---|
.NET | Amazon.CDK.AWS.S3.BucketNamespace |
Go | github.com/aws/aws-cdk-go/awscdk/v2/awss3#BucketNamespace |
Java | software.amazon.awscdk.services.s3.BucketNamespace |
Python | aws_cdk.aws_s3.BucketNamespace |
TypeScript (source) | aws-cdk-lib » aws_s3 » BucketNamespace |
The namespace for the bucket name when using bucketNamePrefix.
Determines how CloudFormation generates the unique portion of the bucket name.
Example
new s3.Bucket(this, 'MyBucket', {
bucketNamePrefix: 'my-app',
bucketNamespace: s3.BucketNamespace.ACCOUNT_REGIONAL,
});
// Resulting bucket name: my-app-123456789012-us-east-1-an
Members
| Name | Description |
|---|---|
| GLOBAL | The bucket name is globally unique. |
| ACCOUNT_REGIONAL | The bucket name is unique within the account and region. |
GLOBAL
The bucket name is globally unique.
ACCOUNT_REGIONAL
The bucket name is unique within the account and region.

.NET
Go
Java
Python
TypeScript (