I am trying out Camel for use in a project. 

One of the things we would like to do is have guaranteed delivery. To that
end I am trying to use Client Ack mode in JMS to leave a message on the
Queue I read it from until all the processing has been completed. 

This is similar to what was asked in this Thread:
http://old.nabble.com/guaranteed-message-processing-question...-td26202573.html
Thread on guaranteed-message-processing-question 

I have added the JmsComponent to the CamelContext using the
jmsComponentClientAcknowledge method as follows:

JmsComponent jc = JmsComponent.jmsComponentClientAcknowledge(cf);
context.addComponent("test-jms", jc);

but the message is always pulled off the JMS queue without a JMS Message
acknowledge() method call. 

        public class ProcessMessageOK implements Processor{
                @Override
                public void process(Exchange exchange) throws Exception {
                        Message m = exchange.getIn();                   
                        log.info("Received message (body): " + m.getBody());
                        // ((JmsMessage)m).getJmsMessage().acknowledge();
                }
        }

This does not seem to work the way JMS 1.1 spec specifies (section 4.4.11
and 4.10) regarding CLIENT_ACKNOWLEDGEMENT. 

If I need to use transactions in Camel per the other thread, what does the
jmsComponentClientAcknowledge method actually do?

Thanks and sorry if I am missing something as I am new to Camel. 
Mike

-- 
View this message in context: 
http://old.nabble.com/Camel-and-JMS-Client-Ack-Mode--tp27152146p27152146.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to