Closed apmarathe closed 8 years ago
Yes, this is the correct way to ACK (or NACK using NACK()) a message. Follows the Tutorials in the tutorial folder to understand this and other best practices.
The reason that I asked this question was this. After ACK-ing the message this way, it does not get removed from the queue on the RabbitMQ server (as it should be).
Does your client use STOMP 1.1? If so, pull the latest repo version and retry passing the subscriptionid to the ACK method.
In our implementation, we observe that when a message response comes back to the Delphi code via the stomp client, the response is not deleted from the response queue.
I have tried something like this to ack the message, thinking that ack-ing a message might remove it from the response queue.
procedure Consumer.OnMessage(StompClient: IStompClient; StompFrame: IStompFrame; var StopListening: Boolean);
<-- code deleted -->
StompClient.Ack(StompFrame.MessageID());
My question is: Is this a correct way to ack a response? If not, could you please share how?
Thanks, Arun