jBPM Hello World Example
Here, we will write our first application of jbpm. We have to follow the following steps to create our First Application.
Create Project
To Create Project Go to File -> New -> Other -> jBPM Project.
2. Provide Project Name
Click Next and type our Project name “HelloWorld”.
3. We include a sample process in our project to get started. See the Below Screen and click Next.
4. Select jBPM Runtime
Click on Configure Workspace Setting.
5. New window screen will be opened, click on Add Button.
Once you click on Add Button, a new window screen will open. In this window click on “Create a new jBPM Runtime”.
Again new screen will be opened. Give the path for jBPM Runtime and select the Installed jBPM Runtime click on Apply and Close Button.
6. Finish Project
Project Structure
Now open the Project Explorer View in Eclipse. We will see the following screen.
Double click the sample.bpmn of the project, we will see the following screen.
Here the Green circle tells the Start of the WorkFlow and Red circle tells the End of the WorkFlow. The Hello in between Start and End event is the Script Task.
To see the code written in the script task Hello, then go to Windows -> Show View -> Other -> Properties. We will see the below screen.
Click on Open Button. Select Hello and see the properties of Hello event.
To see the entire code written in Hello event click on action property, new screen will be appeared.
We can also edit this and write the code which we want to execute inside the Hello event script task. Let us edit and see the output.
Output: