Documentation ¶
Overview ¶
sqs handles messages from AWS SQS via channels.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ( MaxNumberOfMessages = 1 VisibilityTimeout = 600 WaitTimeSeconds = 20 )
Functions ¶
func InitRx ¶
InitRx handles receiving and deleting messages from AWS SQS via a pair of channels. Messages from SQS can be received from the read chan. Receipt handles for messages that should be deleted from SQS can be sent to the write chan.
Messages are read from the SQS queue s.MaxNumberOfMessages at a time. They remain invisible or inflight on the SQS queue until either they are deleted by sending the ReceiptHandle to the write chan or they become visible again after s.VisibilityTimeout seconds when they are redelivered. Messages are delivered by SQS at least once. Applications should handle receiving message duplicates.
The chans block for slow consumers.
Types ¶
This section is empty.