File tree Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -481,12 +481,20 @@ Status S3StorageProvider::CreateBucket(const std::string& bucket) {
481481 Aws::S3::Model::BucketLocationConstraint bucket_location = Aws::S3::Model::
482482 BucketLocationConstraintMapper::GetBucketLocationConstraintForName (
483483 ToAwsString (env_->GetCloudEnvOptions ().dest_bucket .GetRegion ()));
484- // to create a bucket in US-EAST-1 you must specify no constraint location for
485- // legacy reasons
484+ //
485+ // If you create a bucket in US-EAST-1, no location constraint should be
486+ // specified
487+ //
488+ // https://docs.aws.amazon.com/AmazonS3/latest/API/API_CreateBucket.html
489+ //
490+ // By default, the bucket is created in the US East (N. Virginia) Region.
491+ // You can optionally specify a Region in the request body. You might choose
492+ // a Region to optimize latency, minimize costs, or address regulatory
493+ // requirements.
494+ //
486495 if ((bucket_location != Aws::S3::Model::BucketLocationConstraint::NOT_SET) &&
487496 (bucket_location !=
488497 Aws::S3::Model::BucketLocationConstraint::us_east_1)) {
489- // only set the location constraint if it's not not set
490498 conf.SetLocationConstraint (bucket_location);
491499 }
492500
You can’t perform that action at this time.
0 commit comments