camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From S AR <sa_remin...@hotmail.com>
Subject Re: Catching Exception
Date Sun, 18 Dec 2016 13:33:32 GMT
Sadly,

sjms does not throw any exception when the connection is gone. At least when testing with
ActiveMQ.

batch-sjms does though.



On 18.12.2016 14:07, Claus Ibsen wrote:

Hi

Btw what exceptions / stacktraces etc do you see from the logs? It can
help us to see if we can improve the camel-sjms component even more.

I am just fixing the batch consumer to allow the bridge

On Sat, Dec 17, 2016 at 1:43 PM, sa_james <sa_reminder@hotmail.com><mailto:sa_reminder@hotmail.com>
wrote:


So I went back and read the book again, but it does not show how to handle
exception outside of the routing engine. I check the file consumer example
and tried to apply it, but it did not work. This is what I did:

/onException(classOf[Exception]).to("log:was-caught ${body}")

from("batch-sjms:test.foo?consumer.bridgeErrorHandler=true").to("log:test")/

I was excepting an IOException (First ConnectException and Subsequent
DisconnectException) to be caught, but that was not the case.
What am I missing?



--
View this message in context: http://camel.465427.n5.nabble.com/Catching-Exception-tp5791552p5791630.html
Sent from the Camel - Users mailing list archive at Nabble.com.







Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message