A parent process starts some parallel sub processes and this sub processes are sending signals.
The parent process is waiting for the signals.
Is it possible to miss fired signals from the started processes?
I tested it and even with a Thread.sleep in an end listener intermediateCatchEvent I got all throwed signals.
So everything is fine and I am happy about that.
I thought it could be possible to miss when I just received a signal and I am in the loop afterwards.
I also thought in my MultiInstance loop I will produce a number of threads but the sending task and receiving of tasks happens all in the same java thread.
In general, yes, it is. Signals are not buffered. So, if the signal is fired but the instance is not waiting in a catch-signal-event then the instance will not receive the signal.
Your example works because the signal is sent synchronously. That means, the job for the async start event send the signal and waits until the receiving instance reaches a wait state. The next wait state is the catch-signal-event.
If a second job runs in parallel then both jobs would modify the same instance. This causes an optimistic lock exception. One job is rolled back and will be retried later.
A multi-instance loop doesnโt create threads. The execution always happens synchronously in one thread.
But because of the async-start-event, it will create jobs which are executed by the job executor. By default, the job executor has 10 threads. Please see the docs for details.