1
选择块在下面的代码,任何人都可以请解释doTry做什么选择块,为什么它不赶RuntimeCamelException?异常处理骆驼 - 在doTry
<doTry>
<process ref="msgProcessor" />
<choice>
<when>
<simple>"false" == "true" && ${exchangeProperty.status} == ${ref:SUCCESS}</simple>
<process ref="queryProcessor" />
</when>
</choice>
<choice>
<when>
<simple>"false" == "true" && ${exchangeProperty.status} == ${ref:SUCCESS}</simple>
<process ref="compareProcessor" />
</when>
</choice>
<doCatch>
<exception>org.apache.camel.RuntimeCamelException</exception>
<exception>java.lang.Exception</exception>
</doCatch>
</doTry>
我仍然得到以下异常:
org.apache.camel.RuntimeCamelException: Scanner aborted because of an IOException!
at org.apache.camel.processor.Splitter$SplitterIterable$1.hasNext(Splitter.java:171)
at org.apache.camel.processor.MulticastProcessor.doProcessParallel(MulticastProcessor.java:268)
at org.apache.camel.processor.MulticastProcessor.process(MulticastProcessor.java:225)
at org.apache.camel.processor.Splitter.process(Splitter.java:104)
我有类似的问题。它看起来像.doTry()和.choice()不能很好地一起玩。 –