cancel
Showing results for 
Search instead for 
Did you mean: 

Problem with jobExecutor when set to true

ganeshr
Champ in-the-making
Champ in-the-making
Hi,

  I have created a standalone application in which the process engine is running. This application was running fine when jobExecutor is set to false but when I set it to true the problems started. When trying to retrieve the tasks for process instance id using the below statements
TaskQuery taskQuery =
          taskService.createTaskQuery().processInstanceId(businessProcessId);
      task = taskQuery.singleResult();

program is getting struck when taskQuery.singleResult() statement is executed. This statement is not returning any result and its getting struck. Here is the log statement

09-Jul-2013[01:46:14.812]:Smiley Very HappyEBUG::listenerContainer-1:Smiley Surprisedrg.activiti.engine.impl.interceptor.LogInterceptor:33 -
09-Jul-2013[01:46:14.813]:Smiley Very HappyEBUG::listenerContainer-1:Smiley Surprisedrg.activiti.engine.impl.interceptor.LogInterceptor:34 - — starting TaskQueryImpl

After this I'm not seeing anything in my log and my program is getting hanged after that.

I'm attaching the activiti context file and I'm using Oracle as a database. I'm guessing may be the problem is with transaction manager. If that is the root cause of this issue, can anyone provide how exactly transaction manager is to be configured for standalone applications.

3 REPLIES 3

frederikherema1
Star Contributor
Star Contributor
What are the defaults for org.apache.commons.dbcp.BasicDataSource in terms of number of connections? Make sure enough connections are available, the job-executor takes at least 1 every now and then to check for jobs and an additional one when executing a single job…

I have not given any defaults for org.apache.commons.dbcp.BasicDataSource. As per doc it says it will have max 8 active connections.
Do you mean to increase this active connections to much more?

jbarrez
Star Contributor
Star Contributor
Indeed, I saw the behaviour too before: http://www.jorambarrez.be/blog/2012/04/30/dbcp_vs_c3p0_bonecp/