When you start DCR Simulator you effectively spawns the graph creating a new instance of the graph. Sometimes you would like to spawn a new (sub)graph inside an existing graph.

Imagine a case management system outlined in the case management example. Given a case you can add documents, i.e. spawning a new subgraph representing the document. As many documents can exists on a case you need to be able to spawn new documents.

A document can be represented by a subgraph.

When you inside a graph executes an activity that spawns a subgraph you effectively spawns a new instance inside the existing instance.

Visually, a subgraph has a "G" in the lower right corner and a double lined box around it.

Naming the new instance of a subgraph

When spawning a new subgraph you can provide a label to the new subgraph. This is done using the value in the options panel as illustrated below. The value will be set to 'Subgraph no ' ++ SpawnSubgraph.

Try it out yourself on this graph:

The graph consist of a spawning activity and a subgraph with a form and a confirm activity inside. The form contains an Integer inside.

Aften having spawned two subgraphs the task list will look like this:

Notice the the prefix of task labels "Subgraph no 1" and "Subgraph no 2" in from of activities/forms etc.

Spawn new instance in same context

When you spawn a new instance the default behavior is to spawn the instance within the instance currently opened.

However, now you can spawn a new instance in the same context is the current instance, i.e. a sibling instance.

This is similar to OCMSpawn og KMD WorkZone Startprocess. Read more here. Notice, this cannot be tested in DCR Simulator. You need DCR Case to verify the logic.

In the Options panel look for Spawn in Separate Instance as illustrated below.

Multi-instance subprocesses

Please refer to this page for details.

Related Release notes

Release 7.0.4

Related Videos

No related videos found.

Related Articles

Web-based Modelling and Collaborative Simulation of Declarative Processes