Hi

Yeah you are right I am fixing this now.

On Mon, Sep 8, 2014 at 8:35 PM, blr_developer <sridhar2...@gmail.com> wrote:
> Camel RabbitMQ component acknowledges the message even though the autoAck is
> set to false and there is an exception in the route. I don't know if I am
> doing anything wrong.
>
> My guess is that the error could be in the RabbitMQConsumer class.
>
> try {
>                 consumer.getProcessor().process(exchange);
>
>                 long deliveryTag = envelope.getDeliveryTag();
>                 if (!consumer.endpoint.isAutoAck()) {
>                     log.trace("Acknowledging receipt [delivery_tag={}]",
> deliveryTag);
>                     channel.basicAck(deliveryTag, false);
>                 }
>
>             } catch (Exception e) {
>                 getExceptionHandler().handleException("Error processing
> exchange", exchange, e);
>             }
>
> Process method does not throw exception but sets exception property of the
> exchange to the exception object when there is any error while processing
> the exchange. There may need to be a check to see if the exception property
> is null before acknowledging the message.
>
>
>
> --
> View this message in context: 
> http://camel.465427.n5.nabble.com/Camel-RabbitMQ-acknowledges-event-though-autoAck-is-set-to-false-and-there-is-an-exception-in-the-roe-tp5756207.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cib...@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen
hawtio: http://hawt.io/
fabric8: http://fabric8.io/

Reply via email to