This content has been marked as final.
Show 1 reply
-
1. Re: Ensure consistency of logging
jbarrez Apr 9, 2009 4:27 AM (in response to thomas.kriechbaum)Simply call the jBPMContext.save(processInstance) operation before the close() method is invoked.
The logging for the process instance, including the subprocesses, will be stored in the log table.
For a task, you should doJbpmContext context = ...; TaskInstance task = context.getTaskInstance(id); task.end(); context.save(task.getProcessInstance); context.close();
Or, better, use the jBPM command service. The commands automatically save the process instance (and closes the context):TaskEndCommand command = new TaskEndCommand(taskId); commandService.execute(command);