Question

I have an AWS EB Worker Tier working.

I have noticed that sometimes particular tasks would always end up in the Dead Letter Queue in SQS even though they successfully complete and return the right response code. I have tracked this down to the length of time of the running task so I guess there is a timeout on tasks.

What is the timeout for EB Worker Tier tasks?

How can I extend the timeout?

Thanks!

Was it helpful?

Solution

AWS EB Worker Tier is based on an SQS queue. SQS has a default message timeout of 30 seconds. If processing certain messages consistently takes more than this amount of time and timeouts, then the Worker Tier will place those messages in the Dead Letter Queue so that they stop being sent to your worker. This happens even if your worker tier successfully processes the message, it just couldn't do it in time.

You have two possible solutions: (a) Improve the performance and/or processing time of those messages, or (b) Increase the timeout of your SQS queue.

To do (b):

  1. Go to the SQS part of the AWS Management Console
  2. Select your queue
  3. Choose "Configure Queue" from the "Queue Actions" menu
  4. Increase the "Default Visibility Timeout" value
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top