Leveraging activity-chaining

Certified Associate Developer

Hi everyone,

Hope everyone is doing well and safe.

Can any one help me with Leveraging activity-chaining with example.?

How can we pass data from one process to other process by using start process smart service?

Thank you all in advance!

Regards,

Kiran Sajjan

  Discussion posts and replies are publicly visible

  • Interestingly it is technically still valid to use a form on any node that allows it (including nodes that aren't User Input Tasks). If you do this, it will correctly generate a task that is visible in the tasks feed, and it can be completed and save outputs just like a user Input Task.

    However, there are a few reasons why almost no one does this in practice:

    • Saving data is a bit strange. In most cases you want to guarantee that one activity occurs before another (e.g. saving the data on a form occurs before starting a process). However, since activity class parameters are evaluated in parallel, this isn't guaranteed to happen. It's usually much better to separate out the User Input Task ahead of the next node to guarantee the order of operations.
    • Debugging is also harder if you combined everything together into a single node, as the process history can't provide granular enough detail to give context for what occurred within a node.

    For those reasons, it's best practice to not use the Forms tab within any node except for User Input tasks.

  • 0
    Certified Lead Developer
    in reply to Peter Lewis

    Thank you very much for this excellent description . Very much appreciated :-)

  • 0
    Certified Associate Developer
    in reply to Peter Lewis

    Thank you very much for clarifying my doubts.

  • 0
    Certified Associate Developer
    in reply to Stefan Helzle

    Thank you for your great help in clarifying my doubts .

  • 0
    Certified Associate Developer

    Hi Kiran,

    If you mean how to get data output returned from the proces initiated via the start process smart service you have to use activity chaining in the child right from the first node. The parent will wait for the last chained node in the child to finish before the parent proceeds to the next node. This way the behavior of the start process smart service is kind of synchronize and you will be able to fetch the output of the child process in the node's that follow after the start process smart service node. the pv's of the child are returned in a array of pv's. To initiate the child process via start process smartservice in via a dictionary with the data regarding to the parameters of the child process to be started. If you don't chain the nodes in the child the pv's will be null if you fetch them in the next node because default behavior is async, so the next node in the parent will not get updated data in the child because it executed before the child was finished with updating the data.

    Regards,

    Erik