diff options
author | Valery Piashchynski <[email protected]> | 2021-07-21 16:52:41 +0300 |
---|---|---|
committer | Valery Piashchynski <[email protected]> | 2021-07-21 16:52:41 +0300 |
commit | b2da831f47284974551710d2767a7bdde0efa51d (patch) | |
tree | 7d8fee59cdb307110d2fcd872635437e0203321b /plugins/jobs/drivers/sqs/config.go | |
parent | 50cf036c81668508c8f2e9130bc5a2019cddf1b9 (diff) |
Fix AMQP context, add ID, job, other fields.
Fix sqs queue re-creation.
Complete redia for the beanstalk.
Signed-off-by: Valery Piashchynski <[email protected]>
Diffstat (limited to 'plugins/jobs/drivers/sqs/config.go')
-rw-r--r-- | plugins/jobs/drivers/sqs/config.go | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/plugins/jobs/drivers/sqs/config.go b/plugins/jobs/drivers/sqs/config.go index 0b4e8157..af5b1cfb 100644 --- a/plugins/jobs/drivers/sqs/config.go +++ b/plugins/jobs/drivers/sqs/config.go @@ -1,5 +1,7 @@ package sqs +import "github.com/aws/aws-sdk-go-v2/aws" + type GlobalCfg struct { Key string `mapstructure:"key"` Secret string `mapstructure:"secret"` @@ -36,7 +38,7 @@ type Config struct { // Queue URLs and names are case-sensitive. // // This member is required. - Queue string `mapstructure:"queue"` + Queue *string `mapstructure:"queue"` // A map of attributes with their corresponding values. The following lists the // names, descriptions, and values of the special request parameters that the @@ -81,8 +83,8 @@ func (c *GlobalCfg) InitDefault() { } func (c *Config) InitDefault() { - if c.Queue == "" { - c.Queue = "default" + if c.Queue == nil { + c.Queue = aws.String("default") } if c.PrefetchCount == 0 || c.PrefetchCount > 10 { |