Professional Documents
Culture Documents
By penchalaRaju.Yanamala
Allow concurrent workflows with the same instance name. Configure one
workflow instance to run multiple times concurrently. Each instance has the
same source, target, and variables parameters. The Integration Service
identifies each instance by the run ID. The run ID is a number that identifies a
workflow instance that has run. For more information about running the same
instance concurrently, see Configuring Concurrent Workflows of the Same
Name.
Configure unique workflow instances to run concurrently. Define each
workflow instance name and configure a workflow parameter file for the
instance. You can define different sources, targets, and variables in the
parameter file. For more information about configuring the workflow instances,
see Configuring Unique Workflow Instances.
When you run concurrent workflows, the Workflow Monitor displays each
workflow by workflow name and instance name. If the workflow has no unique
instance names, the Workflow Monitor displays the same workflow name for
each concurrent workflow run. For more information about viewing concurrent
workflows in the Workflow Monitor, see Monitoring Concurrent Workflows.
The Integration Service appends either an instance name or a run ID and time
stamp to the workflow and session log names to create unique log files for
concurrent workflows. For more information about viewing logs for concurrent
workflows, see Viewing Session and Workflow Logs.
You can configure more than one instance of a workflow and run each instance
at the same time. When you configure a workflow instance, you provide a unique
name for the instance and configure a workflow parameter file for the instance.
When you start the workflow, you can choose which instances to run. When you
configure a concurrent workflow to run with unique instances, you can run the
instances concurrently. To run one instance multiple times concurrently,
configure the workflow to run with the same instance name.
Related Topics:
Steps to Configure Concurrent Workflows
Starting and Stopping Concurrent Workflows
You can recover workflow instances from the Workflow Monitor or pmcmd. When
you enable a workflow for recovery, the Integration Service appends the workflow
run ID to the recovery storage file name.
When you recover a concurrent workflow, identify the instance that you want to
recover. In the Workflow Monitor right-click the instance to recover. When you
recover with pmcmd, enter the instance name parameter.
Note: You cannot recover a session from the last checkpoint if the workflow
updates a relational target. The recovery session fails.
Use the following rules and guidelines when you run concurrent instances with
unique instance names:
The Integration Service can persist variables between concurrent workflow runs
for concurrent workflows with unique instance names.
You can stop or abort a workflow by instance name from pmcmd.
The Workflow Monitor displays the instance name for each workflow run. The
instance name appears in the workflow log and the Run Properties panel of the
Workflow Monitor.
When you configure a concurrent workflow to run with a unique instance name,
the log file names contain the instance name. You can archive
You can enable a workflow to run concurrently without defining unique instance
names. You can run more than one instance of the same workflow name. The
Integration Service distinguishes between each workflow instance by a run
identifier number, or run ID. Each workflow run has a unique run ID. The
Integration Service appends the run ID to the workflow and session log names,
recovery file names, and other temporary file names to create separate files for
each workflow.
Run concurrent workflows with the same instance name when the workflows
read from a real-time source, such as a message queue or web service. For
example, you manage data from multiple project teams. Create a workflow that
reads data from a message queue that determines the source data and targets.
You can run the instance multiple times concurrently and pass different
connection parameters to the workflow instances from the message queue.
When you run a web service workflow, the Integration Service can run more than
one instance of a workflow to improve performance. When you configure a
workflow to run as a web service, you configure the number of workflow
instances to run on a hub and when to start a new workflow instance.
When you enable a workflow as a web service, the Workflow Designer enables
the workflow to run concurrently with the same workflow name. The Web
Services Hub determines when to start a new instance of a web service workflow
based on the Maximum Run Count Per Hub and the Service Time property you
configure for the web service.
When the Web Services Hub starts a web service workflow instance, the
instance has the same name as the other workflow instance.
Note: When you enable a workflow as a web service, the Workflow Designer
enables the workflow to run concurrently by default.
When you enable a workflow to run concurrently with the same instance name,
you can also configure workflow instances and parameter files for the workflow.
You can start each instance more than one time concurrently.
For example, if you define a workflow and create two instances, you can start the
workflow and run both instances. You can start the workflow again to run the
same instances concurrently.
The Workflow Monitor Task View shows four instances running concurrently:
wf_sales [Instance1]
wf_sales [Instance2]
wf_sales [Instance1]
wf_sales [Instance2]
Related Topics:
Starting and Stopping Concurrent Workflows
When you enable the workflow for recovery, the Integration Service appends the
run ID to the workflow recovery storage file. You can recover workflows of the
same name from the Workflow Monitor or pmcmd.
When you recover a concurrent workflow, you must identify which instance to
recover. In the Workflow Monitor right-click the instance to recover. When you
recover with pmcmd, you enter the run ID parameter.
Note: You cannot recover a session from the last checkpoint if the workflow
updates a relational target. The recovery session fails with an error message.
Use the following rules and guidelines when you run concurrent instances of the
same instance name:
When you enable a workflow to run concurrently with unique instance names, the
Integration Service distinguishes between workflow run instances by the run
instance name. You can configure the same run instance name for more than
one workflow because each workflow instance is defined by a combination of the
workflow name and the run instance name. When you enable a workflow to run
concurrently with the same instance name, the Integration Service distinguishes
between workflow run instances by the run ID.
For example, create a pre-defined Event-Wait task to delete an indicator file after
it appears. Define the file name with $PMWorkflowRunInstance name. When you
run two concurrent workflows with unique instance names, each workflow Event-
Wait task waits for and deletes a different indicator file.
Note: When you run a workflow that is not enabled to run concurrently,
$PMWorkflowRunInstanceName has no value.
You can enable a workflow for concurrent execution when you create or edit the
workflow.
Optionally, enter the path to a workflow parameter file for the instance. To use
different sources, targets, or variables for each workflow instance, configure a
6.parameter file for each instance.
7.Click OK.
You can start concurrent workflows in the Workflow Designer or the Workflow
Monitor. You can also start workflows from pmcmd. To run unique workflow
instances choose the instances to run when you start the workflow.
You can choose which workflow instances to run when you start a workflow from
the Workflow Designer. Follow these steps to start a workflow that has at least
one instance defined.
The Workflow Monitor displays each concurrent workflow name and instance
name.
When a concurrent workflow does not have unique instance names or when you
do not want to run the configured instances, you can start a workflow with the
Workflow Designer. If you start the concurrent workflow with the Start Workflow
option, the Integration Service runs the workflow with the attributes and variables
you define on the workflow Properties and Variables tabs. The Integration
Service does not run any of the configured workflow instances.
You can dynamically create an instance when you start the workflow with
pmcmd. Enter an instance name and parameter file name. If the instance name
is not configured, the Integration Service generates an instance. The Integration
Service can persist variables for the instance in the repository, but the instance
does not appear on the Concurrent Execution Configuration dialog box for the
workflow.
You can stop or abort a concurrent workflow from the Workflow Monitor or
pmcmd. To stop or abort the workflow from the Workflow Monitor, right-click
workflow in the Navigator and select Stop or Abort. The Workflow Monitor
displays the status of the stop or abort command in the Output window.
The Integration Service names concurrent workflow session and workflow log
files based on the way you configure concurrency:
Unique instance names. The Integration Service appends the instance name
to the log file name.
Instances of the same name. The Integration Service appends a run ID and
time stamp to the log file name.
The Integration Service writes the run ID and the workflow type to the workflow
log. The workflow type describes if the workflow is a concurrent workflow.
For example:
Each session log also includes an entry that describes the workflow run ID and
instance name:
<workflow_name>.<workflow_instance_name>
<session_name>.<workflow_instance_name>
For example if the workflow log file name is wf_store_sales.log, and the instance
name is store1_workflow, the Integration Service creates the following log file
names for the binary workflow log file and the text workflow log file:
wf_store_sales.log.store1_workflow.bin
wf_store_sales.log.store1_workflow
To avoid overwriting the log files, you can archive the log files or save the log
files by time stamp.
Related Topics:
Archiving Log Files
When you configure the workflow to run concurrently with the same instance
name, the Integration Service creates logs for each instance. Each log file name
includes a run ID and time stamp by default:
<workflow_name>.<runID>.<timestamp>
<session_name>.<run ID>.<timestamp>
For example if the workflow log file name is wf_store_sales.log, and the run ID is
845, the Integration Service creates the following log file names for the binary
workflow log file and the text workflow log file if workflow runs on July 12, 2007 at
11:20:45:
wf_store_sales.log.845.20070712112045.bin
wf_store_sales.log.845.20070712112045
When you configure the workflow to run concurrently with the same instance
name, and you also define instance names, the Integration Service appends the
instance name and the time stamp to the log file name. For example:
<workflow_name>.<instance_name>.<run ID>.20070712112045.bin
<session_name>.<instance_name>.<run ID>.20070712112045.bin
The Integration Service writes the instance name and run ID to the workflow log.
For example: