[Bug]: Update AWS endpoint resolution #252
Labels
bug
Something isn't working
go
Pull requests that update Go code
good first issue
Good for newcomers
help wanted
Extra attention is needed
Why is this issue important?
As of the 2023-07-31 release of the github.com/aws/aws-sdk-go-v2 library, use of the "v1"
EndpointResolver
and provided is deprecated. This is documented here in the AWS SDK for Go V2 Developer Guide.We use the now-deprecated
EndpointResolver in the
internal/awsHelpers` package to configure SQS clients in a manner that is compatible with both real-world AWS usage and LocalStack.Current State
The Staticcheck linter fails on two lines of the
GetSQSClient
function defined ininternal/awsHelpers/config.go
due to SA1019 - Using a deprecated function, variable, constant or field and provides the following output:Expected State
EndpointResolver
.lint:ignore
comment directives.Implementation Plan
//lint:ignore SA1019 ...
comment directives to the offending lines.internal/awsHelpers
package to use the newly-availableEndpointResolverV2
and/orBaseEndpoint
instead ofEndpointResolver
.//lint:ignore
comment directives added in Step 1.Relevant Code Snippets
Failing lines:
return cfg.EndpointResolverWithOptions.ResolveEndpoint("sqs", cfg.Region)
o.EndpointResolver = sqsResolver
The text was updated successfully, but these errors were encountered: