Are you using this code in a route that is part a transaction? Like a JMS
transaction?
On Fri, Mar 7, 2014 at 10:30 PM, Freeman, Keith wrote:
> I have this code in my route:
>
> onException(Exception.class)
> .handled(true)
>
> .maximumRedeliveries(-1)
>
Hi
Well there is a little difference in current code between errorHandler
and onException.
The former will set the backoff = true automatic
public RedeliveryPolicy backOffMultiplier(double multiplier) {
useExponentialBackOff();
setBackOffMultiplier(multiplier);
return
Yes, the Java-DSL-example on page 132 is missing it, but on the same page
the book says
"You also have to enable exponential backoff explicitly by setting the
useExponentialBackOff option to true."
;-)
Stephan
On Mon, Mar 10, 2014 at 3:11 PM, Keith Freeman <8fo...@gmail.com> wrote:
> Thanks fo
Thanks for the tip on useExponentialBackoff(), several examples I found
using backoffMultiplier() never mentioned that call (including your
book, Camel In Action, page 132 :).
On 03/08/2014 12:23 AM, Claus Ibsen wrote:
Hi
You need to turn on backoff with
useExponentialBackOff()
And debugging
Hi
You need to turn on backoff with
useExponentialBackOff()
And debugging see
http://camel.apache.org/how-do-i-debug-my-route.html
.. and debugging the source is a bit tougher, but see
CamelInternalProcessor which is a central class during Camel routing.
On Fri, Mar 7, 2014 at 10:35 PM, Keith F
I have this code in my route:
onException(Exception.class)
.handled(true)
.maximumRedeliveries(-1)
.redeliveryDelay(1L * 1000L)
.backOffMultiplier(2.0D)
.maximumRedeliveryDelay(60L * 1000L)
.l
I have this code in my route:
onException(Exception.class)
.handled(true)
.maximumRedeliveries(-1)
.redeliveryDelay(1L * 1000L)
.backOffMultiplier(2.0D)
.maximumRedeliveryDelay(60L * 1000L)
.
exchange.getContext().createProducerTemplate().send("mock:myerror",
> exchange);
> }
>
> }
> **
>
> but it doesn't work .
> Where should i put the "OnException(...) on the main program
ext().createProducerTemplate().send("mock:myerror",
exchange);
}
}
**
but it doesn't work .
Where should i put the "OnException(...) on the main program to catch
Exception and stop the program.
--
View this mess
--
View this message in context:
http://camel.465427.n5.nabble.com/onException-problem-tp5507295p5507295.html
Sent from the Camel - Users mailing list archive at Nabble.com.
tails at
http://camel.apache.org/exception-clause.html
>
>
>
>
>
> --
> View this message in context:
> http://camel.465427.n5.nabble.com/OnException-problem-tp4634025p4634025.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>
--
Claus Ibsen
--
View this message in context:
http://camel.465427.n5.nabble.com/OnException-problem-tp4634025p4634025.html
Sent from the Camel - Users mailing list archive at Nabble.com.
12 matches
Mail list logo