cancel
Showing results for 
Search instead for 
Did you mean: 

Problem Setup AsyncExecutor with Spring on Oracle

gehen
Champ in-the-making
Champ in-the-making
Hi there,

currently i have a problem setting up activiti with asyncexecutor like described in user guide. it can not fetch the transaction.


2015-08-06 13:50:06,972 INFO  org.activiti.engine.impl.ProcessEngineImpl [http-nio-8080-exec-5] ProcessEngine default created
2015-08-06 13:50:06,974 INFO  org.activiti.engine.impl.asyncexecutor.DefaultAsyncJobExecutor [http-nio-8080-exec-5] Starting up the default async job executor [org.activiti.engine.impl.asyncexecutor.DefaultAsyncJobExecutor].
2015-08-06 13:50:06,975 INFO  org.activiti.engine.impl.asyncexecutor.DefaultAsyncJobExecutor [http-nio-8080-exec-5] Creating thread pool queue of size 100
2015-08-06 13:50:06,975 INFO  org.activiti.engine.impl.asyncexecutor.DefaultAsyncJobExecutor [http-nio-8080-exec-5] Creating executor service with corePoolSize 2, maxPoolSize 10 and keepAliveTime 5000
2015-08-06 13:50:06,976 INFO  org.activiti.engine.impl.asyncexecutor.AcquireTimerJobsRunnable [Thread-12] {} starting to acquire async jobs due
2015-08-06 13:50:06,976 INFO  org.activiti.engine.impl.asyncexecutor.AcquireAsyncJobsDueRunnable [Thread-13] {} starting to acquire async jobs due
2015-08-06 13:50:06,977 ERROR  org.activiti.engine.impl.asyncexecutor.AcquireAsyncJobsDueRunnable [Thread-13] exception during async job acquisition: Could not open JDBC Connection for transaction; nested exception is java.lang.NullPointerException org.springframework.transaction.CannotCreateTransactionException: Could not open JDBC Connection for transaction; nested exception is java.lang.NullPointerException
   at org.springframework.jdbc.datasource.DataSourceTransactionManager.doBegin(DataSourceTransactionManager.java:243)


the config is


<bean id="processEngineConfiguration" class="org.activiti.spring.SpringProcessEngineConfiguration">
      <property name="dataSource" ref="dataSource"/>
      <property name="transactionManager" ref="transactionManager"/>
      <property name="jobExecutorActivate" value="false"/>
      <property name="asyncExecutorEnabled" value="true"/>
      <property name="asyncExecutorActivate" value="true"/>
                 <property name="deploymentResources" value="pathtoresourses"/>
   </bean>

   <bean id="processEngine" class="org.activiti.spring.ProcessEngineFactoryBean">
      <property name="processEngineConfiguration" ref="processEngineConfiguration"/>
   </bean>



Maybe someone can help if there is a problem with the setup.
1 REPLY 1

gehen
Champ in-the-making
Champ in-the-making
just dove more into it. we have a setup for datasource with more than one tenant. this is resolved via threadlocal but seems like not populated when in asyncExecutor spans new threads. is there a way to hook into?