SQS - Client Ack Mode Piles up Inflight messages under load and Message Id's in JVM memory

0

SQS queue is implemented with a JMS Message Listener mode with Client ACK session mode. When the messages are read they are delegated to another JVM process to continue processing then Delete the message from the SQS queue. While the messages are deleted successfully. We see two different issues with this

  1. SQS System message Id for each read message is added to a list in the JVM1 where the message is read from the queue.
  2. Under load the number of inflight messages keeps on continously increasing overtime. We have 16 consumers in each JVM process to process the queue.

Does SQS support CLIENT_ACK mode across multiple JVM processes? i.e Read from 1st JVM and delete on the 2nd. how can we stop the SQS library build up the list of Message Id's in the RangeExtender implementation?

And, what do we need to do to keep the messages from getting deleted in a timely manner to avoid the build up of inflight messages. under normal load we do not see this issue. But when TPS increases beyond a certain point we see the inflight messages count keeps increasing.

asked a year ago79 views
No Answers

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions