Hi all,I have a doubt is there a possibility we could have a race condition problem when appending from parallel process nodes to the same pv array? I have a following situation:
So, I am generating several documents in parallel. Some of them will be generated, some of them will be skipped (based on ContractX gateways decision). When generated, I would like to add them as a document cdt instance to the array of document cdts stored in a process variable. So in each yellow marked script task I am using (on output tab) :I usually didn't have problems with possible race condition. But, in theory, is this 100% safe method? Is there a possibility multiple 'Add to docs array' nodes are executed on different process engines and execution happens exectly at the same time and there is a possibility of data loss (some items are not added to the array because 2 engines had different state of the array)?I know there is a workaround where we can merge all parts of the array after AND joining node...
Discussion posts and replies are publicly visible
Process execution engines run the full process. Individual nodes are not distributed.
Peter Lewis , can you help us with some insights? I would expect that parallel append operations on a PV should be OK.
Yeah I wouldn't expect any issues with running append operations on PVs in parallel paths. Even thought they may both be executing in parallel, they still would save their results to the variable in sequence.
Thank you for making this clear :-)