SQSClient

module:queue. SQSClient

Queue client using AWS SQS, full queue url can be used or just the name as sqs://queuename

The count config property specifies how messages to process at the same time, default is 1.

The interval config property defines in ms how often to check for new messages after processing a message, i.e. after a messages processed it can poll immediately or after this amount of time, default is 1000 milliseconds.

The retryInterval config property defines in ms how often to check for new messages after an error or no data, i.e. on empty pool when no messages are processed it can poll immediately or after this amount of time, default is 5000 mulliseconds.

The visibilityTimeout property specifies how long the messages being processed stay hidden, in milliseconds.

The timeout property defines how long to wait for new messages, i.e. the long poll, in milliseconds

The retryCount and retryTimeout define how many times to retry failed AWS HTTP requests, default is 5 times starting with the backoff starting at 500 milliseconds.

For messages that have startTime property which is the time in the future when a message must be actually processed there is a parameter maxTimeout which defines in milliseconds the max time a messsage can stay invisible while waiting for its scheduled date, default is 6 hours, the AWS max is 12 hours. The scheduling is implemented using AWS visibilityTimeout feature, keep scheduled messages hidden until the actual time.

Constructor

new SQSClient()

Example
queue-messages=sqs://messages?bk-interval=60000
queue-messages=https://sqs.us-east-1.amazonaws.com/123456/messages?bk-visibilityTimeout=300&bk-count=2