Show Table of Contents

3.8. Process definition
A Process definition is a BPMN 2.0-compliant file that serves as container for a Process and its BPMN Diagram. A Process definition itself defines the import entry, imported Processes, which can be used by the Process in the Process definition, and relationship entries. We refer to a Process definition as a business process.
.
Example 3.1. BPMN2 source of a Process definition
<definitions id="Definition"
targetNamespace="http://www.jboss.org/drools"
typeLanguage="http://www.java.com/javaTypes"
expressionLanguage="http://www.mvel.org/2.0"
xmlns="http://www.omg.org/spec/BPMN/20100524/MODEL"Rule Task
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd"
xmlns:g="http://www.jboss.org/drools/flow/gpd"
xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI"
xmlns:dc="http://www.omg.org/spec/DD/20100524/DC"
xmlns:di="http://www.omg.org/spec/DD/20100524/DI"
xmlns:tns="http://www.jboss.org/drools">
<process>
PROCESS
</process>
<bpmndi:BPMNDiagram>
BPMN DIAGRAM DEFINITION
</bpmndi:BPMNDiagram>
</definitions>3.8.1. Creating a Process definition
Make sure you have logged in to JBoss BPM Suite or you are in JBoss Developer Studio with the repository connected.
To create a Process, do the following:
- Open the Project Authoring perspective ( → ).
- In
Project Explorer( → ), navigate to the project where you want to create the Process definition (in the Project view, select the respective repository and project in the drop-down lists; in the Repository view, navigate toREPOSITORY/PROJECT/src/main/resources/directory).Note
It is recommended to create your resources, including your Process definitions, in a package of a Project to allow importing of resources and their referencing. To create a package, do the following:- In the Repository view of the Project Explorer, navigate to the
REPOSITORY/PROJECT/src/main/resources/directory. - Go to → .
- In the New resource dialog, define the package name and check the location of the package in the repository.
- From the perspective menu, go to → .
- In the New Processes dialog box, enter the Process name and click . Wait until the Process Editor with the Process diagram appears.
3.8.2. Importing a Process definition
To import an existing BPMN2 or JSON definition, do the following:
- In the Project Explorer, select a Project and the respective package to which you want to import the Process definition.
- Create a new Business Process to work in by going to → .
- In the Process Designer toolbar, click the Import
icon in the editor toolbar and pick the format of the imported process definition. Note that you have to choose to overwrite the existing process definition in order to import.
- From the Import window, locate the Process file and click .

Figure 3.6. Import Window
Whenever a process definition is imported, the existing imported definition is overwritten. Make sure you are not overwriting a process definition you have edited so as not to lose any changes.
A process can also be imported to the git repository in the filesystem by cloning the repository, adding the process files, and pushing the changes back to git. In addition to alternative import methods, you can copy and paste a process or just open a file in the import dialog.
When importing processes, the Process Designer provides visual support for Process elements and therefore requires information on element positions on the canvas. If the information is not provided in the imported Process, you need to add it manually.
3.8.3. Importing jPDL 3.2 to BPMN2
To migrate and import a jPDL definition to BPMN2, in the Process Designer, click on the import button then scroll down and select .

Figure 3.7. Migrate jPDL 3.2 to BPMN2
In the Migrate to BPMN2 dialog box, select the process definition file and the name of the gpd file. Confirm by clicking the button.

Figure 3.8. Migrate to BPMN2 dialog box
Important
The migration tool for jPDL 3.2 to BPMN2 is a technical preview feature, and therefore not currently supported in Red Hat JBoss BPM Suite.
3.8.4. Deleting a Process definition
To delete a Process definition, open it in the Process Designer, click the menu (
) and then (
).
) and then (
).

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.