The “Timer intermediate event” has duration “PT10S”. Ideally, it should wait for 10s and then move to the next user task. However, it doesn’t fire at all. I have to stop my local spring boot application and restart it. Then the process instance moves to the next user task.
My SpringProcessEngineConfiguration is:
SpringProcessEngineConfiguration config = new SpringProcessEngineConfiguration();
config.setDataSource(dataSource());
config.setTransactionManager(dataSourceTransactionManager());
config.setDatabaseSchemaUpdate(
ProcessEngineConfiguration.DB_SCHEMA_UPDATE_FALSE); // If DB schema doesn't match, throw the exception.
config.setDeploymentResources(processDefinitionResources); // Auto deploy bpmn files
config.setAsyncExecutorActivate(true); // Enable async executor for external service task.
config.setDisableIdmEngine(true);
Can you please share a simple reproducible project where we can try this? It is strange that it does not fire at all. If you are not using our out-of-the-box spring boot starter, perhaps you have some misconfiguration in your setup.
another way around this, instead of the Timer intermediate event: add a sample user task (which acts as a timer) and attach to it a boundary timer event which cancels the user task and process to the next items in the flow.
In my real BPMN workflow, I have both Timer intermediate event and Timer boundary event. None of them works. That’s why I created the simplest workflow for troubleshooting, and it still doesn’t work. It seems like I have some misconfiguration wrong.
The demo app is set up with h2 mem database now. Once you kick off a new instance, it never moves to the next user task.
I also commented SQL Server data source. If you replace those placeholders with your DB Info, you can repro the other behavior I mentioned above: the instance doesn’t move from the timer to the next user task. But if you stop the application and restart it, it will move to the next user task.
I see that you have added the Flowable Spring Boot starters. Is there a reason for the FlowableProcessEngineConfiguration and FlowableProcessEngineConfiguration?
If I get rid of those 2 classes. And adjust the application properties to:
The reason I have those two configuration classes is because the open source document mentioned I need to start with a configuration.
Few more questions:
It seems like the starter (or the autoconfigure) dependency is conflict with SpringProcessEngineConfiguration. Do you know why?
My company manages DB update separately. So I should use flowable.database-schema-update=false to stop the engine updating the DB schema if they don’t match. Is that right?
Just curious. If I wish to create the configuration with code, which dependencies I should use?