Skip to content

Conversation

@millems
Copy link
Contributor

@millems millems commented Aug 11, 2021

No description provided.

Comment on lines +31 to +32
AwsRequestOverrideConfiguration requestConfig = AwsRequestOverrideConfiguration.from(endpointDiscoveryRequest
.overrideConfiguration().orElse(null));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One issue might be that request-level overrides like headers/query params could have unintended effects on the DescribeEndpoints request. What do you think about erring on the conservative side and just copying the credentials provider if it's present?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm worried about only copying some things, because different people might have different expectations about what is used and not used. Why shouldn't the headers and query parameters be used for the discovery call? What about the API names (for user agent)? Signer? Metrics publishers? Some of these things we almost certainly want to include on the discovery call, so I'd favor just including them all so that there's no confusion.

Also, if we try to pick-and-choose now, when we add new stuff in the future, we'll definitely forget to ask "does this make sense to copy over for endpoint discovery?".

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep good points; I can't think of a use case where the other things on the override config would cause issues with the request, but I thought it was a valid concern. I'm in favor of just copying the override config as well.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't mean to disregard your concern. I totally agree it's a valid concern. I'm just less fond of the other alternatives.

@sonarqubecloud
Copy link

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

79.2% 79.2% Coverage
0.0% 0.0% Duplication

@millems millems merged commit 21879c8 into master Aug 12, 2021
@millems millems deleted the millem/fix-request-endpoint-discovery branch August 12, 2021 00:57
aws-sdk-java-automation added a commit that referenced this pull request Aug 11, 2023
…f37d95f51

Pull request: release <- staging/ac1a935f-4c29-467e-8331-51bf37d95f51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants