long story short, while testing a class that starts Processes, i ran into unexpected results while trying to start the same Process twice with the same Businesskey:
@Test (expected = IllegalArgumentException.class)
@Deployment(resources = {"test_process.bpmn"})
public void startProcess_duplicateBkey() {
rule.getRuntimeService().startProcessInstanceByKey("test_process", "a1");
rule.getRuntimeService().startProcessInstanceByKey("test_process", "a1");
System.out.println(rule.getRuntimeService().createProcessInstanceQuery().processInstanceBusinessKey("a1", "test_process").list().size());
}
prints "2".I thus have two instances of "test_process" with businesskey "a1". In my understanding, this should not be possible, should it?