Expert AWS Development
上QQ阅读APP看书,第一时间看更新

Troubleshooting in Amazon SQS

Sometimes Amazon SQS Dead-Letter Queues do not behave as expected. The following are common problems or issues and their solutions:

  • Message moved to Dead-Letter Queue:

Viewing messages from the AWS console might cause problems with a message and move it to a Dead-Letter Queue. You can adjust this behavior in the following way:

    • For the corresponding queue's redrive policy, increase the Maximum Receives setting
    • From AWS Management Console, avoid viewing the corresponding queue messages
  • Send and receive messages doesn't match:

When a message is sent to a Dead-Letter Queue manually, it will be captured by the NumberOfMessagesSent metric. If, however, a message is sent to a Dead-Letter Queue as a result of a failed processing attempt, it isn't captured by this metric. Thus the values of NumberOfMessagesSent and NumberOfMessagesReceived don't match.

In the next section, we will discuss Amazon Simple Workflow Service (SWF). It helps to distribute work across different components. It gives full control to developers over coordinating tasks and implementing processing steps without worrying about complexities such as keeping their state and tracking their progress.