Throttler and Delay EIP will invoke done callback twice if using async delayed
------------------------------------------------------------------------------
Key: CAMEL-4795
URL: https://issues.apache.org/jira/browse/CAMEL-4795
Project: Camel
Issue Type: Bug
Components: camel-core
Affects Versions: 2.8.3, 2.7.4
Reporter: Claus Ibsen
Assignee: Claus Ibsen
Fix For: 2.7.5, 2.8.4, 2.9.0
If using async delayed on Throttler or Delay EIP, then a 2nd done on the
callback is invoked, which should not happen. As the Camel routing engine, is
invoking the done as well.
The 2nd done can cause what would appear as a routing error as a NPE occurs in
the error handler, as the exchange is already done, and some cleanup work have
occurred.
{code}
java.lang.NullPointerException
at
org.apache.camel.processor.RedeliveryErrorHandler.processAsyncErrorHandler(RedeliveryErrorHandler.java:387)
at
org.apache.camel.processor.RedeliveryErrorHandler$1.done(RedeliveryErrorHandler.java:336)
at org.apache.camel.processor.interceptor.Debug$1$1.done(Debug.java:56)
at
org.apache.camel.processor.interceptor.TraceInterceptor$1.done(TraceInterceptor.java:188)
at org.apache.camel.impl.ProducerCache$1.done(ProducerCache.java:307)
...
{code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira