You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Ravi Gupta 7 <rg...@sapient.com> on 2014/09/16 13:00:23 UTC
BAM Support in Camel - ActivityMonitorEngine-- Failed to process
expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name:
bamB]]. Reason: java.lang.NullPointerException
I have created two activeMQ [bamA and bamB].
Also created a AcctInqProfileCheckActivity as a routeBuilder under camel context.
Below is the overridden configure () method.
When I send a message to bamA using ActiveMQ then it is giving me below error. I am sending message to bam2 after 3 seconds too.
ActivityMonitorEngine - Failed to process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name: bamB]]. Reason: java.lang.NullPointerException
2014-09-16 15:32:36,793 [tyMonitorEngine] ERROR ActivityMonitorEngine - - - Failed to process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name: b
java.lang.NullPointerException
at org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:322)
at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)
at org.apache.camel.processor.Pipeline.process(Pipeline.java:118)
at org.apache.camel.processor.Pipeline.process(Pipeline.java:80)
at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:105)
at org.apache.camel.processor.Pipeline.process(Pipeline.java:60)
at org.apache.camel.bam.rules.TemporalRule.processExpired(TemporalRule.java:147)
at org.apache.camel.bam.rules.ActivityRules.processExpired(ActivityRules.java:57)
at org.apache.camel.bam.rules.ProcessRules.processExpired(ProcessRules.java:38)
at org.apache.camel.bam.processor.ActivityMonitorEngine$2.execute(ActivityMonitorEngine.java:123)
at org.apache.camel.bam.EntityManagerTemplate.execute(EntityManagerTemplate.java:41)
at org.apache.camel.bam.processor.ActivityMonitorEngine.fireExpiredEvent(ActivityMonitorEngine.java:113)
at org.apache.camel.bam.processor.ActivityMonitorEngine$1.doInTransactionWithoutResult(ActivityMonitorEngine.java:90)
at org.springframework.transaction.support.TransactionCallbackWithoutResult.doInTransaction(TransactionCallbackWithoutResult.java:33)
at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:131)
at org.apache.camel.bam.processor.ActivityMonitorEngine.run(ActivityMonitorEngine.java:80)
at java.lang.Thread.run(Thread.java:745)
@Override
public void configure() throws Exception {
log.debug("Activity running.........");
System.out.println("Activity running.........");
// let's define some activities, correlating on an XPath on the message
// bodies
ActivityBuilder customerEnquiryActivity = activity("activemq:bamA")
.name("bamA").correlate(header("JMSCorrelationId"));
ActivityBuilder customerProfileCheck = activity("activemq:bamB").name(
"bamB").correlate(header("JMSCorrelationId"));
// now let's add some BAM rules
customerProfileCheck
.starts()
.after(customerEnquiryActivity.completes())
.expectWithin(seconds(this.expectedTime))
.errorIfOver(seconds(this.timeOut))
.log(LoggingLevel.DEBUG, log,
"Time Out Error" + header("JMSCorrelationId"))
.throwException(
new BusinessException("Time Out Error :: "
+ header("JMSCorrelationId")))
.to("activemq:bamC");
}
Thanks
RG
Re: BAM Support in Camel - ActivityMonitorEngine-- Failed to process
expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name:
bamB]]. Reason: java.lang.NullPointerException
Posted by Claus Ibsen <cl...@gmail.com>.
Hi
Try with Camel 2.13.2 or the upcoming 2.14.0.
On Tue, Sep 16, 2014 at 1:00 PM, Ravi Gupta 7 <rg...@sapient.com> wrote:
> I have created two activeMQ [bamA and bamB].
> Also created a AcctInqProfileCheckActivity as a routeBuilder under camel context.
> Below is the overridden configure () method.
>
> When I send a message to bamA using ActiveMQ then it is giving me below error. I am sending message to bam2 after 3 seconds too.
>
> ActivityMonitorEngine - Failed to process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name: bamB]]. Reason: java.lang.NullPointerException
> 2014-09-16 15:32:36,793 [tyMonitorEngine] ERROR ActivityMonitorEngine - - - Failed to process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name: b
> java.lang.NullPointerException
> at org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:322)
> at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)
> at org.apache.camel.processor.Pipeline.process(Pipeline.java:118)
> at org.apache.camel.processor.Pipeline.process(Pipeline.java:80)
> at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:105)
> at org.apache.camel.processor.Pipeline.process(Pipeline.java:60)
> at org.apache.camel.bam.rules.TemporalRule.processExpired(TemporalRule.java:147)
> at org.apache.camel.bam.rules.ActivityRules.processExpired(ActivityRules.java:57)
> at org.apache.camel.bam.rules.ProcessRules.processExpired(ProcessRules.java:38)
> at org.apache.camel.bam.processor.ActivityMonitorEngine$2.execute(ActivityMonitorEngine.java:123)
> at org.apache.camel.bam.EntityManagerTemplate.execute(EntityManagerTemplate.java:41)
> at org.apache.camel.bam.processor.ActivityMonitorEngine.fireExpiredEvent(ActivityMonitorEngine.java:113)
> at org.apache.camel.bam.processor.ActivityMonitorEngine$1.doInTransactionWithoutResult(ActivityMonitorEngine.java:90)
> at org.springframework.transaction.support.TransactionCallbackWithoutResult.doInTransaction(TransactionCallbackWithoutResult.java:33)
> at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:131)
> at org.apache.camel.bam.processor.ActivityMonitorEngine.run(ActivityMonitorEngine.java:80)
> at java.lang.Thread.run(Thread.java:745)
> @Override
> public void configure() throws Exception {
> log.debug("Activity running.........");
> System.out.println("Activity running.........");
>
> // let's define some activities, correlating on an XPath on the message
> // bodies
> ActivityBuilder customerEnquiryActivity = activity("activemq:bamA")
> .name("bamA").correlate(header("JMSCorrelationId"));
>
> ActivityBuilder customerProfileCheck = activity("activemq:bamB").name(
> "bamB").correlate(header("JMSCorrelationId"));
>
> // now let's add some BAM rules
>
> customerProfileCheck
> .starts()
> .after(customerEnquiryActivity.completes())
> .expectWithin(seconds(this.expectedTime))
> .errorIfOver(seconds(this.timeOut))
> .log(LoggingLevel.DEBUG, log,
> "Time Out Error" + header("JMSCorrelationId"))
> .throwException(
> new BusinessException("Time Out Error :: "
> + header("JMSCorrelationId")))
> .to("activemq:bamC");
>
> }
>
> Thanks
> RG
--
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen
hawtio: http://hawt.io/
fabric8: http://fabric8.io/
RE: BAM Support in Camel - ActivityMonitorEngine-- Failed to
process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1
name: bamB]]. Reason: java.lang.NullPointerException
Posted by Ravi Gupta 7 <rg...@sapient.com>.
Version -I am using is --> Camel - core 2.13.1.jar / Camel-bam 2.13.1.jar
-----Original Message-----
From: Ravi Gupta 7 [mailto:rgupta76@sapient.com]
Sent: Wednesday, September 17, 2014 12:37 PM
To: claus.ibsen@gmail.com; users@camel.apache.org
Subject: RE: BAM Support in Camel - ActivityMonitorEngine-- Failed to process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name: bamB]]. Reason: java.lang.NullPointerException
Hi Claus,
Version -I am using is --> Camel - core 2.13.1.jar / Camel-bam 2.13.1.jar
-----Original Message-----
From: Claus Ibsen [mailto:claus.ibsen@gmail.com]
Sent: Wednesday, September 17, 2014 12:30 PM
To: users@camel.apache.org
Subject: Re: BAM Support in Camel - ActivityMonitorEngine-- Failed to process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name: bamB]]. Reason: java.lang.NullPointerException
What version of Camel do you use?
On Tue, Sep 16, 2014 at 1:00 PM, Ravi Gupta 7 <rg...@sapient.com> wrote:
> I have created two activeMQ [bamA and bamB].
> Also created a AcctInqProfileCheckActivity as a routeBuilder under camel context.
> Below is the overridden configure () method.
>
> When I send a message to bamA using ActiveMQ then it is giving me below error. I am sending message to bam2 after 3 seconds too.
>
> ActivityMonitorEngine - Failed to process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name: bamB]]. Reason: java.lang.NullPointerException
> 2014-09-16 15:32:36,793 [tyMonitorEngine] ERROR ActivityMonitorEngine - - - Failed to process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name: b
> java.lang.NullPointerException
> at org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:322)
> at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)
> at org.apache.camel.processor.Pipeline.process(Pipeline.java:118)
> at org.apache.camel.processor.Pipeline.process(Pipeline.java:80)
> at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:105)
> at org.apache.camel.processor.Pipeline.process(Pipeline.java:60)
> at org.apache.camel.bam.rules.TemporalRule.processExpired(TemporalRule.java:147)
> at org.apache.camel.bam.rules.ActivityRules.processExpired(ActivityRules.java:57)
> at org.apache.camel.bam.rules.ProcessRules.processExpired(ProcessRules.java:38)
> at org.apache.camel.bam.processor.ActivityMonitorEngine$2.execute(ActivityMonitorEngine.java:123)
> at org.apache.camel.bam.EntityManagerTemplate.execute(EntityManagerTemplate.java:41)
> at org.apache.camel.bam.processor.ActivityMonitorEngine.fireExpiredEvent(ActivityMonitorEngine.java:113)
> at org.apache.camel.bam.processor.ActivityMonitorEngine$1.doInTransactionWithoutResult(ActivityMonitorEngine.java:90)
> at org.springframework.transaction.support.TransactionCallbackWithoutResult.doInTransaction(TransactionCallbackWithoutResult.java:33)
> at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:131)
> at org.apache.camel.bam.processor.ActivityMonitorEngine.run(ActivityMonitorEngine.java:80)
> at java.lang.Thread.run(Thread.java:745)
> @Override
> public void configure() throws Exception {
> log.debug("Activity running.........");
> System.out.println("Activity running.........");
>
> // let's define some activities, correlating on an XPath on the message
> // bodies
> ActivityBuilder customerEnquiryActivity = activity("activemq:bamA")
> .name("bamA").correlate(header("JMSCorrelationId"));
>
> ActivityBuilder customerProfileCheck = activity("activemq:bamB").name(
> "bamB").correlate(header("JMSCorrelationId"));
>
> // now let's add some BAM rules
>
> customerProfileCheck
> .starts()
> .after(customerEnquiryActivity.completes())
> .expectWithin(seconds(this.expectedTime))
> .errorIfOver(seconds(this.timeOut))
> .log(LoggingLevel.DEBUG, log,
> "Time Out Error" + header("JMSCorrelationId"))
> .throwException(
> new BusinessException("Time Out Error :: "
> + header("JMSCorrelationId")))
> .to("activemq:bamC");
>
> }
>
> Thanks
> RG
--
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen
hawtio: http://hawt.io/
fabric8: http://fabric8.io/
RE: BAM Support in Camel - ActivityMonitorEngine-- Failed to
process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1
name: bamB]]. Reason: java.lang.NullPointerException
Posted by Ravi Gupta 7 <rg...@sapient.com>.
Hi Claus,
Version -I am using is --> Camel - core 2.13.1.jar / Camel-bam 2.13.1.jar
-----Original Message-----
From: Claus Ibsen [mailto:claus.ibsen@gmail.com]
Sent: Wednesday, September 17, 2014 12:30 PM
To: users@camel.apache.org
Subject: Re: BAM Support in Camel - ActivityMonitorEngine-- Failed to process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name: bamB]]. Reason: java.lang.NullPointerException
What version of Camel do you use?
On Tue, Sep 16, 2014 at 1:00 PM, Ravi Gupta 7 <rg...@sapient.com> wrote:
> I have created two activeMQ [bamA and bamB].
> Also created a AcctInqProfileCheckActivity as a routeBuilder under camel context.
> Below is the overridden configure () method.
>
> When I send a message to bamA using ActiveMQ then it is giving me below error. I am sending message to bam2 after 3 seconds too.
>
> ActivityMonitorEngine - Failed to process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name: bamB]]. Reason: java.lang.NullPointerException
> 2014-09-16 15:32:36,793 [tyMonitorEngine] ERROR ActivityMonitorEngine - - - Failed to process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name: b
> java.lang.NullPointerException
> at org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:322)
> at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)
> at org.apache.camel.processor.Pipeline.process(Pipeline.java:118)
> at org.apache.camel.processor.Pipeline.process(Pipeline.java:80)
> at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:105)
> at org.apache.camel.processor.Pipeline.process(Pipeline.java:60)
> at org.apache.camel.bam.rules.TemporalRule.processExpired(TemporalRule.java:147)
> at org.apache.camel.bam.rules.ActivityRules.processExpired(ActivityRules.java:57)
> at org.apache.camel.bam.rules.ProcessRules.processExpired(ProcessRules.java:38)
> at org.apache.camel.bam.processor.ActivityMonitorEngine$2.execute(ActivityMonitorEngine.java:123)
> at org.apache.camel.bam.EntityManagerTemplate.execute(EntityManagerTemplate.java:41)
> at org.apache.camel.bam.processor.ActivityMonitorEngine.fireExpiredEvent(ActivityMonitorEngine.java:113)
> at org.apache.camel.bam.processor.ActivityMonitorEngine$1.doInTransactionWithoutResult(ActivityMonitorEngine.java:90)
> at org.springframework.transaction.support.TransactionCallbackWithoutResult.doInTransaction(TransactionCallbackWithoutResult.java:33)
> at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:131)
> at org.apache.camel.bam.processor.ActivityMonitorEngine.run(ActivityMonitorEngine.java:80)
> at java.lang.Thread.run(Thread.java:745)
> @Override
> public void configure() throws Exception {
> log.debug("Activity running.........");
> System.out.println("Activity running.........");
>
> // let's define some activities, correlating on an XPath on the message
> // bodies
> ActivityBuilder customerEnquiryActivity = activity("activemq:bamA")
> .name("bamA").correlate(header("JMSCorrelationId"));
>
> ActivityBuilder customerProfileCheck = activity("activemq:bamB").name(
> "bamB").correlate(header("JMSCorrelationId"));
>
> // now let's add some BAM rules
>
> customerProfileCheck
> .starts()
> .after(customerEnquiryActivity.completes())
> .expectWithin(seconds(this.expectedTime))
> .errorIfOver(seconds(this.timeOut))
> .log(LoggingLevel.DEBUG, log,
> "Time Out Error" + header("JMSCorrelationId"))
> .throwException(
> new BusinessException("Time Out Error :: "
> + header("JMSCorrelationId")))
> .to("activemq:bamC");
>
> }
>
> Thanks
> RG
--
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen
hawtio: http://hawt.io/
fabric8: http://fabric8.io/
Re: BAM Support in Camel - ActivityMonitorEngine-- Failed to process
expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name:
bamB]]. Reason: java.lang.NullPointerException
Posted by Claus Ibsen <cl...@gmail.com>.
What version of Camel do you use?
On Tue, Sep 16, 2014 at 1:00 PM, Ravi Gupta 7 <rg...@sapient.com> wrote:
> I have created two activeMQ [bamA and bamB].
> Also created a AcctInqProfileCheckActivity as a routeBuilder under camel context.
> Below is the overridden configure () method.
>
> When I send a message to bamA using ActiveMQ then it is giving me below error. I am sending message to bam2 after 3 seconds too.
>
> ActivityMonitorEngine - Failed to process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name: bamB]]. Reason: java.lang.NullPointerException
> 2014-09-16 15:32:36,793 [tyMonitorEngine] ERROR ActivityMonitorEngine - - - Failed to process expiration of: ActivityState[19 on ProcessInstance[44] Activity[1 name: b
> java.lang.NullPointerException
> at org.apache.camel.processor.RedeliveryErrorHandler.process(RedeliveryErrorHandler.java:322)
> at org.apache.camel.processor.CamelInternalProcessor.process(CamelInternalProcessor.java:191)
> at org.apache.camel.processor.Pipeline.process(Pipeline.java:118)
> at org.apache.camel.processor.Pipeline.process(Pipeline.java:80)
> at org.apache.camel.util.AsyncProcessorHelper.process(AsyncProcessorHelper.java:105)
> at org.apache.camel.processor.Pipeline.process(Pipeline.java:60)
> at org.apache.camel.bam.rules.TemporalRule.processExpired(TemporalRule.java:147)
> at org.apache.camel.bam.rules.ActivityRules.processExpired(ActivityRules.java:57)
> at org.apache.camel.bam.rules.ProcessRules.processExpired(ProcessRules.java:38)
> at org.apache.camel.bam.processor.ActivityMonitorEngine$2.execute(ActivityMonitorEngine.java:123)
> at org.apache.camel.bam.EntityManagerTemplate.execute(EntityManagerTemplate.java:41)
> at org.apache.camel.bam.processor.ActivityMonitorEngine.fireExpiredEvent(ActivityMonitorEngine.java:113)
> at org.apache.camel.bam.processor.ActivityMonitorEngine$1.doInTransactionWithoutResult(ActivityMonitorEngine.java:90)
> at org.springframework.transaction.support.TransactionCallbackWithoutResult.doInTransaction(TransactionCallbackWithoutResult.java:33)
> at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:131)
> at org.apache.camel.bam.processor.ActivityMonitorEngine.run(ActivityMonitorEngine.java:80)
> at java.lang.Thread.run(Thread.java:745)
> @Override
> public void configure() throws Exception {
> log.debug("Activity running.........");
> System.out.println("Activity running.........");
>
> // let's define some activities, correlating on an XPath on the message
> // bodies
> ActivityBuilder customerEnquiryActivity = activity("activemq:bamA")
> .name("bamA").correlate(header("JMSCorrelationId"));
>
> ActivityBuilder customerProfileCheck = activity("activemq:bamB").name(
> "bamB").correlate(header("JMSCorrelationId"));
>
> // now let's add some BAM rules
>
> customerProfileCheck
> .starts()
> .after(customerEnquiryActivity.completes())
> .expectWithin(seconds(this.expectedTime))
> .errorIfOver(seconds(this.timeOut))
> .log(LoggingLevel.DEBUG, log,
> "Time Out Error" + header("JMSCorrelationId"))
> .throwException(
> new BusinessException("Time Out Error :: "
> + header("JMSCorrelationId")))
> .to("activemq:bamC");
>
> }
>
> Thanks
> RG
--
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cibsen@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen
hawtio: http://hawt.io/
fabric8: http://fabric8.io/