Skip to content

Commit

Permalink
add source property for aws endpoint
Browse files Browse the repository at this point in the history
  • Loading branch information
skotambkar committed Jan 22, 2021
1 parent a55d57f commit 776fa46
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions aws/endpoints.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,27 @@ type Endpoint struct {
// The signing method that should be used for signing the requests to the
// endpoint.
SigningMethod string

// The source of the Endpoint. By default, this will be EndpointSourceServiceMetadata.
// When providing a custom endpoint, you should set the source as EndpointSourceCustom.
// If source is not provided when providing a custom endpoint, the SDK may not
// perform required host mutations correctly. Source should be used along with
// HostnameImmutable property as per the usage requirement.
Source EndpointSource
}

// EndpointSource is the endpoint source type.
type EndpointSource int

const (
// EndpointSourceServiceMetadata denotes service modeled endpoint metadata is used as Endpoint Source.
EndpointSourceServiceMetadata EndpointSource = iota

// EndpointSourceCustom denotes endpoint is a custom endpoint. This source should be used when
// user provides a custom endpoint to be used by the SDK.
EndpointSourceCustom
)

// EndpointNotFoundError is a sentinel error to indicate that the
// EndpointResolver implementation was unable to resolve an endpoint for the
// given service and region. Resolvers should use this to indicate that an API
Expand Down

0 comments on commit 776fa46

Please sign in to comment.