Problem solved.
Error was not in defining redelivery policy
but in dealing with messages ack/not ack.

When message was to be acknowledged it was done this way:

    _message->acknowledge();

However, when message was to be returned to the queue the following snippet
was called:

    _session->recover();

That was the problem. According to ActiveMQ-CPP documentation, messages that
have been received but not acknowledged will be redelivered.
According to that there is no need to do anything on _session object. 
Not sending acknowledgement is enough.



--
View this message in context: 
http://activemq.2283324.n4.nabble.com/ActiveMQ-c-redelivery-delay-tp4664942p4664957.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Reply via email to