Skip to content

MQ Message not acknowledged on thrown exception #5234

@garrettahines1

Description

@garrettahines1

Describe the bug
I am using artemis mq as a message broker and have an incoming stream to listen for messages on a queue. In the method for the incoming stream, I have it possible to throw an exception. It seems that if an exception is thrown the mq broker is not notified that the message has been acknowledged by my service even though I have received and processed it. My service will no longer receive any messages sent to the queue and every time I restart my service, it receives that same bad message. If I change the method to just log the error, the queue works normally and is able to receive the bad message, log it, and continue receiving messages.

Expected behavior
Throws exception but continues listening for future messages on that queue.

Actual behavior
Throws exception and no longer receives messages on that queue.

To Reproduce
Steps to reproduce the behavior:

  1. Start up mq broker
  2. Create method with incoming tag to receive messages on a queue
  3. Throw exception in method
  4. Send data that causes exception to be thrown
  5. Send data again

Configuration

# Add your application.properties here, if applicable.
mp.messaging.incoming.queue-name.connector=smallrye-amqp
mp.messaging.incoming.queue-name.durable=true

Environment (please complete the following information):

  • Output of uname -a or ver:
  • Output of java -version: 11.0.2
  • GraalVM version (if different from Java):
  • Quarkus version or git rev: 0.28.0

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions