camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From duclad <claudiu.dumitre...@gmail.com>
Subject onException ignored when using Spring DSL
Date Fri, 12 Oct 2012 15:24:37 GMT
Hello, 

Please help me on this until I go nuts: I have a camel context created using
Spring DSL with some routes define inside. I want that in the case one of
the routes throws an exception all things to stop and the message to be
routed to a special endpoint. 
Here, let me show you:

<camelContext errorHandlerRef="noErrorHandler" id="contextId"
depends-on="logService">
   <propertyPlaceholder id="properties"	location="ref:propConf" />
   <onException>
	<exception>java.lang.Exception</cml:exception>
	<redeliveryPolicy maximumRedeliveries="0" />
	<handled><cml:constant>true</cml:constant></cml:handled>
	<to uri="vm:trash"/>
   </onException>
   <route id="trash">
      <from uri="vm:trash"/>
      </stop>
   </route>
   <route id="A">
      <from uri="file//input"/>
      <to uri="vm:xmlFilesListener/>
   </route>
   <route id="B">
      <from uri="vm:xmlFilesListener"/>
      <process ref="processorThatThrowsException"/>
      <to uri="vm:applicationEntryPoint"/>
   </route>
   <route id="C">
      <from uri="vm:applicationEntryPoint"/>
      <process ref="processorThatEatsResources/>
      <to uri="file://output">
   </route>
</camelContext>

Nevertheless, it seems that the onException is completely ignored and I
tried all the possible combinations. :(

Thank you so much guys, 
Claudiu





--
View this message in context: http://camel.465427.n5.nabble.com/onException-ignored-when-using-Spring-DSL-tp5720968.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Mime
View raw message