If I load from cache in a child process would I be able to use the documents in it's parent process as well as the other sub-processes of the parent process?
Yes. Think of Document Caches as having "execution scope" that can be read from and written to across parent and child processes. Same as Process Properties.
Tech note for rare scenarios: if you are using Flow Control parallel processing or execute Process Calls with "Wait for subprocess to complete"=false, cache contents may not be synchronized.
Thank you Adam
how about using them in sibling processes can i access them in another child of same process
If the subprocesses are all part of the same overall execution, then yes.
On contrary if you have two independently executing (scheduled or real time) processes that reference the same Document Cache component, they will not share the same contents of that cache during execution.
Adam Arrowsmith, I am having an issue with cache in a subprocess. I must be missing some important aspect of documents processing, perhaps you could explain what is happening please?
So my process has a decision shape that checks the document cache for a particular record based on the document attributes coming into the shape. If a record is not found in cache, I do a connector call to add the record to the database, then add it to cache, so that I don't add a duplicate to the database once it comes in again. Say, orders are records coming into the shape and order customers are records that I add to the database and then cache. Makes sense so far?
Before the decision shape, I split my documents in the parent process, so each order record comes in as a separate document. Both orders in the example below happen to have the same customer. Now, I thought they'd be executed sequentially and the first one goes through to the connector and gets added to cache on the other side of the connector. Then the second order would get to the decision shape, be found in cache and routed past the connector to the stop shape. But the second order seems to go the same way, cached record is not found (I double checked the decision shape contents, it's got the right profile data coming in and I'm using the right link to cache, etc).
Is there anything I am not doing right or is this expected behaviour?
Hi Maria Schmidt,
This is one of the rare situations in which you'll want to use a Flow Control shape configured to "Run Documents Individually". Add this before your "Does Client existing in Cache" decisions shape.
Why? Documents move through the process as a "group": all documents execute (in order) on shape 1, then all docs move to shape 2, and so on. In situations like this existence check scenario, you need to change the execution flow using a Flow Control shape to have the docs process one-by-one instead through the remainder of the shapes.
The free LMS course on Document Flow does a great job of explaining and illustrating this concept.
Adam Arrowsmith Beautiful, all working as expected now.
Thanks heaps for the explanation, and I'll get to that LMS course eventually.
Retrieving data ...