Pega #Pega Notes #Interview Topics
Pega #Pega Notes #Interview Topics
Modes
Read only: - These Data Pages gets created on clipboard under ‘Data Pages”.
Editable Modes: - These Data Pages gets created on clipboard under “User Pages”., These can be updated or deleted
Scopes
• Thread: A thread scope of data page is accessible for sharing with in a single WO multiple times.
• Requestor: This scope of data page is accessible for sharing with in a single requestor session among multiple WO’s but not
with other requestors.
• Node: This scope of data page is accessible among multiple requestors who logon to same node but not with requestors of
another node.
Report definition is used to fetch data from tables and display the data in table or charts format.
Real life example: If amazon application developed using pega, we can use report definition to fetch all the returned items into a
report to analyse the monthly returns data. It can be created under Report Category., Report Definition is instance Class is Rule-Obj-
Report-Definition.
1.1 Report Definition Continuation.
A. Reporting can be done on Exposed columns. Reporting on BLOB brings down the performance of Application. (To performs Joins, both
tables should have common data columns).
For Example, Work Class and Worklist Class. 1. pyID of Worktable= pxrefobjectinsname 2. pzInskey of worktable= pxrefobjectkey.
**They are four types Report Definition.
a. Class Joins (Two or More table can be joined): - Created a report to fetch data from work table and worklist tables by Class Joins.
b. Association (Two table can be Joined its reusable Join): - Association rule defined Joins b/w two classes. This rule can be reused for
Joins. *** Association rule can be directly referenced in the select clause or where clause by its name. Let’s impl above report using
association Joins. -> For this we need to create association rule which defines Joins b/w work class and work list tables. PRPC provides
OOTB association for the Same “pxWorklistAssignments”.
C. Index Joins (Joins can be done on index table): - Indexing in pega can be done for Embedded properties like page list. When we Optimize
Page list properties, PRPC create a dedicated tables for Page list. This table each row corresponds to one index page to page list.
1 Index Class (derives from OOTB class Index-) 1. Properties 2. Declare index 3. Perform joins b/w work and page list index class
D. Sub-Report: - A sub report is a report that is called by another report to provide data. Sub reports enable you to reference results
from any report definition in the main report.
Case Management:
Case Management is a technique of designing or defining the case life cycle to have multiple work object been created.
In Case Manager we have one Parent Case (Cover Case) and remaining are children (covered cases).
If we want to access data from child to parent, then we have to open parent case by obj-open or open-by-handle and update it back
to work table.
On Parent Case
pxCoveredCountOpen = The number of child cases which are yet to get resolved.
* Under pyWorkPage of Parent Case we have an OOTB Value List property, pxcoveredInsKeys
While Processing parent case, if we want to read the pzInsKeys of child cases, those will be available on Value List
pyWorkPage.pxCoveredInsKeys.
1. Default locking: The moment a case is opened, lock will get acquired.
2. Optimistic locking: This allows more than one user to open a case at a time. Lock will not be quired on open but it gets acquired
when an action is been performed on the case like submit.
Lock table is PR_SYS_LOCKS.
1.What are Differences between Edit Validate & Constraints & Obj Validate.
**It can be created under Data Model Category., Edit Validate is instance Class is Rule-edit-Validate.
** It can be created under Decision Category., Declare Constraints is instance Class is Rule-Declare-Constraints.
** It can be created under Process Category., Obj Validate is instance Class is Rule-Obj-Validate.
Edit Validate Constraint Obj Validate
One property can be validated Multiple properties can be validated Multiple properties can be validated
This gets executed where ever we use This gets executed where ever we use This is specific the Screen / flow
property. property. action on which we call it.
This is Client-side validation This is Client-side validation This is Server-side validation
This has to be explicitly called on There is no need to call this, This has to be explicitly called on flow
property automatically called internally when action or activity
we use properties.
This is not a dependent validation This is dependency validation This can be dependent / independent
validation.
This required java coding. This one-use functions This one uses functions.
Local Action: - It allows us to perform an action on the assignment but still WO will be there on same assignment and assignment will not be
completed. Example: - Pop Up Windows, Attaching documents to WO. ** When We Create Local Action make sure go to Action Tab Change into
Local Action.
Local Action Can be called from, 1. A control Events. 2. Assignments Shape. 3. Diagram tab of Work Flow 4. Case Type Rule.
** If we call local action on assignment or Flow or Case type, we can access that using Action drop down of Work Object Form
5. What are the Split Join, Sub Process, Spin Off, Split for Each.
Split join: - Using this flow shape we can call multiple sub flows. All these sub flows gets executed parallel. Once all the sub flow are
completed, process flow can be resumed. ** When we select ‘Join Any’, Process flow can be resumed when any of the sub flows completed.
2.** When we select ‘Join Some’ process flow can be resumes when any of the sub flows completed with a when condition met.
Split For Each: - Using this flow shape we can call one sub flow. 1.This flow shape takes the Page List a parameter to it and executes the sub
flow N number of times where N = number of pages in page list.
Spin Off: - This option is available in sub process shape, when selected, both process flow and sub flow will run parallel. This is called
asynchronous processing.
Sub Process: Using this shape we can call only one sub flow where the process flow will wait for sub flow to be completed. Once
sub flow is completed process flow can resume its execution.
6. What is Circumstance?
Circumstance is creating multiple variants of a single rule with conditions.
Two types of circumstance
1. Single property circumstance: The condition involves only one property
2. Multi property circumstance: The condition involves multiple properties
We need to create two other rules for multi property circumstance
1.Circumstance template Rules. It can be created under Technical Category., Circumstance template is instance Class is Rule-
Circumstance-template.
2. Circumstance Definition rules. It can be created under Technical Category., Circumstance Definition is instance Class is Rule-
Circumstance-definition.
Forward Chaining: - Whenever input properties are changing the target property value gets automatically updated. This is called “Forward
Chaining”. ** In declare expression under “change Tracking” Tab we have dropdown option “Whenever input change” This is defaults option
Expression.
Backward Chaining: - In Declare Expression under “Change Tracking Tab” In dropdown if we select option. “Whenever used” It works as
backward chaining. *** Whenever used depends on target property usage. “N” number of times target property is used then “N” times
expression will be executed.
Now expression will be executed every time target property is used. This is “Backward Chaining”.
3.Declare on change: The Purpose of Declare on Changes is to Executes Activities automatically whenever there is a change in property
value. It can be created under Decision Category., Declare on Change is instance Class is Rule-Declare-On change.
4.Decalre tigger: Declare trigger rule gets executed declaratively when an Obj Method gets executed on Rule base tables. This gets auto
executed when DB table Action performed. . It can be created under Decision Category., Declare tigger is instance Class is Rule-Declare-Tigger
5.Decalre Index: Indexing Improves the performance of application when running the reports. It can be created under SysAdmin Category.,
Declare Index is instance Class is Rule-Declare-Index.
** If we want use any properties in Report rules, we need to optimize those properties.
Unlike normal properties, when we optimize page list properties PRPC will create below Rules.
1.Index Class which gets Derived from the OOTB class ‘INDEX’. This index class is been mapped to an index table.
2.Declare index rule which maintains the mapping b/w Data table and index table.
6.Declare Pages (Data Pages)
8. What is Harness.
Harness is a UI rule. Harness Holds Sections. Harness defines appearance and processing of Work Object Forms or Portals.
Every User Interface that gets loaded in PRPC, is be defined or created using Harness rule Type. It can be created under User
Interface Category., Harness is instance Class is Rule-HMTL-Harness
Harness in a Work Object life cycle, PRPC uses difference OOTB harness for work object form New-Perform-confirm.
1. New: - This is responsible for Creating Work Object on click of Done Button. This is Editable harness.
2. Perform: This harness gets loaded at every assignment. This is responsible for performing an assignment. This harness loads Flow
Action and Submit buttons. This is Editable harness.
3. Confirm: This harness gets loaded when there is no assignment to perform. This is read only harness. This can be used to display the
summary of WO Data.
4. Review: This is read only harness. To review the work object data and re assign it for modifications. This is for system internal usage.
Any user defined harness which is read only, will treated as Review Harness.
9.What is Routing?
Routing: Assigning work to an operator is called Routing. An Assignment can be particular operator by means of Routing.
Routing option is available under. 1.Assignment shape properties in Process Flow. 2. Start shape Properties in Screen Flow.
Two Types of Assignments based on Routing. 1. Work List Assignment. 2. Work Basket Assignment.
1.Work List Assignment: When an assignment is created and routed to single Operator. It will be created as an instance Assign-Worklist. The
assignment gets stored into PC_ASSIGN_WORKLIST table. The OOTB activity that gets executed is “toworklist”
2.Work Basket or Queue Assignment: Multiple operators will have access to basket. All of them can see the tasks in basket and only one pick
and work on task at a given time. Assignment is instance of class Assign-Workbasket. The assignment gets stored into PC_ASSIGN_WORKBASKET
table. The OOTB activity that gets executed is “toworkbasket”.
Data transform can be used to assign values to properties, assign one page data to another page, copy pages from one page list to another page
list.
Web services can be used to establish connection between two applications over web, in order to exchange Data.
Using web Services two application can communicate on web using different Protocols like SOAP, REST, MQ, HTTP, etc... When communicate
one application is going to request for data from other application.
The application which requests for Data is called as consumer and the app which responds is called as Provider.1. Consumer is going to send
Request whereas Provider is going to Respond.
PRPC application can be a requestor or provider. (Being PRPC application a requestor/ Consumer we need to create CONNECT rules like
Connect-SOAP, Connect-REST, Connect-MQ etc…) (Being PRPC application as a provider/Respond we need to create SERVICE rules like
SERVICE-SOAP, SERVICE-REST, SERVICE-MQ etc…)
SOAP protocol supports XML Data structure. While using SOAP, being a consumer or provider, we must have to implement below two
techniques
1. Converting from Clipboard to XML (XML Streaming) For this in Pega We have to Create XMLStream Rule.
2. Converting from XML to Clipboard (Parsing XML) We have to create ParseXML rule.
To locate the service, we need END POINT URL. While Working with Building of SOAP service, once service is create we need to generate
WSDL URL and provide it Requestor.
WSDL: Web Service Description Language. This document contains details about web service (SOAP Service)
Details Are: 1. End Point URL, 2. Request Parameters,3. Response Data Structure,4. Authentication Details.
Providing WSDL URL to requestor’s means, providing all the Meta Data about service.
SLA can be created under Process Category. Service level agreement defines the goal, deadline and passed deadline time intervals, urgencies
and escalations. SLA can be created and applied on an assignment or on a work object. SLA there is two types of SLA Available
1.Assignment level SLA: - When an SLA is Applied on assignment shape then it is said to be Assignment’s level SLA. Here SLA is applicable only
to one assignment on which we call it. ***(To apply SLA on an Assignment, go to assignment Service properties level = SLA rule Name)
2.WO Level SLA: - When an SLA is Applied on WO. It is said to level SLA.WO level SLA can be applied by assigning the property. WO Level SLA
will be applicable in the work flow.
SLA Defines three-time intervals for a task to get completed also It defines the Urgency (Priory).
SLA Time intervals are 1. Goal Time 2. Deadline Time 3. Passed Deadline Time
1.Goal Time: - Goal Time start calculating immediately once the assignment gets created on which we apply the SLA.
2.Deadline Time: - Deadline Time start calculating immediately once the assignment gets created on which we apply the SLA.
3.Passed Deadline Time: - It Starts Calculating from the time deadline is completed.
Urgency: - Urgency defines the priority of an assignments. Urgency value ranges from 0-100 where 0 is minimum and 100 is maximum.
1.Default Urgency: - Which can be assigned to the OOTB property pxUrgencyWorkClass in the pydefault Data transform.
2.Initial Urgency: - which can be defined in SLA rule Form. Once the task is created Initial Urgency. Value = Default Urgency +Initial Urgency.
3.Goal Urgency: - Once the Goal time is completed. Urgency = Default Urgency +Initial Urgency + Goal Urgency.
4.Deadline Urgency: - Once the Deadline time is completed. Urgency = Default Urgency +Initial Urgency + Goal Urgency+ Deadline Urgency.
5.Passed Deadline Urgency: - Once the Passed Deadline Time is Completed. Urgency = Default Urgency +Initial Urgency + Goal Urgency+
Deadline Urgency+ Passed Deadline Urgency.
We can add more than one escalation at a given time interval. At dead line and passed deadline the same type of escalations can be defined.
All these escalations gets executed in Back ground upload goal , deadline and passed deadline times breaches.
1. Once assignment is ready (Default): Once assignment is created SLA starts running.
2. Dynamically Defined by Property: We can use a Date time property, once this property value is matching with current server time
then SAL will get start running.
3. Time Delay: we Mention
Data Type is Just like a Table which will have Data Storage. Make sure that Your Data Types create under Data Classes. Data Types Must be
derived from OOTB class “Data- “. Data Type classes are Concrete Classes, which “Does Not belong to class group”. Does Not belong to class
group: - This means the classes will not fall under inheritance path of Class Group. This are Global to multiple different class groups.
When We create a Data Type PRPC automatically Creates Below Components and Rules.
1. It is going to create a Concrete Class Under Data Class.
2. Properties (Which are like columns of table)
3. Physical (Dedicated) table gets created in Rule Base.
4. Data base Table mapping rules gets created.
5. Data Pages (List Type Pages, Page Type and Savable)
6. Report Definition
A. Activity is a rule which is used to implements business logic. It can be created under Technical Category., Activity is instance Class is Rule-
Obj-Activity.
Method: - Method is something which is already having predefined business logic written in Java Code. PRPC provides many different methods,
those can be accessed under Method Dropdown in an activity rule.
Obj-Browse: - This method is used to fetch multiple instances from a table. Data Structure is Page List and Data is Read only.
Obj-Open: - This methods can be used to fetch single Record from tables on Class Key.
Obj-open-By-Handle: - This method is used to fetch single Record from tables on Primary Key (pzInsKey).
Obj-Save: - This method can be used to insert or update an instance into Tables.
Commit method: commits the entire differ queue items respective table or tables. Commit method releases lock
Write Now: It is an immediate commit operator which is being done only on one table. This option in obj-save cannot release the lock.
Rollback method erases or rolls back entire differ queue items means all the obj-saves done in a thread. The roll back will not have any impact
after the commit is executed.
Obj-save-cancel: erases or rolls back only the latest un committed obj-save.
This method will not have any impact after the commit is executed.
We need to write both business and transaction logic. We are required to write only business logic. Transaction logic
will be taken care by Process commander.
This mode of agent is recommended for non-transactional This mode of agent is for transactional processing.
processing
This agent will get sopped when an exception occurs. This agent is going to update the queue item status to “Broken-
Process” if an item processing fails…
It is going proceed processing remaining items after current
item.
Agent gets executed on the access group mentioned in agent rule Agent activity gets executed on Requestor’s access group who
form. had kept the queue item in queue table.
If we do not mention any access group, it runs on guest access
group
16. What are the difference between Comparison/differences between Obj and RDB methods for Internal and External DB tables.
Obj Methods RDB Methods
Obj Methods will work on Rule base tables as well as external DB tables. RDB work on Rule base tables as well as external DB tables, but it can
fetch only Exposed columns.
Obj Methods can fetch the content saved inside BLOB column. RDB methods can NOT fetch content available inside BLOB, it can
retrieve BLOB as BLOB.
Obj-open-by-Handle, OBJ-Delete-by-Handle can be used on Internal Obj-open-by-Handle, OBJ-Delete-by-Handle can NOT be used on
tables. External tables.
When using Obj methods class and table is mapping is must. When using RDB methos.
• If we are writing query like
SELECT vinid, company, model, make year FROM {Class:
Hano-Data-vinvalidation}
WHERE vinid = '{Asis: MyServicePage.Request.Input.VIN}'
Obj Methods Auto Generates the Queries and that too those are RDB methods, we need to write queries in connect SQL rules.
optimized w.r.to Process Commander.
When using OBJ methods, Query gets generated at run time, converted When using RDB methods, Queries are Direct Queries hits the DB.
to post Query then it hits the DB.
When we use the direct tables name in Connect SQL rule.
Obj Methods cannot Execute Stored Procedures. RDB-List can call Stored Procedure.
OBJ Supports only Inner Joins.
RDB supports All Joins.
1.1 Can we run a report definition on external table?
A. yes, as long as we have class and table mapping is there.
• What is the limitation w.r.to joins while using report definition in internal or external tables?
A. RD supports only inner and full joins but not Outer.
*What are the reasons pega has RDB methods, when we can use Obj Methods for external tables as well.
1. In a connect SQL we can writes joins among multiple tables, where it supports all joins like inner, outer, full joins.
2. We can call stored procedures using connect SQL tab, Browse tab.
1.2 How to create a DB, Tables & define Privileges using Postgres SQL Environment?
Requirement: Create an External Database ‘primextdb’. Create a table ‘vindetails’. Column VIN is Primary Key.
Make a connection between PRPC environment and above DB and its tables.
1. In Bound: When an email is received, PRPC read the email content and process the data.
2. Out Bound: Sending an email notification being trigger from a mail box by Process commander. Mail box can be, Gmail, Hot mail,
Yahoo, outlook etc…
SendEmailNotification @baseclass
To work with Out Bound Email Integration, we need to know the below inputs.1. From Email Address 2. SMTP Host of the From Email Box.
3. Password of From Email Address. 4.To Email/Emails.
DSS (Dynamic System Settings): - DSS entries allows us to maintain different values for Different application server environments by allowing
us to change the values without check in and check out.
18. What is Agents?
Agent is internal background process or requestor, which is gets associated with 1) Schedule 2) Activity 3) Access Group 4) Mode.
Agents wakes up at the sc he dul e time and exe cute s its associated activity. When an agent wakeup, it will run on the associated
access group. PRPC has a predefined master agent ‘System Pulse’, which wakes up all the user created agents at their schedule time.
** Agent is an instance of Rule-Agent-Queue Whereas agent schedule is an instance of Data-Agent-Queue.
Modes Of Agent: - There are 3 differences modes available.
1. Legacy: - This mode is been deprecated from PRPC version 5.4
2.Advanced: - a) When an advanced wakes up at schedule time it will directly executes agent activity without bothering about Agent
Queue Items. B) Usually, we will create advanced without applying AQM (Auto Queue Management) and these agents will be
configured to run on Single Node. C)In an advanced Agent Work Object locking and Transactional Commit must be taken care by our
self.
3.Standard agent: - Standard agent will be applied with AQM
AQM (Auto Queue Management): - This programmed is responsible for instructing the agent weather r to executed associated agent activity
or not. When the Queue Items are there, standard agent will execute agent activity else it will not execute activity thus go to sleep.
Queue Items can be put into agent queue table PR_SYS_QUEUES by using the method/activity. Queue-For-Agent/QueueForAgent.
When the standard agent wake it will execute the agent activity ‘N’ number of times (with status=scheduled) where ‘N’ is the number of
Queue Items in the PR_SYS_QUEUS table.
1.Scheduled: - This is initial status when a queue is been inserted into the table and which gets process by agent during next run.
2. Now-Processing: - This means that the Queue is picked by agent and is being processed.
3. Broken-Queue: - When Queue items fails in its processing, the status will be updated to Broken-Queue.
1.Cache 2. Rule set Versions 3. Circumstance 4. Inheritance 5. Rule Authorization 6. Rule availability
Available: Current class, highest version is available, the rule will get picked, processed and presented to requestor.
Not Available: Current class, highest version is NOT available, the rule is ignored for higher version, Process commander has picked the rule
of previous version of same class, processed and presented to requestor.
Final: Current class, highest version is FINAL, the rule will get picked, processed and presented to requestor.
Withdrawn: Current class, highest version is WITHDRAWN, the rule is ignored for higher version, and all previous version of current class.
Process commander has picked the rule from parent class