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
aws/endpoints: Fix resolve endpoint with empty region #2911
Conversation
Fixes the SDK's behavior when attempting to resolve a service's endpoint when no region was provided. Adds legacy support for services that were able to resolve a valid endpoint. No new service will support resolving an endpoint without an region. Fixes aws#2909
@@ -5,7 +5,6 @@ var stsLegacyGlobalRegions = map[string]struct{}{ | |||
"ap-south-1": {}, | |||
"ap-southeast-1": {}, | |||
"ap-southeast-2": {}, | |||
"aws-global": {}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this have been removed? We still set the region to "aws-global" in v3model.go#L115
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes this was intentional. The aws-global
region already exists in the model, and wasn't really a legacy region. If endpoint were resolved with this region it was resolve to aws-global direclty in the endpoints file.
aws/session/session.go
Outdated
// s.Handlers.Validate.PushFront(func(r *request.Request) { | ||
// r.Error = err | ||
// }) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: Commented out code
Fixes the SDK's endpoint resolve incorrectly resolving endpoints for a service when the region is empty. Also fixes the SDK attempting to resolve a service when the service value is empty. Related to: aws/aws-sdk-go#2911
=== ### Service Client Updates * `service/ecr`: Updates service API, documentation, and paginators * This release of Amazon Elastic Container Registry Service (Amazon ECR) introduces support for image scanning. This identifies the software vulnerabilities in the container image based on the Common Vulnerabilities and Exposures (CVE) database. * `service/elasticache`: Updates service API and documentation * Amazon ElastiCache adds support for migrating Redis workloads hosted on Amazon EC2 into ElastiCache by syncing the data between the source Redis cluster and target ElastiCache for Redis cluster in real time. For more information, see https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/migrate-to-elasticache.html. * `service/transfer`: Updates service API and documentation * This release adds logical directories support to your AWS SFTP server endpoint, so you can now create logical directory structures mapped to Amazon Simple Storage Service (Amazon S3) bucket paths for users created and stored within the service. Amazon S3 bucket names and paths can now be hidden from AWS SFTP users, providing an additional level of privacy to meet security requirements. You can lock down your SFTP users' access to designated folders (commonly referred to as 'chroot'), and simplify complex folder structures for data distribution through SFTP without replicating files across multiple users. ### SDK Enhancements * `aws/client`: Add PartitionID to Config ([#2902](#2902)) * `aws/client/metadata`: Add PartitionID to ClientInfo ([#2902](#2902)) * `aws/endpoints`: Add PartitionID to ResolvedEndpoint ([#2902](#2902)) ### SDK Bugs * `aws/endpoints`: Fix resolve endpoint with empty region ([#2911](#2911)) * Fixes the SDK's behavior when attempting to resolve a service's endpoint when no region was provided. Adds legacy support for services that were able to resolve a valid endpoint. No new service will support resolving an endpoint without an region. * Fixes [#2909](#2909)
Release v1.25.20 (2019-10-28) === ### Service Client Updates * `service/ecr`: Updates service API, documentation, and paginators * This release of Amazon Elastic Container Registry Service (Amazon ECR) introduces support for image scanning. This identifies the software vulnerabilities in the container image based on the Common Vulnerabilities and Exposures (CVE) database. * `service/elasticache`: Updates service API and documentation * Amazon ElastiCache adds support for migrating Redis workloads hosted on Amazon EC2 into ElastiCache by syncing the data between the source Redis cluster and target ElastiCache for Redis cluster in real time. For more information, see https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/migrate-to-elasticache.html. * `service/transfer`: Updates service API and documentation * This release adds logical directories support to your AWS SFTP server endpoint, so you can now create logical directory structures mapped to Amazon Simple Storage Service (Amazon S3) bucket paths for users created and stored within the service. Amazon S3 bucket names and paths can now be hidden from AWS SFTP users, providing an additional level of privacy to meet security requirements. You can lock down your SFTP users' access to designated folders (commonly referred to as 'chroot'), and simplify complex folder structures for data distribution through SFTP without replicating files across multiple users. ### SDK Enhancements * `aws/client`: Add PartitionID to Config ([#2902](#2902)) * `aws/client/metadata`: Add PartitionID to ClientInfo ([#2902](#2902)) * `aws/endpoints`: Add PartitionID to ResolvedEndpoint ([#2902](#2902)) ### SDK Bugs * `aws/endpoints`: Fix resolve endpoint with empty region ([#2911](#2911)) * Fixes the SDK's behavior when attempting to resolve a service's endpoint when no region was provided. Adds legacy support for services that were able to resolve a valid endpoint. No new service will support resolving an endpoint without an region. * Fixes [#2909](#2909)
Fixes the SDK's endpoint resolve incorrectly resolving endpoints for a service when the region is empty. Also fixes the SDK attempting to resolve a service when the service value is empty. Related to: aws/aws-sdk-go#2911
Fixes the SDK's endpoint resolve incorrectly resolving endpoints for a service when the region is empty. Also fixes the SDK attempting to resolve a service when the service value is empty. Related to: aws/aws-sdk-go#2911
Fixes the SDK's behavior when attempting to resolve a service's endpoint when no region was provided. Adds legacy support for services that were able to resolve a valid endpoint. No new service will support resolving an endpoint without an region.
Fixes #2909