Details
-
Improvement
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
2.24.1
-
None
-
Unknown
Description
Pulsar messages are currently acknowledged immediately upon consumption, which could lead to lost messages if the application crashes or does not finish its unit of work. [Correction March 3, 2020 -- This is not correct. Pulsar messages are acknowledged after successful processing of the route, not immediately after consumption from the topic. Exceptions or errors on the route will correctly cause the message to remain unacknowledged.]
It would be desirable to add the ability to manually acknowledge a message consumed from Pulsar. The end user can decide when to acknowledge, or negative acknowledge a Pulsar message within the route. This will become a necessity when support for asynchronous processing of Pulsar messages is added.
Add a handle to the Pulsar consumer in a header in the Exchange so that the user can acknowledge the message at will similar to what was done for Kafka: