Thanks Claus. Though I didn't understand why, I had already come to the
realization that I had to check the exchange headers directly in the
processor.

Now for hopefully my last question on this issue. 

My route builder has two similar routes that communicate with web services,
so I have two separate onExceptions defined in the two different routes.
This seems to break my onException unit tests.

I believe I recreated the issue by adding a second route to your test:

RouteScopedOnExceptionWithInterceptSendToEndpointIssueWithPredicateTest

I just added

                from("direct:start2")
                // no redelivery delay for faster unit tests
               
.onException(ConnectException.class).maximumRedeliveries(5).redeliveryDelay(0)
               
.logRetryAttempted(true).retryAttemptedLogLevel(LoggingLevel.WARN)
                // send to mock when we are exhausted
                .to("mock:exhausted")
                .end()
                .to("seda:bar");

below the first route. I believe this second route should be innocuous and
never get exercised.

Thanks again for all of your help,

-john
-- 
View this message in context: 
http://camel.465427.n5.nabble.com/route-scoped-onException-tp3300994p3312060.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to