cancel
Showing results for 
Search instead for 
Did you mean: 

Parallel Gateway and Java Concurreny with Java Service Task

rdewall
Champ in-the-making
Champ in-the-making
Currently, the Parallel Gateway does not guarantee (nor support I don't think) concurrency of Java Service Tasks, as from what I can tell, the tasks are executed sequentially.

1)  Is there plans to support concurrency of Java Service Tasks used with Parallel Gateways?
2)  Is there a recommended method to mimic this true parallelism with Java Service Tasks?
6 REPLIES 6

jbarrez
Star Contributor
Star Contributor
No, parallel refers to 'business concurrency', not to actual threading.

Secondly, having 'real' concurrency mixed with the transactions of executing the process is asking for troubles: synchronisations, race conditions, etc. So in the end, in our opinion, it's just not worth it.

jherryft
Champ in-the-making
Champ in-the-making
This is too bad… why will I use parallel gateways if you execute task sequentially?
I need this functionnality to work, do you have a work around?
Thank you.

tombaeyens
Champ in-the-making
Champ in-the-making
there is a workaround (a rather heavy one)

for each parallel branch, you send a message (jms or so) and then introduce a wait state.  once that transaction commits, the message listener of the queue will be called and that should just send a signal to the execution. 

that principle is what we call an asynchronous continuation.  it's on our roadmap, but we can't tell at this point when it will make it into a concrete release.

filipearaujo
Champ in-the-making
Champ in-the-making
jherryft, did you get a workaround?

ronald_van_kuij
Champ on-the-rise
Champ on-the-rise
the 'workaround' is described above. But you can also try the sourcecode and look at async continuations.

jherryft
Champ in-the-making
Champ in-the-making
I used the workaround given by tombaeyens.