Home
- Home
- Blog
Author :
Global TechHub
Introduction
There are two ways we can integrate
BPD in IBM BPM Process designer as a Restful service. It can be either inbound
or outbound integration. Outbound Integration involves the Business Process
Definitions (BPD) invoking external Restful service as part of the process.
This artical focuses on inbound
integration that involves exposing the BPD as a Restful service for external
users.
Overview
As part of exposing BPD as a Restful
Service we need to follow below steps.
1.
Create a BPD.
2.
Expose as a Service.
3.
Install Sanpshot.
4.
Test the Application.
Create a BPD:
Open Process Designer and Click on Create New Process App. Give name as ‘BPD Sample App’, Acronomy as ‘BSA’ and click on Cretae.
Click on ‘Open in Designer’, now our application will open in designer we can
create BPD under processes.
Select Variables tab under Restful BPD implementation, add Input varaible
name as ‘name’ and Output variable
name as ‘greeting’ as shown below.
By default these input and output variables are String type.
Select Defination tab and drag and drop three activities, connect them and
name it as shown below.
Select First Log Activity à Properties à Implementation à Select Type as ‘Script’ from drop down box.
Select First Log Activity à Properties à
Select Script tab and enter below
message.
Repete the same step for last Log
Activity and enter below message under Script.
Now select ‘Set Greeting’ Activity à Properties à Implementation à Select Type as ‘Script’ from dropdown box.
Select ‘Set Greeting’ Activity à Properties à
Select Script tab and enter below
message.
Expose as a Service:
Select Overview tab and under Exposing section
select ‘All Users’ for Expose to
Start as shown below. Save all the changes.
By selecting All
users for Expose to start all user under this server can start this BPD, if we
want to retrict for specific Team or user we can select specific team or user.
Install Snapshot:
Come back to Process
center page, click on BPD Sample App click on Create New Snapshot. Give
Snapshot name as ‘BPD Sample App V1.0’ and click on create.
Test the Application:
IBM is providing BPMRestAPI tester
along with IBM BPM product. We can access the BPMRestAPI Tester by using below
url.
https://<hostname>:<port>/bpm/test/bpmrest-ui/
Expand the Business Process Manager Rest APIs à Process API à Select Exposed Processes and click on Execute call.
Now we can see our BPD is exposed as
a service, but we want to access as a restful service.
Expand the Business Process Manager
Rest APIs à Process API à Select Start Process, give the values as shown
below and click on Execute call.
Conclusion
Here we have learnt exposing BPD as a
restful service in IBM BPM, even we can expose BPD as SOAP webservice and
Javasctipt to access the BPD. I will post in other article to expose BPD in
otherways too.
Download
S. No
|
File Name
|
Size
|
Download
|
1
|
Expose BPD as Restful service in
IBM BPM.pdf
|
1.9 MB
|
|
2
|
BPD_Sample_App_V1.0.twx
|
10 MB
|
Comments
Post a Comment