Press "Enter" to skip to content

How to configure Split Join, Split for Each & Spin Off in flow rule?

26

Introduction

We are going to see about three parallel processing that can be used in a Flow rule.

  1. Split Join
  2. Split for each
  3. Spin off

What is parallel processing?

Imagine you have got a job offer from a reputed company.

Onboarding process involves,

  • Document uploading & verification process – You and the HR will be involved.
  • Address verification process – External vendor involved.

Both are independent. If this happens sequentially, then I am sure that your joining date will be extended.

This needs to happen in parallel.

If this onboarding process is implemented in flow, then you have to consider the following shapes.

These shapes (Spin Off is not a shape) support parallel processing.

Throughout this post, I will explain with the Amazon sales as example.

Scenario Explanations:

  1. Split Join scenario

Step 1: Customer ordered the product.

Step 2: The real flow starts.

We need to use parallel processing.

Step 3: The process needs approval from both the teams – Operations, Seller.

Both the approval process are totally different.

Step 4: Once both got approved, the product will be dispatched to the customer.

How do you configure Split Join shape?

  • In the flow rule diagram tab, open the shapes + icon, then advanced shapes and click and drag the Split join shape into work area.

  • Double click on the shape to explore the properties.

In Details block, you can configure the parallel processing details.

Join condition –

a) All – Only when both the operations and seller managers approve, the primary flow will resume and we can dispatch the product. This is exactly opposite to parallel processing.

b) Any  – At least if any one of the managers approve, then the primary flow will resume and we can dispatch the product.

Say for example – Operations manager approved the case, then the assignment for seller manager will be cancelled and the primary flow resumes to dispatch the product.

c) Some –

On When – You can specify a when rule to return to primary flow.

On count – You can return to primary flow, when no of paths (say 1) results in flow status Resolved.

When the conditions meet, primary flow resumes and the other assignments get cancelled.

Specify a flow rule for this sub process –

Define flow On which context the flow should run.

a) On current page You can run the flow on current page.

b) On embedded page You can run the flow on different page.

Normally we use this, when the flow is of another class.

c) On a specific work item This is bit tricky.

  • You can either specify a work party or a page name to identify the work item on which the flow should run.
  • Imagine you have a purchase request (parent work item) work item and a product order work item (child). If you are in primary flow and want to run this Split Join flow in the child case, you can use this option.

Don’t get confused 🙂 We use it rarely. First try testing using same page context 🙂

Flow input/output  – Tabs to support the input/output parameters for the flow rule.

Filter flow by You can specify either process flow or screen flow.

Flow rule Specify the flow rule.

You can add any number of parallel process here. Since the approval process are different, we need to add two different process here.

Advanced block

In the advanced block, you can specify the status as well as tickets. Normal as we use in other shapes.

   2. Split  For Each scenario
Step 1: Customer ordered the product.

Step 2: The real flow starts.

We need to use parallel processing.

Step 3: The process needs approval from sales, operations and seller managers.

The approval process is same for all the three teams.

Step 4: Once approved, the product will be dispatched to the customer.

Now tell me. “What is the main difference you find in using Split-Join & Split -For each scenarios?”

Scroll up and find it out.

Split Join – The approval sub process is different for different people.

Split for each – The approval sub process is same for all people.

Remember Split Join & Split for Each are not pure parallel processing. The primary flow waits for sometime, before the conditions meet to resume.

  • In the amazon sales process, we need verification from 3 different teams.
  • We used Split-For each, so three assignments will be created 3 different teams for approval.
  • At this time primary flow is halted. So no parallel processing in the primary flow.
  • Only based on some condition, we can work on primary flow parallel.

It means the business will be like, you need at least 2 approvals out of 3 teams to dispatch the product. In this case, there is no reason to wait for all 3 approvals. If 2 approvals are done, then we can get back to primary flow and continue the process.

  • Split for each will always run on a group of people sharing the same process.
  • In Pega, we can use pagelist/pagegroup property to store the group of people.

 How do you configure Split for Each shape?

Follow the same steps to include a Split for each shape.

Double click on the shape to explore the properties.

Few notable differences to split join are:

Join You will have 4 options.

All, Any, Some – Same as Split Join.

Iterate – You can specify a when rule to exit iteration and return to primary flow.

Page property – Specify the Pagelist/Page group property.

Class – Page list defined class.

Filter flow by  – Process flow/Screen flow.

Flow name – Specify the flow name here.

When – You can specify a when rule to conditionally start the flow.

Note: There may be some scenario, where we don’t want to start the flow for all the pages in the pagelist.

Assume, we have a workparty pagelist prioperty. It contains 5 results, but we need to start the approval flow only for mangers. You can use the when rule here to conditionally start the flow.

Page Group Iteration settings –

This appears only when we select Join – Iterate.

Applicable for Page group property.

Imagine, you used a page group property – pyWorkParty.

It contains two results:

  1. pyWorkParty(Sales)
  2. pyWorkParty(Service).

In the above picture, I mentioned subscript sales. So the process flow starts only for pyWorkPage(Sales).

Exact match Matches the subscript order exactly, no contains match.

3. SpinOff
Step 1: Customer ordered the product.

Step 2: The real flow starts.

We need to use parallel processing for verification process.

Note: This verification do not affect the primary flow.

Step 3: You can send the workitem to verification WB and continue working sales process.

The processing in verification WB is totally independent. It will never return to primary flow.

How do you configure SpinOff shape? 

  • SpinOff is not a flow shape.
  • You can spinOff any subprocess using the SpinOff flow checkbox.

Include a sub process shape and double click on it to open the properties.

  • You can check the SpinOff flow checkbox to spinoff any sub process.

Get to my next post to test all scenarios 🙂

  1. Venkatesh Venkatesh

    Hi,
    In Split join, when we put join condition as some and assume 4 sub flows triggered and respective assignments routed to different approvers l. When join condition configured as Some and count as 2 approvers and if condition returned true then what happens to other assignments in other approvers worklist ?

    • Premkumar G Premkumar G

      Hi Venkatesh, all the other assignments will be deleted.

  2. Vijay Vijay

    Doing a great job brother..
    Thank you for sharing the information.

    • Premkumar G Premkumar G

      Thank you so much, Vijay. Please subscribe and stay tuned for more posts.

  3. Premkumar G Premkumar G

    Oh 😀 Thank you so much for your encouraging words. It means a lot to me. Thank you.
    Kindly subscribe and stay tuned for more posts.

  4. sameer sameer

    Hi ,
    I dont kow who developed this site . but really good . please post some more information also

  5. pradeep pradeep

    hi prem iam really not getting what is main purpose of spin off

    • Premkumar G Premkumar G

      Hi Pradeep,
      Spin – Off supports parallel processing. In some scenario, you need more than one people to work on a case. You can create 2 assignments, using spin-Off.

      • Venkateshwar Reddy Moogala Venkateshwar Reddy Moogala

        Doesn’t split join also do the same? Split join also can be used to create more than one assignment so that more than one operator can work on the case. Can you please let us know what exactly is the difference between Split Join and Spin Off?

        Very thank full for all the info you put out here. A big shout out to you.

  6. swapna swapna

    Please make a post on flow actions also.

    • Premkumar G Premkumar G

      I will post about it soon, Swapna. 🙂

  7. Kumar Kumar

    Hi Prem,
    Great Information. Very useful one!!!
    A quick doubt, in your split join example, you have created two parallel flows(Operational team and sales team) and when the system reaches Splitjoin shape, two ASSIGNMENTS are created for the same work object.
    But when we say parallel processing, both OPERATIONAL and SALES teams should open the case at the same time and process it to make it parallel process. But when i tried this, it is failing because of lock issues. And system is alowing me to open assignment by assignment and submit the assignments(which is a kind of sequential). Could you please help me out on this..

    Thanks,
    Kumar.

    • Premkumar G Premkumar G

      Yes. It is the expected behaviour. You can create 2 assignments parallel. But always only one people can work at a time. This is the default locking. I am preparing a post on locking architecture. You will soon get cleared out of your doubt 🙂

  8. Rupesh Rupesh

    Hi Prem,

    I have a doubt for Split join shape. we have subprocess tab , under that for define flow=”specific to work item”.. you have mentioned like => ” you can either specify the work party or page name to identify the work item on which the flow should run”

    is that work party or work property ?

    if it is work party then how it is related to identify the work item on which flow to run.

    can you please make it clear.i m bit confused with this point.

    Thanks
    Rupesh M

  9. Himasekhar Reddy Pucha Himasekhar Reddy Pucha

    Which scenario we are using spin-off

  10. Prasu Raya Prasu Raya

    Hi Prem,

    Really you are sharing very useful knowledge with good clarity.

    • Premkumar G Premkumar G

      Hi Prasu,

      Thank you so much for your appreciation, Prasu. 🙂

      Regards,
      Premkumar G

  11. Jay Jay

    Hi Prem,

    Thanks for your posts. This is really awesome to learn about Pega. You are sharing the tiny details too. Thanks again.

    I would really appreciate your response on the Spin off flow. I couldn’t make what is the exact purpose of it. And we have the split join and split for each flow shapes, What is the need of this spin off process?

  12. Rasika R D Rasika R D

    Prem your posts have been very helpful.
    Great job. 🙂

    • Premkumar G Premkumar G

      Glad to hear that you find it helpful. Thank you so much for your appreciation, Rasika. 🙂

  13. Rakesh Rakesh

    Hello Prem,

    Thank you so much for these posts. Could you please add some posts related to the screen flow?

  14. Monu Sharma Monu Sharma

    Prem,
    your posts are really good and helping.

    • Premkumar G Premkumar G

      Hi Monu Sharma,

      Thank you so much for your appreciation. 🙂

  15. Basant Soni Basant Soni

    Great work Prem Bhaiya 🙂

  16. Venkateshwar Reddy Moogala Venkateshwar Reddy Moogala

    Doesn’t split join also do the same? Split join also can be used to create more than one assignment so that more than one operator can work on the case. Can you please let us know what exactly is the difference between Split Join and Spin Off?

    Very thank full for all the info you put out here. A big shout out to you.

Leave a Reply

Your email address will not be published. Required fields are marked *

error: Content is protected !!