Professional Documents
Culture Documents
01 Business Process Engine Overview PDF
01 Business Process Engine Overview PDF
Andrea Schmieden
1
Lesson Objectives
2
Agenda
Runtime Cache
Message Monitoring
Event Trace
Troubleshooting
3
What is the Business Process Engine?
4
Business Process Engine vs. Business Workflow
The Business Process Engine is the same as the Workflow Engine. The XI
version of workflow works just the same as the normal workflow component in
WAS 6.40.
However, in XI there are unique step types that are not normally apart of the
workflow definition environment. Even though the design layer of workflow has
unique features for XI, the runtime layer is the same as the normal workflow
runtime layer.
Most XI workflows are triggered by events (which is the way most workflows start,
via an event). When a workflow starts from an event, WF-BATCH logs in to start
the workflow. So, if you have a workflow that could start 5,000 times a day, then
you will have 5,000 logons by WF-BATCH. If the workflow will start 5,000 times a
minute, then you will have 5,000 logins by WF-BATCH in a minute. In this lesson
we will discuss some tuning and performance considerations for WF-BATCH.
IMPORTANT: When designing an integration (business) process in the
Integration Repository, you should try to determine approximately how often the
process will run.
Most of the generated workflows have start conditions associated with them. Start
conditions ensure a workflow only executes if it really should execute. They are
very common in workflow and improve performance.
5
Integration (Business) Process defined in Integration
Repository
6
Workflow Generated from the Integration Process
Triggering Event
Activity (Task)
Step that calls
another
workflow
This is the workflow generated from the Integration (Business) Process shown on
the previous slide.
The actual generated workflow can be seen in transaction code SWDD. This
transaction code is used in the exercises for this lesson.
When a workflow gets created it is stored on the database as WS (workflow
template) and a number. For example, WS74900023. In the configuration section
we will discuss required configuration for the number ranges.
You can see that some icons are the same as in the Integration Repository;
others are different.
The first “start” step becomes the triggering event step.
The second “receive” step becomes a wait for event step.
The third “mapping” step becomes an activity step. This is the most common type
of step in a workflow. Behind this step type is normally a call to a business object
or an ABAP class.
The fourth “send” step calls another workflow.
7
Agenda
Runtime Cache
Message Monitoring
Event Trace
Troubleshooting
8
Access Runtime Cache
You can display and analyze the runtime version of an integration process in the
runtime cache. This can be useful in an error situation, for example, when an
integration process could not be started. If you want to analyze the runtime
version, you can display it either as an XML representation or in the Process
Builder.
The runtime version of an integration process is created automatically from the
definition of the integration process in the Integration Repository and the entries
for service and party in the Integration Directory. The runtime version is created as
soon as you have activated the change list in the Integration Directory. If the
runtime version was created without errors, it is processed by the Business
Process Engine.
In the user menu, choose Exchange Infrastructure → Configuration → XI Cache
Refresh (transaction SXI_CACHE).
If the contents of the cache is currently being updated (amber status traffic light),
wait until the cache update is complete. If you do not, you may accidentally lock a
business process.
Prerequisites
Automatic Customizing of the Business Process Engine (transaction
SWF_XI_CUSTOMIZING) was executed without errors. This normally takes place
during installation.
9
Runtime Cache Overview
Display
10
Find the Workflow Number in Runtime Cache
Generated
workflow
11
IR Activation Updates Runtime Cache
12
Runtime Cache Information
Return code 0:
runtime
version was
created
without errors
Other return
code: Errors
occurred.
You can update
the runtime
version and
then analyze the
error messages
The screen area on the right displays the following information for each runtime
version:
Partner and service from the Integration Directory
Workflow task: During processing by the Business Process Engine, the runtime
version of the integration process is represented by a Workflow task. You do not
normally need to know the number of the task. However, you can use the number
to search for a task, for example.
Release: SAP Web AS release that was being used when the cache was updated.
Return Code: Return code for the creation of the runtime version:
0: The runtime version was created without errors.
Not equal to 0: Errors occurred. You can update the runtime version and then analyze the error
messages. When you do so, the system displays detailed messages about the problems that
occurred. You can also save the XML output as a file, which you can then pass on to SAP
Support for further analysis.
Date and time of last update
XML: XML representation of the runtime version of the business process. To
display the XML representation in a clearer, more structured way, double-click a
line.
13
Display Process Definition in the Process Builder
To display the process definition, select the runtime version and click the icon with
the quick info Display Active Version.
The process definition is displayed in the Process Builder. The Process Builder
has a similar structure to the SAP Business Workflow Workflow Builder; however it
is specially designed for displaying business processes. You cannot make any
changes to the process definition in the Process Builder.
To display the process definition graphically, in the menu in the title line of the
screen area on the right, choose Graphical Modeling.
14
Runtime Cache Error and Syntax Check
2. Display the workflow definition
3. Do a syntax
check in the
workflow
definition
Whenever you have a bad return code, such as the return code of 99 in the
graphic, you can do a syntax check on the generated workflow.
In the workflow definition, there is a Syntax check icon. You can also check the
syntax by selecting the menu path Workflow->Check Syntax from transaction code
SWDD.
After the syntax check you will receive any existing errors.
In the example on the graphic, there is an error on a condition statement. The two
values cannot be compared. This is an error related to the actual definition of the
workflow. Since this workflow was created in the Integration Repository, the error
must be fixed by the developer in the IR. You cannot make changes to workflows
that are generated from the Integration Builder activities.
Once the change is fixed in the IR and the changes are activated, the workflow
should no longer have syntax errors and transaction code SXI_CACHE should no
longer have a bad return code.
The workflow is not generated when the integration (business) process is created
in the Integration Repository. The workflow is generated when it is used in the
Integration Directory. That means the workflow is physically generated after the
integration (business) process has been built. That means the developer may not
have errors at the time the process was built in the IR, but there could still be
definition errors when the workflow is generated.
The developer should check the contents of SXI_CACHE after activating changes
in the Integration Directory. They should then verify that the workflow was
generated without problems.
15
Update the Runtime Version
Repeat
Activation
If a return code other than 0 is displayed in the runtime cache for a runtime
version, update the cache. To do so, click the icon with the quick info Repeat
Activation.
16
Process Activation Results
Messages:
S: Success message after a step has
been created
I: Information, e. g. about default settings
used
W: Warning, indicates logical errors and
problems
E: Error which stops a functional runtime
version from being created
17
Error Analysis
Conditions
Are the defined conditions valid?
At present, the condition editor cannot ensure that a condition does not
contain invalid comparisons, for example:
z Comparisons between different data types, for example xsd:date and xsd:time
z Comparisons between single and multiple expressions
Correlations
Is every activated correlation actually used?
Customizing
Incomplete customizing (transaction SWF_XI_CUSTOMIZING)
Every customizing item must have status green
18