Hello,
IIUC, a process instance is actually persisted when entering a wait node or finishing.
I have a process with non-wait (action) nodes that may last very long (hours) themselves. They are calls to remote clusters so while long, they are not resource-hungry. There is a business need to trace process execution from step to step and I wonder if there are some good practices to follow on this issue.
If I simply do, in each action :
executionContext.getJbpmContext().save(executionContext.getProcessInstance()); executionContext.getJbpmContext().getSessionFactory().getCurrentSession().flush();