cancel
Showing results for 
Search instead for 
Did you mean: 

Several questions regarding activiti

halfsoft
Champ in-the-making
Champ in-the-making
Hello, i have several questions that i hope somebody will be able to answer regarding the usage of activiti.

1. Assuming that we use a remote mysql server (with low ping (around 0.45ms) and proper configuration), history disabled, we start 1 000 000 activiti processes that just are waiting for a timer to continue, so all 1 million are 'suspended' and at a given moment they will continue their execution (and just print to the console using a service task, calling a method in a stateless EJB that has a pool size of 1000).
What is the bottleneck in this situation - the database connection, the async executor? Our tests show that we get around 160-200 executions per second, way too low for our liking, no matter the configuration of the async executor(the configuration seems to affect the speed but this is the best that we got in our initial testing).

2. How long does the async executor stay "alive" to monitor for jobs that need to continue? For example in a servlet we create an activiti engine instance, we start 100 processes that should auto continue tomorrow at the same time, do we need to keep an activiti instance running/in memory in order to have the async executor do its job, or will it start automatically(maybe by setting up a timer) the next day.
2 REPLIES 2

halfsoft
Champ in-the-making
Champ in-the-making
3. What is faster - using JBoss datasource for the DB connection, or specifying the settings manually and providing the mysql libs as part of the deployment.

jbarrez
Star Contributor
Star Contributor
1. How did you configure the Async executor? By default it'll use max 10 threads for example, so wondering what specific setting you had. Also do take in account that a stateless EJB also has the network/container overhead.

2. You need the Activiti engine running such that it can find the jobs when the timer fires. I'm sure i'm understanding the question, how would you expect it to work if you don't have Activiti booted up? If you shut it down and boot it up later, it will execute all timer jobs that are past it's due date.

3. No idea about JBoss datasource performance, but I would not use the default (MyBatis) connection pooling. There are better ones out there.