Class ReceiveSqsMessageHelper


  • public class ReceiveSqsMessageHelper
    extends Object
    The ReceiveSqsMessageHelper class forms a ReceiveMessageRequest request based on configuration settings, collects messages from an AWS SQS queue, and handles exceptions during the process.

    It manages message visibility timeout by tracking the visibility deadline and expiring messages if not processed in time, ensuring unhandled messages return to the queue for reprocessing.

    Additionally, the class supports clearing messages in the batch and changing their visibility as needed.

    • Method Detail

      • isEmpty

        public boolean isEmpty()
      • getException

        public Throwable getException()
      • removeMessage

        public Message removeMessage()
      • clear

        public void clear()
      • messagesSize

        public Integer messagesSize()
        messages.size() is expensive since it is ConcurrentLinkedQueue. Thus, its used only for testing the results and not used in any internal classes.