JBoss Community

Unknown error using timer in JEE

created by Francesco Pietrobelli in jBPM - View the full discussion

Hi all,

I have a JEE application with jBPM embedded and I have a process that during his execution flow he reaches a intermediate timer catch event. And so the session with that process is disposed. My problem arises when I load the session after the timer is triggered, particularly, the thrown exception is:

 

2011-08-05 17:03:54,659 ERROR org.drools.persistence.SingleSessionCommandService (pool-26-thread-1) Could not commit session

java.lang.NullPointerException

          at org.drools.persistence.jpa.JpaPersistenceContextManager.beginCommandScopedEntityManager(JpaPersistenceContextManager.java:67)

          at org.drools.persistence.SingleSessionCommandService.execute(SingleSessionCommandService.java:287)

          at org.drools.persistence.jpa.JpaJDKTimerService$JpaJDKCallableJob.call(JpaJDKTimerService.java:75)

          at org.drools.persistence.jpa.JpaJDKTimerService$JpaJDKCallableJob.call(JpaJDKTimerService.java:63)

          at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)

          at java.util.concurrent.FutureTask.run(FutureTask.java:166)

          at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:165)

          at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:266)

          at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)

          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)

          at java.lang.Thread.run(Thread.java:636)

 

 

This is the entire stack trace and I haven't any additional information for understand what happened.

 

Moreover the thread that throws the NPE is different from thread that load the session. Anybody know where to find some information about jBPM threading model?

 

I can't attach a junit test because i have this problem only when i deploy my application in JBoss5.1, whereas the same process tested with the help of JbpmJunitTestCase doesn't generate any errors.

 

Regards,

Francesco.

Reply to this message by going to Community

Start a new discussion in jBPM at Community