camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From deepak_a <>
Subject Re: How to use throwExceptionOnFailure=false to differentiate HTTP Status codes
Date Wed, 20 Feb 2013 09:22:47 GMT

I took an *ugly* approach.
Capture the HTTP exception (OnExeption) - then find out what type of
ShatusCode it is.
If its between 400..499 then just simply log the exception, if Status Code
is between 500..599 then i manually publish the message back into my
ActiveMQ Queue (for camel to again pull the message and make the HTTP call)
This goes into a loop with a maxRetry of 5 and on the 5th attempt I simply
log the 500..599 exception. 

I do get the expected functionality bu 
Would need to revisit this at a later point in time to make it more

View this message in context:
Sent from the Camel - Users mailing list archive at

View raw message