I just wrote a simple unit test[1] to verify the issue that you find, the test passed in camel master branch.
[1]http://git-wip-us.apache.org/repos/asf/camel/diff/b6a87991 -- Willem Jiang Red Hat, Inc. Web: http://www.redhat.com Blog: http://willemjiang.blogspot.com (English) http://jnn.iteye.com (Chinese) Twitter: willemjiang Weibo: 姜宁willem On June 18, 2014 at 12:37:34 AM, koritoss ([email protected]) wrote: > Thanks for the reply. > > I doubt the onException code is executed when 300~399 response code is > returned since I do not see the log message below. > > .onException(HttpOperationFailedException.class) > .process(new Processor() { > public void process(Exchange exchange) throws Exception { > LOGGER.log(Level.INFO, "HttpOperationFailedException > thrown); > } > }) > > One thing to note is that I do see the log messsage > "HttpOperationFailedException thrown" when response code 400+ is returned. > > I believe handled(true) mask the exception to the caller but it should still > catch the exception and print out that log message. > > > Is there another way to prevent this auto redirect behavior? > > > > -- > View this message in context: > http://camel.465427.n5.nabble.com/Disable-auto-redirect-tp5752391p5752446.html > > Sent from the Camel - Users mailing list archive at Nabble.com. >
