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
bug: SQS API is not respecting the region defined in request headers #6102
Comments
Welcome to LocalStack! Thanks for reporting your first issue and our team will be working towards fixing the issue for you or reach out for more background information. We recommend joining our Slack Community for real-time help and drop a message to LocalStack Pro Support if you are a Pro user! If you are willing to contribute towards fixing this issue, please have a look at our contributing guidelines and our developer guide. |
The problem also goes away if I use |
Refs #5928 |
hey @shadowhand, thanks for reporting.
TL;DR: it is now, it wasn't previously. in principle this is expected behavior, because (from my understanding) with AWS, the region is encoded either explicitly or implicitly in the queue. creating a we wanted to have that same behavior, and in i feel inclined to just say "sorry for breaking your code, but please use but i think a case can be made for something like a fourth endpoint strategy which is please share your thoughts :-) |
All of that makes sense and we did switch to using the new provider with "path" strategy. The problem is more that this was done in a minor release version with no warning or backwards compatibility in place, and it broke our entire development stack for the better part of day. Once I realized that localstack had updated I was able to read the change log and figure out how to upgrade. |
point taken, and apologies for that! we are working on updating the release strategy soon and making breaking changes more visible! closing for now, glad the path strategy is working for you! |
Is there an existing issue for this?
Current Behavior
Since version
0.14.3
localstack's SQS API no longer looks for the region defined in theAuthorization
header generated by the SDK, which means that any queues URLs created using thelegacy
strategy are only accessible inus-east-1
.Expected Behavior
When my SDK is configured with
region
, I expect that localstack services will respect that configuration. The SDKs, or at least the PHP SDK, send the region as part of theAuthorization
header:Note the region is contained in 3rd section of
Credential
. The problematic behavior appears to be written here insqs/query_api.py
, which makes no attempt to check for the region in the Authorization header, or in fact if the header even exists.When I configure localstack with
PROVIDER_OVERRIDE_SQS=legacy
the problem immediately goes away and I can use the SDK without issue.How are you starting LocalStack?
With a docker-compose file
Steps To Reproduce
How are you starting localstack (e.g.,
bin/localstack
command, arguments, ordocker-compose.yml
)Client commands (e.g., AWS SDK code snippet, or sequence of "awslocal" commands)
Environment
Anything else?
No response
The text was updated successfully, but these errors were encountered: