You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Since v0.21.0 it is not possible to enumerate over AWS regions due to #512
Version of AWS SDK for Go?
Since v0.21.0
Version of Go (go version)?
go version go1.14.2 linux/amd64
To Reproduce (observed behavior)
Try to compile example code from: github.com/aws/aws-sdk-go-v2/aws/endpoints/doc.go
// Enumerating Regions and Endpoint Metadata
//
// Casting the Resolver returned by DefaultResolver to a EnumPartitions interface
// will allow you to get access to the list of underlying Partitions with the
// Partitions method. This is helpful if you want to limit the SDK's endpoint
// resolving to a single partition, or enumerate regions, services, and endpoints
// in the partition.
//
// resolver := endpoints.NewDefaultResolver()
// partitions := resolver.Partitions()
//
// for _, p := range partitions {
// fmt.Println("Regions for", p.ID())
// for id, _ := range p.Regions() {
// fmt.Println("*", id)
// }
//
// fmt.Println("Services for", p.ID())
// for id, _ := range p.Services() {
// fmt.Println("*", id)
// }
// }
Expected behavior
It is possible to enumerate over regions.
Additional context
We are using this to change configurations in all AWS service regions. As the number of service regions is expanding, this helps us to keep up-to-date with service regions and use the newest version.
The text was updated successfully, but these errors were encountered:
Fixesaws#557 by removing out dated example documentation from the SDK's
endpoints package and README. The feature to enumerate regions and
services was removed in aws#512 pending further design and development of
service specific endpoint metadata.
Thanks for reaching out @Necropaw. This was a feature that was intentionally removed from the v2 SDK, and it looks like the example documentation was missed in that update. This was done as the design of how the V2 SDK sources endpoints metadata is currently in flux. We are investigating designs that will move the modeling of service endpoints out of a centralized unit and into the individual API client packages.
Confirm by changing [ ] to [x] below to ensure that it's a bug:
Describe the bug
Since v0.21.0 it is not possible to enumerate over AWS regions due to #512
Version of AWS SDK for Go?
Since v0.21.0
Version of Go (
go version
)?go version go1.14.2 linux/amd64
To Reproduce (observed behavior)
Try to compile example code from:
github.com/aws/aws-sdk-go-v2/aws/endpoints/doc.go
Expected behavior
It is possible to enumerate over regions.
Additional context
We are using this to change configurations in all AWS service regions. As the number of service regions is expanding, this helps us to keep up-to-date with service regions and use the newest version.
The text was updated successfully, but these errors were encountered: