From 7e006af713fe9c86eb00c854465e852e775dd585 Mon Sep 17 00:00:00 2001 From: tidwall Date: Sun, 17 Mar 2019 18:40:34 -0700 Subject: [PATCH] Add verbose messaging for aws/sqs --- internal/endpoint/sqs.go | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/internal/endpoint/sqs.go b/internal/endpoint/sqs.go index 36319641..7d0a94c4 100644 --- a/internal/endpoint/sqs.go +++ b/internal/endpoint/sqs.go @@ -12,6 +12,7 @@ import ( "github.com/aws/aws-sdk-go/aws/session" "github.com/aws/aws-sdk-go/service/sqs" "github.com/streadway/amqp" + "github.com/tidwall/tile38/internal/log" ) var errCreateQueue = errors.New("Error while creating queue") @@ -86,9 +87,10 @@ func (conn *SQSConn) Send(msg string) error { region = sqsRegionFromPlainURL(conn.ep.SQS.PlainURL) } sess := session.Must(session.NewSession(&aws.Config{ - Region: ®ion, - Credentials: creds, - MaxRetries: aws.Int(5), + Region: ®ion, + Credentials: creds, + CredentialsChainVerboseErrors: aws.Bool(log.Level >= 3), + MaxRetries: aws.Int(5), })) svc := sqs.New(sess) if conn.ep.SQS.CreateQueue {