Quering all process tasks from caseInstance (CMMN)

Hi there,
I have a simple CMMN diagram with only one task (Process Task, Manual Activation Rule checked). CaseInstance is created:
CaseInstance caseInstance = caseService.createCaseInstanceByKey("recruitment");
How can I run the process using Java API? How can I list all available process?
Thanks!

Hi @dikey94,

You can start a case task via caseService.manuallyStartCaseExecution(aCaseExecutionId); where aCaseExecutionId is the ID of the case execution responsible for that task. You can obtain that via CaseService#createCaseExecutionQuery and for example filtering via activity id. Currently there is no filter for task type. The best I can think of is fetching all case executions and then manually filtering via CaseExecution#getActivityType.

Cheers,
Thorben

Thanks. It helps.
Regards!