.behavior(new ParallelGateway())
.transition("c1")
.transition("c2")
.endActivity()
.createActivity("c1")
.behavior(new WaitState())
.transition("join")
.endActivity()
.createActivity("c2")
.behavior(new WaitState())
.transition("join")
.endActivity()
.createActivity("join")
.behavior(new ParallelGateway())
.transition("end")
.endActivity()
.createActivity("end")
.behavior(new WaitState())
.endActivity()
.buildProcessDefinition();
PvmProcessInstance processInstance = processDefinition.createProcessInstance();
processInstance.start();