Thursday, October 04, 2012

Usage of WorkGroup & WorkBasket in Pega

It's been some time since i'm trying to understand the case management in PRPC. The concepts of WorkList, WorkGroup, WorkBasket are most confusing if not understood with some examples. Not to criticize any, i questioned many of my friends who has decent hands on experience in PRPC. But all that i get are vague answers or should i say theoritical answers. Spending lot of time on developer help, pdn etc, here is what i understood.

Before i blabber more, let me put down the definitions from PRPC here,

A workbasket is a named queue of open assignments that are not associated with an operator. A workbasket is defined by an instance of the Data-Admin-WorkBasket class.

A work group is an instance of the Data-Admin-WorkGroup class. A work group can identify a user who is a supervisor, and a set of workers and workbaskets that report to that supervisor.

Just have a look at how work group(referred as WG further) and work basket(referred as WB further) creation screens look.
Work Group creation screen(as in 6.1 version)

Work Basket creation screen(as in 6.1 version)

Intersting point here is, WG has a reference to WB and again WB has a reference to WG. A circular dependency can be noticed. Just thinking aloud. "This means, a entity called WG is created to just hold the Manager value. Other than this, what is the purpose of WG? I mean, lets say, if the Manager field is moved from WG creation to WB creation, then there is no need of WG entity/concept at all in PRPC??"
To dig into the details, lets have a look at the operator creation screen,

Operator creation screen(as in 6.1 version)
A user/operator can have only one WG and multiple WB's assigned to him. So, this also means, he has got only one reporting Manager that is linked through WG. But, what is the purpose of multiple of WB's?

Another point is, an assigment in a BPM can be routed to WorkList, WorkBasket, WorkGroup & we have many more options but these are the context our discussion.


Ok, with all the important points put down above, the questions will boil down to,
  • What is the purpose of maintaining WG as an seperate rule, where as the Manager field(only field in WG) can be moved to WB and all we can avoid WG totally?
  • We dont have any WG area in the inbox of the user. The user portal has WL area and WB area but not WG area in real time user login. Then what happens if an assignment is routed to WG?
I will try to answer these questions with an example. Lets say, we have 4 operators, all having access to all the 4 work baskets.

OperatorJOHN
WorkGroupJAVAWG
WorkBasketsJAVAWB
SAPWB
DBWB
BPMWB
OperatorMIKE
WorkGroupSAPWG
WorkBasketsSAPWB
JAVAWB
DBWB
BPMWB


OperatorBROWN
WorkGroupDBWG
WorkBasketsDBWB
JAVAWB
SAPWB
BPMWB
OperatorSAM
WorkGroupBPMWG
WorkBasketsBPMWB
JAVAWB
DBWB
SAPWB






And the WB and WG are created as,

SAPWGManager: PersonA
WB: SAPWB
SAPWBOrganization/Unit/Division
WG: SAPWG
JAVAWGManager: PersonB
WB: JAVAWB
JAVAWBOrganization/Unit/Division
WG: JAVAWG
DBWGManager: PersonC
WB: DBWB
DBWBOrganization/Unit/Division
WG: DBWG
 BPMWGManager: PersonD
WB: BPMWB
BPMWBOrgnization/Unit/Division
WG: BPMWG

And consider a BPM as below,

Sample BPM for understanding

Now, when the assignments are triggered and routed to WB, WG, what happens? Where exactly the assignments appear for the end user?

When Assignment 01 and Assignment 03 are routed to SAPWB and JAVAWB respectively, they appear in the WB area of user portal/inbox(whoever has the access to those WBs). So user is free to pick up any assignment and can also transfer back to the WB.

When Assignment 02 and Assignment 04 are routed to BPMWG and DBWG respectively, they are routed to available operator, chosen randomly, in the workgroup.  If none are available, the assignment is routed to the respective managers.

So, whenever you expect any of specialized group to act on a task(with an assigned supervisor) use WG, else use WB which has bigger audience.

Another pointer,


PS: All the images & information is picked up from the developer help or pdn of Pegasystems.

7 comments:

Anonymous said...

Superb

Recipes for life!! said...

This is really awesome!! Very well explained. I had this confusion for long time now.

Unknown said...

Impressing sir..

vikas said...

Excellent explanation, This article is real useful to a learner who unable to understand or confused of these WG, WB, WL etc... Good explanation even a layman can learn by the explanation. Thank You Very much.

Anonymous said...

That explanation was to the point why we actually use WG! Thanks for sharing. :)

Unknown said...

Hi There,

Allow me to show my gratitude bloggers. You guys are like unicorns. Never seen but always spreading magic. Your content is yummy. So satisfied.

Issue: Decision table rule in Production ruleset is not being picked up during rule resolution.
Description: Need to delegate a decision table . So we placed that rule in Production ruleset. But it is not being picked up during execution. Error is displayed on the screen saying rule is not available in application ruleset.
This decision table need to be changed in Production environment. That's why we added it in production ruleset.
We have added the ruleset in production ruleset in Application as well as Access group level.
Observation: If I add the ruleset in Application ruleset list then it works. But I don't want it to be in application ruleset list. It should be in production ruleset itself.
Anyways great write up, your efforts are much appreciated.

Kind Regards,
Hari

Thrinath Chakravarthy Jalamadugu said...

Do you see the "prod" RSV in the profile of the user?