-
Notifications
You must be signed in to change notification settings - Fork 652
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
Unable to Override Region for Timestream ListDatabase Call #2163
Comments
I can confirm this is an issue. You have noted correctly that services using endpoint discovery will always make the "describe endpoints" call with the initially configured region, ignoring any other regions sideloaded through per-invocation options. Note this occurs whether the client region came from shared config as your example demonstrates, OR through a region manually set via svc := timestreamwrite.NewFromConfig(cfg, func(o *timestreamwrite.Options) {
o.Region = "us-east-2"
}) The actual failure you're seeing appears to come from signing, since we're effectively (incorrectly) always operating in a timestream "cell" in There are two changes we need to make to correct this behavior:
As of this writing, the endpoint discovery feature is used only by timestream (both While it's not an ideal workaround, you can circumvent this issue by creating a separate client for each region in which you're operating. |
#### Summary Workaround for aws/aws-sdk-go-v2#2163
I see you merged a fix? if this is fixed can we close this issue? Thanks, |
@RanVaknin - The fix that we put in place is purely a workaround that we intend to remove once the SDK is fixed |
Yes-- please leave this issue open for now. There is still a bug in the SDK itself. |
|
#### Summary AWS has merged a fix for aws/aws-sdk-go-v2#2163. Once that fix is released we can delete this workaround
Describe the bug
When you specify a region that is different than the region in the config via the request options the call always fails. The internal endpoint discovery mechanism always uses the region from the sdk client rather than the region specified in the request options
Expected Behavior
The call should not fail with an error saying the credentials are invalid. The endpoint discovery should use the region that is passed in to determine the endpoint rather than the region set in the sdk client
Current Behavior
The call returns an error:
Reproduction Steps
With the output being:
Possible Solution
No response
Additional Information/Context
No response
AWS Go SDK V2 Module Versions Used
Compiler and Version used
go version go1.20.5 darwin/arm64
Operating System and version
MacOS
The text was updated successfully, but these errors were encountered: