Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[C++] S3 CreateBucket fails because AWS treats us-east-1 differently than other regions #28914

Closed
asfimport opened this issue Jul 1, 2021 · 2 comments

Comments

@asfimport
Copy link

When you create a bucket you must specify a locationconstraint if the region is not us-east-1.  This works if you specify a region but fails if you use the default region (and the default region has been configured to NOT be us-east-1).

When you create a bucket you must NOT specify a locationconstraint if the region is us-east-1.  This fails (Arrow specifies the locationconstraint and receives an error "InvalidLocationConstraint Message: The specified location-constraint is not valid").

CreateBucket is getting the region from options().region which is the empty string if the user didn't specify a region.

 

Reporter: Weston Pace / @westonpace
Assignee: Weston Pace / @westonpace

PRs and other links:

Note: This issue was originally created as ARROW-13228. Please see the migration documentation for further details.

@asfimport
Copy link
Author

Weston Pace / @westonpace:
Botocore related: boto/boto3#125

AWS related: https://docs.aws.amazon.com/cli/latest/reference/s3api/create-bucket.html

 

Notice that even the AWS command line has this quirk...

 

# Create a bucket on us-east-1
aws s3api create-bucket --bucket my-bucket --region us-east-1
# Create a bucket on us-west-2
aws s3api create-bucket --bucket my-bucket --region us-west-2 --create-bucket-configuration LocationConstraint=us-west-2

 

@asfimport
Copy link
Author

Antoine Pitrou / @pitrou:
Issue resolved by pull request 10637
#10637

@asfimport asfimport added this to the 5.0.0 milestone Jan 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants