An Alternative Design Approach to Achieve Pega Process Fabric Functionality

An Alternative Design Approach to Achieve Pega Process Fabric Functionality

Did you ever come across any scenario where a business asks to implement a solution to have a consolidated list of cross-application assignments instead of logging into multiple portals?

Pega's Process Fabric Approach

If Yes, you might have immediately thought about Pega Process Fabric which ideally fits the above requirement!

No alt text provided for this image

Abstract (Wrapper) Application Approach

You might have also thought about building a wrapper application built upon source applications to achieve the requirements too! I mean for example, if you are logging into two applications, one to approve timesheets and another application to approve leave requests then build an employee management system built upon a timesheet & leave management application to get consolidate a list of the task to have a unified view of work.

No alt text provided for this image

Concerns

As we all know that Pega Process Fabric or Wrapper Application pattern is not a kind of middleware solution where every application can exchange information as per the need.

The wrapper application may not work if the source applications are situated at different instances.

So what exactly we are talking about here?

API Integrator & Manager Approach

I would like to talk about my perspective on an alternative design that we can think of to achieve Pega Process Fabric functionality(worklist point of view) using API designer or Integrator!!

You call it API integrator or Gateway or etc, they all do one thing called API Management / Orchestration.

WSO2 Integrator

Here I have used WSO2 API Integrator to consolidate user tasks from two different applications from different instances.

No alt text provided for this image


Solution Approach

In this example, we have two different instances (two independent apps) where a user has to log in to complete the tasks. These two apps (1-App & 2-App) have some open tasks to finish. Let's now understand it technically!

Here is a sample request & response of '1App'. Assume that this instance is running on a private cloud.

No alt text provided for this image

Here is another sample request of '2App' running on avdifferent location.

No alt text provided for this image

If these two applications are running on the same instance then you can have this wrapper application approach to solve the requirement!

No alt text provided for this image

You can have the worklist (combined) like below.

No alt text provided for this image

We can also use the Process Fabric connector component to connect our 1&2Apps to the Process Fabric Hub to get consolidate worklist.

No alt text provided for this image

Let's get back to our alternative design option to achieve Process Fabric functionality where we have seen two different instances of sample requests & responses.

WSO2 Enterprise API Integrator

Now launch WS02 Integration Studio & create an Integration Project

No alt text provided for this image
No alt text provided for this image

Create two endpoints, one for 1App and another for 2App as below

No alt text provided for this image

Do repeat the same steps for the 2App instance too and you should have both the endpoints as below (In the project explorer)

No alt text provided for this image


Now create a REST API (This is going to be our URL which can get the tasks from both the instances) as per below

No alt text provided for this image
No alt text provided for this image

This should open the API designer as below

No alt text provided for this image

Now let's use Mediators shapes like Clone (as we need club two instances output here) and Call shapes to call the created endpoints.

Add a clone shape & set two branches

No alt text provided for this image

Drag & drop two Call shapes.

No alt text provided for this image

Now call the two endpoints by dragging & dropping in the clone branches as shown below.

No alt text provided for this image

We need an aggregator shape to combine these endpoints responses and provide an expression(which elements from these two responses to be aggregated) as below

No alt text provided for this image
No alt text provided for this image

Once done, we need to respond to the API (MyTasks) by placing this response shape.

No alt text provided for this image

We have finished integrating two different endpoints into a single lightweight REST API which can then be published API Manager (Catalog of APIs for an enterprise)

No alt text provided for this image

We can now run this integration by exporting the required artifacts!

No alt text provided for this image

Once you run, you must see this runtime services window to look at the generated API details or you can use inbuilt Swagger API to test the API

No alt text provided for this image
No alt text provided for this image
No alt text provided for this image

I will use Postman to test this API by providing my authentication details(operator details)

As you see now, this API brings the tasks from two different applications and can be used to bring consolidated worklist tasks.

Summary

As we all know one product doesn't fit all, here Pega Process Fabric can be used to get all list of tasks from different applications from both Pega & Non-Pega applications to get a unified portal experience if required Pega UX/UI.

If we have a Non-Pega custom portal, then we can think about this API Integrator approach.

If two applications are residing in a single instance then we can go for a wrapper application pattern to achieve a unified worklist experience!

Venkata Gangadhar Reddy Yelugoti

Pega Lead System Architect, Pega Decisioning, Cloud Enthusiast

3 年

Very nice explanation and great thought ????

Deepak Pandey

PCLSA 8.5 | Technical Architect

3 年

Unified solution simplified ! Lucid explanation.?

要查看或添加评论,请登录

社区洞察

其他会员也浏览了