Rapid Workflow Based Application Development
May 31

Rapid Workflow Based Application Development

Enterprises are looking to constantly re-engineer business processes to be more effective and productive.  Business processes modelled as Workflows offer many advantages, not limited to, modelling of processes as tasks, involvement of business folks, distributed deployment of tasks and parallel execution. There are many tools that provide visual modelling of business processes as workflows, tasks and involve manual human intervention as well as automatic assignment of tasks and completion.

Modern day RAD platform like WaveMaker offers, visual drag and drop WYSWYG interface to design, implement front end application User Interface. WaveMaker offers out of box beautiful responsive design of Web as well as Mobile Applications.

WaveMaker in combination with BPM tools can offer enterprises ability to model complex sophisticated business processes and at the same time offer visually interactive user experience and interface for end users to interact with the application.

Now that we understand the importance of such an integration, let’s dive specifically into one such integration between WaveMaker and JBPM – a flexible Business Process Management (BPM) Suite.

WaveMaker and JBPM Integration Application Development

JBPM is light-weight, fully open-source (distributed under Apache license) and written in Java. JBPM is used by many Java Developers for modelling business processes. See more at http://www.jbpm.org/. JBPM can be used to model simple as well as complex business processes as Workflows.

jbpm

JBPM Integration with WaveMaker

JBPM offers a REST API Integration model for client applications to integrate to it. Using the REST APIs a client application can remotely invoke, fetch and interact with JBPM Workflows and Tasks.

Overall Application Needs

Let’s see how WaveMaker Application Developers can leverage JBPM to build sophisticated workflow process applications.

High level components of Process Based Application

  • Business Processes modelled as Workflows
  • Workflow involving multiple Tasks and Flows
  • User Roles and Task Assignment
  • Application Business Logic
  • Application UX and User Interface Screens
  • Application Persistence
  • Application Security

The table below shows which parts are built within WaveMaker and the ones built using JBPM Tool. Note: WaveMaker can also model processes using Page Navigation and Page Assignment using its own business logic. When you need a business process designer to model processes, one needs to choose this type of integration.

Application FeatureImplemented Within
Business Process Modelling using WorkflowsBPM Tool
Workflow Tasks and Role AssignmentsBPM Tool
Application Look and FeelWaveMaker Using Themes
Application User Interface WaveMaker Drag and Drop Interface
Application SecurityWaveMaker Inbuilt RBAC Security
Task InvocationWaveMaker Using BPM REST APIs
Task MonitoringWaveMaker Using BPM REST APIs
Application PersistenceWaveMaker Using Database Integration

Business Process Modelling as Workflows

Launch JBPM Console, at http://host:port/jbpm-console, and you can login and start creating Process definitions, Task List and users/roles. Here is one such example, of a Bank Loan Approval Business Process that is modelled using JBPM workflows. As you can see the process involves multiple steps from the time end user applies for a loan to the time the loan gets approved. These steps are modelled as tasks and there are various gate keepers (roles) that need to approve the step in order for the workflow to the next step. Bank
Loan Approval Process Modelled

 

jbpm1

 

  1. Workflow Tasks and Role Assignments

In the JBPM Process Designer, you can have a Workflow modelled with various tasks as shown below. Each Task can be assigned to an approver who needs to manually intervene and move the workflow ahead. As you can see below, there is a verification step involved in Bank Loan approvals. And there is a verification task that is assigned to a Role (“Verifier”) and that person will manually intervene the workflow and approve / disapprove the loan step depending on business rules.

As you can see in the workflow, there are multiple tasks in the overall workflow process. At different tasks level, you can see that there is an approver involved that will move the process to the next step.

jbpm2

 

  1. Application User Interface and User Experience

WaveMaker provides intuitive drag and drop interface to develop UI Screens and Widgets. Application developers can create the UI Elements using WaveMaker.

WaveMaker support number of out of box widgets to easily create the UI Screens.  The UI can be customized in terms of look and feel using WaveMaker Themes. The UI created out of box from WaveMaker is by default Responsive in Nature. Here is an example of WaveMaker created UI Screen.

 

jbpm3

  1. Binding UI to JBPM Processes

WaveMaker supports easy integration to REST APIs using the Import Web Services Wizard. JBPM exposes REST APIs for client applications to consume and remotely invoke, fetch, and monitor workflow processes and tasks.

Here is the link to see the documentation of REST APIs from JBPM, https://docs.jboss.org/jbpm/v6.0/userguide/jBPMRemoteAPI.html

Few of these REST APIs used in the Bank Loan Application are shown and explained below,

Get Process Information:  Get Information about JBPM Process Instance, given an instance ID

REST API URL: /rest/runtime/demo:LoanProcesses:1.0/withvars/process/instance/{processinstanceid}

In order to import this API in WaveMaker, use Import Web Services Wizard as shown here,

jbpm5

Security for invoking the REST API

WaveMaker can import/invoke secure as well as non-secure APIs. While importing these REST APIs from JBPM, the appropriate security credentials need to be provided in order to import the services and invoke them from the application. Here is the security configuration that needs to be provided provide, as an example,

jbpm6

Once these APIs are imported, WaveMaker creates Service Variables for each API. In the User Interface, these service variables are then bounded to the respective Widgets to bind the data from the service to the widget.

For example in a loan processing app, when a loan processing application form is filled, the loan processing workflow needs to be kick started, this is done by binding the respective service variable to the submit button as shown below

jbpm7

 

 

jbpm8

 

jbpm9

 

Other examples of REST APIs that JBPM Provides

Invoke Start Process: Invokes a specific task within a workflow

REST API URL : /rest/runtime/demo:LoanProcesses:1.0/process/LoanProcesses.LoanApproval/start?map_Address={map_Address}&map_EmailId={map_EmailId}&map_PAN={map_PAN}&map_Salary={map_Salary}&map_LoanAmount={map_LoanAmount}&map_Name={map_Name}&map_CompanyName={map_CompanyName}&map_EmployeeId={map_EmployeeId}&map_Gender={map_Gender}

Start a specific Tasks

REST API URL:
/rest/task/{taskid}/start

  1. Application Security

WaveMaker supports out of box authentication, authorization and access control for the various application components.  The Application can use various forms of Authentication stores (LDAP, AD, Custom Legacy Systems) to authenticate users and also support Role Based Access Control both at coarse as well as granular levels for UI Screens, Widgets and individual services.

 

  1. Application Persistence

WaveMaker support persistence of any custom data that the application needs to manage. WaveMaker supports all the major SQL databases to persist data.

In summary, as you can see in this article, WaveMaker in combination with BPM tools can allow Enterprises to rapidly develop sophisticated process based applications both as responsive web applications as well as Mobile Hybrid applications.

For more on WaveMaker, please visit, www.wavemaker.com, to sign up for a free trial account, www.wavemakeronline.com and for a demo request, contact us at www.wavemaker.com/request-demo

 

 

 

About The Author

Mayur Shah - Customer Success - Enterprise (Asia). Mayur’s expertise middleware and software architecture at BEA Systems, Cisco and Informatica, before joining the WaveMaker team, helps him in being deeply technical and honest in communication. Mayur has experience working with several successful enterprise CIOs, software decision makers and architects, bringing business and technical strengths.
We use cookies to provide you with a better experience. By using our website you agree to the use of cookies as described in our Privacy Policy. Continue