Spawning Subprocesses

This tutorial describes how spawning of a root process instance creates a sub-process and copies data associated with it.

Assuming a scenario where a company often receives scanned documents in the Stardust Portal. But the scan operator submits the scanned documents to wrong process definition. Thus the document enters in the wrong workflow. Also, the company also needs a single document available to multiple processes. For details refer to the Common Usage Pattern section of the Spawning a Sub-process chapter of the Concepts handbook.

This tutorial covers the following:

For details on the spawn subprocess functionality, refer to The Spawn Process Dialog chapter of the End User Handbooks.

Importing the Example Model

Use the ScanDemo example model which contains several process definitions that allow process attachments.

  1. Download the following ZIP file containing the example model

    managingUnstructuredWorklowExamples.zip

  2. Create a dynamic Web project designed to deploy Stardust Process Platform models to run in the Stardust Portal. For detailed information on creating dynamic Web projects for usage with the Stardust Portal, please refer to the Rapid Application Development guide.
  3. Right-click the project and select Import > Process Manager > Process Model. Click Next and browse to the location of the example model extracted from the zip file.

Deploying and Running the Model

Perform the following steps to deploy your example model and run the project in the Stardust Portal:

  1. Start your server and deploy the model. For details on how to deploy a model, please refer to the chapter Deploying a Workflow Model of the Support Case Example.
  2. Start the Stardust Portal as described in the chapter Login to the Stardust Portal of the End User Handbooks. Login as administrator (motu/motu). You can use the Shift-F8 short key.
  3. Switch to the Participant Management View of the Administration Perspective.
  4. Create a user and assign him to the roles Scan Operator and Good Order Reviewer. For details on how to create a new user, refer to section Creating a new User of the chapter Participant Management View of the Administration Perspective guide.
  5. Logout and login again as the new user.

Executing the Workflow

Perform the following steps to execute the workflow and spawn a process:

  1. Scan a document into the Loans process definition
  2. Login to Stardust Portal with the credentials of Goods Order Reviewer and locate the Loans process instance created in step 2
  3. Activate an Activity in the newly created process instance and enter details

Spawning the Process

  1. In the toolbar, click Spawn Process icon
  2. Spawn Process icon
    Figure: Spawn Process icon

  3. Select Brokerage and HELOC process to start from the Spawn Process dialog
  4. Select processes to start
    Figure: Select processes to start

  5. Review the newly started processes in the Spawn Process confirmation dialog
  6. Spawn Process Confirmation
    Figure: Spawn Process Confirmation dialog

  7. Click Yes if you want to view the newly spawned process

Viewing the Process History

  1. Expand the Process History panel of each newly started process and confirm that they are shown as sub-processes of the root process instance

  2. Process History
    Figure: Process History

  3. In the Process History panel, click the Process Details icon of HELOC sub-process. The HELOC process details get displayed.
  4. Process Details of the Sub-process
    Figure: Process Details of the Sub-process

Viewing the Data

  1. Expand the Process Documents panel of the HELOC sub-process. The copied documents get displayed under Process Attachments.
  2. Copied Document
    Figure: Process Document - Copied Document

  3. Similarly, check the copied document for the Brokerage sub-process.