Professional Documents
Culture Documents
Table of Contents
1. Introduction to BPM & BRE ................................................................................ 3
2. General PRPC Architecture .............................................................................. 12
3. Class Structures & Hierarchy Design............................................................ 31
4. Data Modeling...................................................................................................... 44
5. Process Flow ........................................................................................................ 50
6. Case Management ............................................................................................... 67
7. Activities .............................................................................................................. 73
8. User Interface ................................................................................................... 92
9. Decision Rules & Declarative Rules .............................................................. 115
10. Rule Management/Security .......................................................................... 126
11. Integration ....................................................................................................... 150
12. Implementation and Performance Tools ................................................... 179
13. Reporting .......................................................................................................... 191
14. Application Deployment ................................................................................ 203
Business rules become requirements, that is, they may be implemented in a software
system. BREs can be used alone or in conjunction with other technologies, like
Business Process Management (BPM).
A business rules engine is a software system that executes one or more business
rules in a runtime production environment.
BRE is the software that automates policies and procedures within an organization,
whether legal, internal or operational. The use of a rules engine (BRE) requires
placing the company rules in an external repository that can be easily reviewed rather
than buried inside the code of numerous applications. Instead of a program executing
internal algorithms, it goes out to the BRE to obtain its business logic.
A BRE enables software changes to be implemented much faster than changing
source code. It can also ensure that the same rules are applied in all programs on all
platforms across departmental lines. In addition, it supports platform changes. New
software can be deployed knowing that the same business logic is going to be
executed in the new programs.
This means that the rules engine is capable of getting data through services, process
the data with some business logic, and return results through services. It can also
interact with other backend systems to get more information, validate data etc, but
through services.
Advantages of Business Rules Engine:
C Quick development
C Easy Rule move from one environment to another environment
C Business Users can update the rule directly without IT help (Up to some level)
C Lot of in build functionality. No need to write thousands lines of code (For
Example Parsing XML, Generating XML, Connecting external system.)
SmartBPM
The latest generation of PegaSystems' industry-leading, rules-driven Business Process
Management (BPM) is a comprehensive suite intended to help businesses plan, build,
and manage process-management solutions through their entire lifecycle.
SmartBPM is a process that blends your process and practice rules and helps you
rapidly deploy and update solutions in response to changing circumstances.
SmartBPM Suite contains the below Components
1.
2.
3.
4.
5.
6.
7.
step describes how to design and build specific components. You perform these steps
and the associated tasks iteratively to deliver a fully functional solution. In short,
SmartBuild is the design and development process for Process Commander Solutions.
Services are interfaces from other systems to PRPC. Standard services that come in
with PRPC are
1. Rule-Service-COM
2. Rule-Service-CORBA
3. Rule-Service-BPEL
4. Rule-Service-File
5. Rule-Service-HTTP
6. Rule-Service-Portlet
7. Rule-Service-DOTNET
8. Rule-Service-EJB
9. Rule-Service-Email
10. Rule-Service-JMS
11. Rule-Service-JSR94
12. Rule-Service-MQ
Connectors are interfaces from PRPC to other systems. Standard connectors that
come in with PRPC are
1. Rule-Connect-EJB
2. Rule-Connect-BPEL
3. Rule-Connect-File
4. Rule-Connect-HTTP
5. Rule-Connect-JCA
6. Rule-Connect-DOTNET
7. Rule-Connect-SQL
8. Rule-Connect-Java
9. Rule-Connect-JMS
10. Rule-Connect-SOAP
11. Rule-Connect-MQ
Standard access roles (with names starting with PegaRULES:) define capabilities for
below PRPC model users
a. Business Users
1. Business User : End user of the application
2. Business Manager : Who monitors the performance of users or user
groups
b. Developers and Implementers
1. Process Architect: A business analyst who defines and maintains
business rules, service levels, and flows
2. System Architect: An application developer who creates class structure
for the application and who builds the interfaces with external systems
3. System Administrator: System engineer who is responsible for
installation and setup, security, and high level configurations
RuleSet name is an instance of the Rule-RuleSet-Name rule type. Each RuleSet
defines a major subset of rules in the PegaRULES database, because every instance of
every rule type references or "belongs to" a RuleSet. Together with the RuleSet
version, a RuleSet name is a major aspect in:
Access control
Managing the rules
Moving applications sets of rules from one Process Commander
System to another.
RuleSet version is an instance of the Rule-RuleSet-Version rule type. The version
number in the form NN-NN-NN, defines six digits in three groups that characterize
the evolution and development of a rule instance, and of the application it belongs
with. The three segments are known as the major version, minor version, and patch
version.
RuleSet Format
LoanAppl 01-02-03
01- Version
02 Minor release within the version
03 Interim or patch release within minor release
Rule resolution is the sophisticated internal search algorithm that the system uses
to find the best or most appropriate rule instance to apply in a situation. Rule
resolution applies to most, but not all, classes derived from the Rule- base class.
Rule resolution uses as input values:
The name of the rule needed
10
Questions:
1. Typically, the process architect maintains which of the following rules:
a. Decision tables
b. Decision trees
c. Access roles
d. Access privileges
e. Correspondence
f. Expressions
2. Typically, the system architect maintains which of the following rules:
a. Properties
b. User interface rules
c. Services
d. RuleSets
e. Indexes
3. Typically, the system administrator maintains which of the following rules:
a. Flows
b. Portal access
c. User IDs
d. Activities
11
12
PegaRULES has a flexible, open architecture. It allows you to execute the rules
engine in a variety of configurations and platforms. In addition, PegaRULES nodes
can run concurrently on heterogeneous platforms. This capability provides flexibility
to system administrators in configuring and deploying user accounts or execution
models against a shared PegaRULES database.
13
PegaRULES runs as a collection of loosely coupled nodes that bring the execution of
processes and rules in proximity to the requesting user or system. PegaRULES can
support various architectural designs. The patterns shown in the following sections
are examples of fundamental implementations.
Basic Multitier Pattern with Servlets
PegaRULES runs as servlets within the Web container of a J2EE application server
(or a servlet container, such as Apache Tomcat). The rules engine runs self-contained
within the Java Virtual Machine (JVM).
14
server (or a servlet container, such as Apache Tomcat). PegaRULES also supports
server tier architectures and EJBs.
Process Commander is designed to run as a Web application, built in a Service
Oriented Architecture (SOA) to support a Web services environment, such as
SOAP and other industry-standard transports. While these architecture patterns are
well served by the J2EE framework, two other primary integration methods batch
and embedded are not. For certain high-performance applications, embedded or
batch processing provides a better alternative. For this reason, Process Commander is
built to run within the J2EE environment without inheriting its limitations.
In the multi-tier architecture, Process Commander sends HTML to the browser for
both business user and developer/administrator functions. HTML screens are
managed using specialized HTML rules within the rules engine.
Embedded Java Application Pattern
PegaRULES supports the JSR 94 standard rules application interface (API). The rules
engine can be invoked through the Java API and can execute within a rules engine
application on the same Java virtual machine (JVM). With this pattern, client
applications can embed the rules engine in the overall Java code of their applications.
15
16
17
prweb.war or prpc_j2ee14.ear
Note: The legacy packages listed below are provided only for existing
customers to support backward compatibility. Contact customer support before
deploying.
18
prweb.war
prweb.war or prpc_j2ee13.ear
prweb.war or prweb_j2ee14.ear
prweb.war or prweb_j2ee13.ear
When upgrading Process Commander, you should generally install the core
component package that is currently in use in your environment. That is, existing
WAR deployments should deploy the 5.5 SP1 WAR component; existing EAR
deployments should deploy the 5.5 SP1 EAR. However, if you upgrade the
supporting platform components at the same time as Process Commander, or if your
integration requirements have changed, you may need to change the PRPC core
component and your system configuration.
Note: Please refer the Pega Installation Guide from the PDN site for any detailed
Deployment procedure.
The prerequisites for installing Process Commander are:
An application server host computer with adequate memory and disk space for the
installation. Process Commander requires a minimum of one GB of free memory.
This is in addition to any memory allocated for the operating system or other
applications on the server. The memory required for your system may need to be
higher, depending on the number of users and your specific configuration.
A working installation of the application server.
A configured relational database available for Process Commander use, and
support in your organization for the installation and configuration of relational
databases.
19
Note: The database and application server platforms may be either UNIX or
Windows systems. However, a Windows system is required for the Pegasystems
developer and end-user clients and for some of the Pegasystems monitoring tools,
specifically, PegaRULES Process Analyzer, Process
Simulator and Autonomic Event Services. The environment for your initial
Process Commander system should include at least one Windows platform.
Caching
To allow the powerful Rule Resolution process to occur with the required
performance levels for enterprise-scale systems, PegaRULES has a series of caches.
A cache contains data that has been copied out of one place and stored temporarily in
another for easier access. In Process Commander, some caches are stored in the
system memory (JVM), some are stored in the database, and some are stored on disk.
Caches stored in memory include:
Rule cache
Rules Assembly cache
Conclusion cache
Caches stored on disk in the file system include:
LookupList cache
Static Content cache
Rule cache holds data about the reads done from the PegaRULES database for rule
classes. The first time a rule is requested from the database, the cache has no
information about it. It passes the request on to the database, and the system attempts
to retrieve the information from the database. If the data is available in the database,
the system retrieves the rule, stores it in the Rule cache, and then sends the rule
information back to whichever process requested it. The next time that information is
required, it is retrieved from the cache instead of the database.
Rules Assembly cache is used to minimize Java code generation and compilation
mainly by tracking RuleSet lists and user entries. Rules assembly is the process
whereby all the rules run by the Process Commander system are generated into Java
code for the system to execute. Rules assembly, especially code compilation, is
extremely resource intensive and comprises a series of processing steps.
A conclusion is an instance of a Java object (resulting from the Rules Assembly
process) that was generated, instantiated, and then persisted to the database for future
use. The unique feature of conclusions that differentiate them from normal Java
object persistence is that these classes also rebuild themselves in response to rule
changes (just like all other types of rules). The benefit of conclusions is that they
group a number of similar rules, and digest the information down to the minimum
amount required at runtime.
20
Rules Assembly is the process whereby all of the rules which are run by the Process
Commander system are generated into Java code for the system to execute. Since
Rules Assembly is an expensive process (in terms of system resources), the process
has been broken down into several steps to maximize performance and efficiency.
When the system calls a rule to be run, if that rule was never executed, the Rules
Assembly process must:
assemble the rule, including all the other rules required (for example, if this is an
activity rule, it may call other rules)
generate the Java code for the rule
compile the code
load and execute the resulting class file
Of these steps, the code compilation is the most expensive. Therefore, several Rules
caches have been added to try to minimize Java code generation and compilation.
During Rules Assembly, one of the key factors is the users RuleSet List, as that
controls which rules the user may see. Two users with different RuleSet Lists may
call the same named rule, but due to their different Lists, the rules selected and the
code ultimately generated may be quite different. Similarly, it is possible for two
users with different-yet-related RuleSet Lists to call for the same named rule; because
the rules are defined entirely in the RuleSets they have in common, the generated
class is exactly the same. Due to these factors, a cache structure is maintained in
memory, keyed by a combination of the RuleSet List and Rule Name (its purpose)
that maintains a reference to the generated class files loaded instance.
Static Content Cache
In PegaRULES, static content files contain information presented to users which
doesnt need to be constantly processed, such as form images or help files (example:
the login splash screen, which will not be affected by changes to rules or to work
items). In PegaRULES Process Commander, the main Rules which contain static
content are:
Rule-File-Binary
Rule-File-Form
Rule-File-Text
These rules are read from the database using the Rule Resolution process, and the
files are cached to the server file system (not into memory). Since these files dont
change rapidly and are expensive to read from the database, they can persist in the file
system through system shutdown and startup, and be retrieved as a file, rather than
spending the resources to constantly retrieve the data from the database.
The static content data is actually cached in two places:
on the client (each users PC)
on the server
21
Static Content Cached on the Client is standard browser caching. Whenever a user
requests static content (Rule-File- forms, Help forms, and other static content in the
WAR file), that information will be cached in the browser on the client side. It is
possible to set an expiration tag on this information, which will tell the browser to
look first in its cache for data before asking the server again.
Static Content Cached on the Server: The first time information from a static file is
requested, the system searches the directory structure for the requested rule, in the
following order:
Personal RuleSet subdirectories
(\rule_cache\webwb\RuleSethashname\PersonalRuleSethashname)
RuleSet List directories (\rule_cache\webwb\RuleSethashname)
the WebWB directory
(NOTE: Just as the Rules in the personal RuleSet override the Rules in the main
RuleSets, so the static content in the Personal subdirectory overrides the static files in
the main subdirectory.)
LookupList Cache
LookupLists contain information that displays in dropdown boxes in Process
Commander. These are items (such as the SmartPrompts) which are built on a
complex query that takes a long time to run (perhaps more than two seconds). Since
this information is so expensive to produce, it is cached to improve performance.
The LookupList cache is stored similarly to the Static Content Cache, in the file
system. Files are put in the contextroot/webwb/llc directory, and grouped by
classname.
Example:
prweb/webwb/llc/Rule-Obj-Fieldvalue
prweb/webwb/llc/Rule-HTML-Harness
The first time a LookupList is requested, the system searches the directory structure
for the requested rule, in appropriate class subdirectory under LLC. If the file is
present, it will be returned. If the file is not already cached, the system will load the
file from the database, and also write the file to the LookupList cache on disk.
Again, the LookupList cache should have to be cleared rarely, if ever. If something
that is done that modifies rules outside normal processing, such as importing rules
using the PRImpExpServlet, then the cache must be cleared to pick up the new data.
Also, if there was a problem with the system pulse, and data was not correctly
propagated to the other nodes in the system, the LookupList Cache should be cleared
(along with various other caches).
The consequences of clearing the cache is that the system must check the cache
before going to the database, and then cache everything again, which will slow
performance until the caches are rebuilt.
22
23
Agents
Agents are internal background processes operating on the server that run activities
according to a schedule. Agents are autonomous and asynchronous. The activities
they call run individually on their own schedules and one activity does not have to
finish before another one runs.
Agents are implemented through two Process Commander objects:
Agent queue rules
Agent schedule data objects
Agent queue rules instances of Rule-Agent-Queue. These rules specify the
activities the agent runs and the interval, in seconds, at which it runs them. There can
be no more than one agent queue rule in a RuleSet.
Agent schedule data objects instances of Data-Agent-Queue. Process Commander
generates these schedules for each node in the system, based on the settings in the
agent queue rule. For each agent queue rule, one agent schedule is generated for each
node in the system.
Two built-in master agents are background processes operating on each Process
Commander node that manage requestor sessions and agents defined through agents
rules and agent schedule data instances. They are not defined by agents rules.
(Technically, these are daemons, rather than full agents.)
The Master-for-Requestors (Requestor Manager) master agent monitors idle
requestor sessions to enforce automatic timeouts. By default, this occurs every 60
seconds. Your site can establish another value in the prconfig.xml file setting:
<env name="agents/requestortimeoutwakeup" value="NNN" />
The Master-for-Agents (Agent Manager) master agent starts and monitors agents
defined through agents rules and agent schedule data instances. By default, the
Master-for-Agents master agent awakes every ten minutes. Your site can establish
another value in the prconfig.xml file setting:
<env name="agents/newqueuewakeup" value="NNN" />
where NNN is in seconds.
Process Commander relies on two standard agents:
Pega-ProCom
Pega-RULES
If your system is using the PegaDISTRIBUTION Manager application, Process
Commander also uses the Pega-IntSvcs agent.
24
The Pega-ProCom agent queue rule is configured to run two activities by default and
two additional activities if you enable them:
25
26
<env name="database/databases/Northwind/url"
value= "jdbc:microsoft:sqlserver://shelpnt:1433;SelectMethod=cursor"/>
<env name="databases/databases/Northwind/userName" value="Smith" />
<env name="database/databases/Northwind/password" value="password" />
<env name="database/databases/Northwind/maxConnections" value="3" />
Q. If the Database connections limit exceeds then what error will be thrown by
PRPC?
a) SQL exception
b) Java Database exception
c) Page level error
d) None of the above
Q. What alert will be set to detect long database call waits?
a) PEGA0001
b) PEGA0014
c) PEGA0026
d) PEGA0023
Sybase databases are accessible only through Connect SQL rules. Sybase is not
supported as a host for the PegaRULES database. If your PegaRULES database is
hosted by Oracle 9, the Type 2 (OCI or thick client) driver is required; the thin client
(Type 4) works with Oracle 10g.
Use Connect SQL rules (Rule-Connect-SQL rule type) to access relational databases
other than the PegaRULES database. Tables and views in the PegaRULES relational
database become visible through Database Table instances (Data-Admin-DB-Table).
Q. Do we need to undeploy and redeploy the PRPC configuration file prconfig.xml
after any changes to Database setting?
True
False
Q. Which background process will save the User pages in PRPC?
a) Clipboard
b) Passivation daemon
Obj-Save method: Use this method to request that the system save a clipboard page
to the PegaRULES database or (if the page belongs to an external class) an external
database. We can reverse the effect of an Obj-Save method if it has not yet been
committed with the Obj-Save-Cancel or the Rollback method. It specifies that an
object should be saved. By default, Obj-Save sets up a deferred write operation that
does not occur until the next commit operation executes.
27
28
Generally speaking, activities that commit objects use the following pattern:
1. Commit the deferred operations list.
2. Evaluate the results of the commit step.
3. If the commit failed:
Report errors to the clipboard page and to the Pega log.
Roll back the operations.
The Work-.commitWithErrorHandling activity also illustrates how to report errors
when a commit operation fails.
Transaction Model
The applications need to participate in distributed transactions, Process Commander
must be deployed as an enterprise application and must use a JDBC driver with XA
support.
Q. What is the default transaction model of Process Commander?
a) Bean-Managed
b) Container-Managed
Bean-Managed transaction: When running in this mode, Process Commander is in
charge of the (distributed) transaction. Process Commander issues the begin statement
and the final commit or rollback.
Container-Managed transaction: When running in this mode, an external J2EE
container starts and ends distributed transactions that Process Commander joins as
one of the participating resources. When Process Commander finishes its work, it
submits a list of operations to the resource manager(s) or it marks the transaction for
rollback. Only the processing managed by certain Process Commander Service rule
types (EJB, Java, and JMS) can participate in container-managed transactions.
Deferred Operations Model
This method does not always cause the object to be written immediately to the
database. Often, developers use this method perform a deferred write operation. In
such cases, later execution of the Commit method, in the same Thread, completes the
database update.
The standard HTML rule @baseclass.DeferredOps interrogates system internals and
presents an ordered list of deferred (uncommitted) database operations for the current
Thread.
In addition to the object locking feature, Process Commander ensures data integrity
by creating a deferred operations list during a business transaction rather than writing
each change to the database individually.
29
Locking
Object locking for work objects is enabled by default. Object locks are associated
with users' requestors. Requestors obtain a lock on a work or other object when the
user opens an object for modification. While the requestor holds the object lock, no
other requestor can make changes to that object. After the processing of the
application causes the changes to be written to the database, the lock is released and
the object is available to another requestor.
Object locks have a timeout interval that is set to 120 minutes by default.
Mechanisms provided by your database management system that control how/whether
operations access data at the same time. Database locking provides functionality such
as preventing two write operations from committing changes to the same row at the
same time.
A Java object that holds information about a user and that user's session. In Process
Commander, users are represented as requestors and object locks are associated with a
user's requestor.
When selected, ReleaseOnCommit parameter instructs Process Commander to release
the object lock on the item being opened when changes for the object are committed
to the database.
Threading Model
A PegaRULES Thread object is a named context of clipboard pages. Most processing
for a requestor is single-threaded. The first Thread for a requestor is named
STANDARD. The pxThread page is a named top-level clipboard page sometimes
referred to as the thread page. The class for the page is Code-Pega-Thread.
Q. What is Pega alert in case of number of threads exceed the limits?
a) PEGA0011
b) PEGA0018
c) PEGA0026
A requestor can have multiple Threads, but the Threads are guaranteed to never run
concurrently. A daemon is a reserved background Java thread that executes as a
BATCH requestor type. Ex: Passivation daemon Saves requestor sessions after
timeout or other situations
The PEGA0030 alert is generated when the number of requestors logged onto the
system (including agents and services) exceeds the alert threshold.
30
31
Organizational Hierarchy
When a user log in with an operator ID, their organizational affiliations grant them
appropriate RuleSet access. The ID also identifies two additional affiliations: work
group and access group.
Work Groups - Users and the work they do are tied to work groups, which fall
below units in an extended organizational hierarchy. Users working on a common
set of items generally belong to a single work group.
Access groups - Users' application permissions, portal layout, and accessible
work are controlled by access groups. Access groups may span multiple work
groups, and typically mirror Process Commander job functions.
32
33
Reusability is the ability for PRPC to share the same instance of a rule, RuleSet,
and/or service so that it can be reused by other portions of the same application and/or
other applications.
Some examples of reuse that we see in PRPC are:
The Add activity defined at Work- that can be can be reused by many
applications as-is without customization
Utility functions that are defined in a shared RuleSet so that they can be
reused by multiple applications
The class structure provides you with a hierarchy in which rules can be
placed. The higher a rule is in the hierarchy, the more potential reuse there is.
However, a rule can only reference other rules at the same level in the
hierarchy or higher. For example, a rule X at class A- cannot call Rule Y
defined at A-B if no rule Y exists at A-.
Implementation Class vs. Framework Class:
An implementation class is a class that belongs to RuleSet that is one of your
application RuleSets. Classes for the implementation are sometimes called the
implementation layer.
A framework class is a class that belongs to RuleSet that is not one of your
application RuleSets. Classes associated with the framework are sometimes called the
framework layer.
Example: Typically, work objects belong only to implementation classes (work
types). To simplify, develop a list view and summary view reports. You can define
reports in framework classes that, at runtime, execute with the corresponding
implementation classes.
34
Class
Class defines capabilities (rules such as properties, activities, HTML forms, and so
on) available to other, subordinate classes, or to instances of the class.
Classes are organized into a hierarchy. The ultimate base class named @baseclass is
at the top (or left). The base classes Data-, Rule-, Work- and others are immediate
child classes of the ultimate base class. Other classes are derived from the base
classes. Classes can be either Abstract or Concrete.
Abstract class cannot have any instances, appears at the top level of the class
hierarchy. An abstract class is a rule (an instance of the Rule-Obj-Class class)
created to support the definition of rules, including other classes. A dash or minus
character "-" as the last character in the class name indicates an abstract class.
A Concrete class, near or at the bottom of a class hierarchy can have instances
stored in the database.
Concrete classes corresponding to instances saved in the PegaRULES database are
known as internal classes
Concrete classes corresponding to a table in an external relational database (rather
than the PegaRULES database) are known as external classes.
Concrete class that is a class group:
35
Concrete classes derived from the Rule- base class are known as rule types and
those derived from the Work- base class are known as work types. Concrete classes
dont end with a (dash).
The Rule- class and Work-Cover- class are abstract classes, while Work-CoverGeneral is a concrete class.
Custom classes that are immediate child classes of the ultimate base class are known
as top-level classes. These are different from base classes.
Inheritance is a primary benefit of object oriented technology. Process Commander
offers multiple types of inheritance that can maximize reuse of your rules while
allowing localized overriding as appropriate.
Inheritance allows a rule created for one class (possibly an abstract class) to be
applied to other classes that inherit from it.
RuleSet version inheritance works using three-level version numbers. For
example, users who have a version 02-15-06 in their RuleSet list inherit rules in
version 02-15-05, when no rule instance exists in 02-15-06.
RuleSet inheritance arises through the order of RuleSet names in the user's
RuleSet list. Rule instances in a RuleSet at the top of the RuleSet list supersede
others of the same name.
Organizational inheritance is implemented through a four-level assembly of
privileges and RuleSet versions through the access group, organization unit,
division, and organization.
Class inheritance searches for rules from a concrete, lower class, up the class
hierarchy to find available rules.
36
Class inheritance uses a sophisticated algorithm to find the parent classes of a specific
class. Two types of class inheritance directed inheritance and pattern inheritance
are available
Directed inheritance allows naming a class choosing a name that's not related to
its parent's name.
Pattern inheritance the name of the parent class is a prefix portion of the name of
the class, based on the dash (-) characters.
A class group instance causes the system to store the instances corresponding to two
or more concrete classes that share a common key format in a single database table.
Class groups are primarily used to group a set of related subclasses of the Work- base
class; such class groups are also known as work pools.
The following benefits of having class group:
All instances of classes that are associated with a class group share a common key
definition and common lock definition. This allows the database to save the
instances as rows in one table in the PegaRULES database.
The common key format also ensures that the same database table is accessed
when an instance is converted from one class (within a class group) to another
class (in that same class group). For example, a work object may initially be
entered incorrectly as a merchandise order, but later be reclassified as a
merchandise return request. Both work types have the same key structure and
belong to a common work pool (class group).
37
Class groups can help with database table management, backup, space, and
reporting.
A work object is a primary unit of work completion in an application, and a primary
collection of data that a flow operates on. As an application is used, the work objects
are created, updated and eventually closed i.e. it will be resolved. Every work object
has a unique ID (property pyID), an urgency value, and a status (property
pyStatusWork).
A work object ID is a permanent, external identifier of a work object, the value of
property pyID. This value has an optional prefix portion, a number, and an optional
suffix portion and is unique system-wide.
The standard activity named Work-.GenerateID uses the standard properties
pyWorkIDPrefix and pyWorkIDSuffix in its computation. By convention, an
ordinary work object ID has a prefix of W-nnnnn and no suffix, so W-9432 identifies
such an object. Conventionally, a cover object ID has the format C-nnnnnn, and a
folder object has the format F-nnnnn, where nnnnn is a system-assigned decimal
number. Normally the system assigns a work object ID automatically as it creates a
work object, using a prefix set in the model rule of the work type or work pool
The internal class Data-UniqueID supports work object numbering, and ensures that
work object IDs are unique system-wide, not just within an application or
organization. The property Data-UniqueID.pyPrefix holds the prefix and is the key to
instances of this class. The integer property Data-UniqueID.pyLastReservedID holds
the highest assigned number. The property Data-UniqueID.pyOrganization, a key
part, is not filled in by standard rules. This property value is left blank so that work
object IDs are unique system-wide.
The Work Object ID is stored in the pc_data_uniqeid table.
The standard property Work-.pyStatusWork defines whether the work object is
open or resolved. The value of this property is a primary indicator of the progress of
the object towards resolution. Values are restricted and controlled, and are changed
only through specific mechanisms.
Resolved work objects identify completed work and are ordinarily not modified by
any further processing, unless the work object is re-opened. The following are the
standard work object statuses available:
New not yet reviewed or qualified
Open responsibility for processing is with the processing organization
Pending responsibility for processing is currently with an external organization
Resolved-Duplicate resolved, as judged to be a duplicate of another work
object
Resolved-Rejected resolved, not accepted
Resolved-Complete resolved, work completed
38
The HTML property rule WorkStatus supports localization of the status value on
displays, through field value rules.
Clipboard Viewer:
39
The Work- base class, one of thirteen standard top level abstract classes, is a
superclass to all the classes that define work objects.
Properties, HTML forms, and flows in the Work- class are available to support the
behavior and appearance of all types of work objects, including
Ordinary work objects, typically belonging to the a class derived from the
standard abstract class Work-Object Covers, typically belonging to a concrete class derived from the Work-Coverclass
Folders, typically belonging to a concrete class derived from the Work-Folderclass
The external key to all Work- instances is recorded in the pyID property, and
typically consists of an alphabetic prefix, a dash, and an arbitrary but unique number.
Through directed inheritance, a subclass of the Work- base class may have a name
that does not begin with "Work." For example, the class PegaSampleCustomerRequest, part of the sample application, is a work type.
40
Questions:
Q1) In designing a class structure for an application, what should the first step be?
a. Identify primary users
b. Identify systems that the application will be interfacing with
c. Identify major units of completed work
d. Identify the key tasks that the application will perform
Q2) In a class
a. Both Pattern Inheritance and Directed Inheritance should be selected
b. Pattern Inheritance is mandatory
c. Directed Inheritance is mandatory
d. Neither Pattern or Directed are selected
Q3) In describing class inheritance in PegaRULES Process Commander, which of the
following statements is false?
a. Directed inheritance causes a class to inherit characteristics directly from the
specified parent class, regardless of any defined pattern inheritance.
b. Pattern inheritance causes a class to inherit characteristics from classes that it
resembles, moving up the pattern class hierarchy.
c. In pattern inheritance dashes are the delimiters for pattern matching.
d. The developer must specify pattern inheritance; directed inheritance is optional
and if specified, takes precedence.
Q4) Consider the following Data Tables and their classes
Class
Data Table
DataData-AdminData-Admin-XYZ
Acme-
pr_data
pr_data_admin
pr_XYZ
acme
Now a class Acme-Data-ABC is created which directly inherits from Data- and a data
table that belongs to this class is created. Five rows are added to this. In which of the
above data tables are these five rows included
a. pr_data
b. pr_data_admin
c. pr_XYZ
d. pr_other
e. acme
41
42
43
4. Data Modeling
44
Properties
A property rule provides a name and characteristics for data in an object. Because a
property definition is a rule, it shares the benefits of versioning, inheritance, and
access control that Process Commander provides to all rules. Properties are used
to
hold data in work objects, so it can be apart of your application Rule Set.
A property is an instance of the Rule-Obj-Property rule type. There are three types
of standard properties stating with the Index px, py, and pz.
Properties starting with px are computed properties that user can see on a form,
but cant directly enter the values or change.
Properties starting with py can be used by the user or developer to enter or change
via direct input
Properties starting with pz are reserved for internal process commander use. User
cant see, enter or change the values of these properties.
Property Types
Properties can be used in different types to determine the kind of data that values of
the property represent. There are 11 different types in the representation of a single
property.
Types: Text, Identifier, Password, Integer, Double, Decimal, Date, DateTime,
TimeofDay, TrueFalse, TextEncrypted.
Property modes are used to determine how the system represents the property data.
Every property has one of eleven property modes. This is a permanent feature of a
property that cannot be changed after you save a property rule. The simplest
45
property mode is Single Value. A Single Value property contains text that can
represent HTML, a date or time, an identifier, a number, or a Boolean true/false
value.
Properties with a mode other than Single Value are known as aggregate properties.
All eleven properties modes can be divided into four categories based on the
representation of the property data. The major categories are Value modes, Page
modes, Java Object mode, and Java Property modes.
Value mode identify properties that can have none, one, or multiple strings as
the
value:
Single Value: Select Single Value to create a property that can contain a Single
text string value. Text, numbers, dates, Boolean values and amounts are stored in
Single Value mode properties.
Value List: A Value List mode is an ordered, indexed list of strings, sometimes
called an array.
Value Group: A Value Group mode contains one or multiple strings, in
unordered manner and each identified by a unique text index value.
Page mode identifies properties for which the value has a single or multiple page
structure.
Page: Page is a data structure that contains name-value pairs.
Page List: A Page List mode property is a data structure consisting of an
ordered list of zero or more embedded pages, each identified by an integer index.
Page Group: A Page Group is a data structure consisting of an unordered set of
pages, each identified by a string index value.
46
47
Properties wizard are used to create one or more property rules with a common
Applies To class by completing a single form. This is used only when to create
several properties, using this wizard the all properties can be created faster than
completing the Property form for each property.
Data Table
Developers can use the Data Table editor to add, update, or delete instances of a
concrete class derived from the Data- class for which no form is defined, or other
classes for which an Excel template rule is defined. This facility allows easy entry
and maintenance of data instances for classes that have a simple structure.
Select Application > Data Tables to access a list of existing Data Tables in your
system. Click Add at the bottom of the form to create a new data table.
We Can use the wizard to create an edit form for any class that meets these
requirements:
Derived from the Data- base class
Contains only properties of mode Single Value
Does not require user input for properties inherited from any higher classes
Contains a Single Value property that defines a unique key
If you add a property (column) to a previously created data table, you must open and
update the list rule (Rule-Obj-List rule type) to have the new property available to
the Data Table editor. After generating the data table, edit the data table to enter the
required data.
48
Model
A model rule defines initial values for properties of a specific class. A model can be
applied to a new empty page of that class to set many property values in one
processing step. Model is an instance of Rule-Obj-Model.
Using a model, the value of multiple properties can be easily to zero, to the null
string, to True or False, to a computed value such as today's date or the current time,
a copied value such as your Operator ID, and so on. By convention, a model named
pyDefault is available for most standard classes.
Using a model the value of multiple properties can be easily set to required values,
rather than setting the property values one-by-one in an activity, this improves
runtime performance. Using a model also speeds development, because you can set
values for many properties quickly.
Flow rules that create work objects use a model rule for a Work- class to set
initial properties for the work object. In Definition Tab of Model specify a target
property or property reference to be initialized with the initial values.
Superclass Model causes the system at runtime to apply a model of the immediate
parent of this model's class with the same Model Name before it applies this model.
Linking together several models is called as model chaining. Process Commander
identifies the superclass to be called at the time you save the Model rule form, not at
runtime.
Important Points
1. Process Commander identifies the parent of the current class using the Parent
field in the class definition, not by following full class hierarchy searches
2. After identifying a parent class, the system uses rule resolution to find the model
of the same name as the current model.
3. The model in the highest class is applied first. The current model is applied last.
49
5. Process Flow
50
Process Flow
Process Commander associates a flow rule with a Microsoft Visio diagram, which
graphically represents a process. The diagram contains a network of shapes (tasks)
and connectors (arrows).
A flow rule defines a business process or part of a business process. A flow rule
governs how work objects are created, progress through the system, and become
resolved. A flow rule consists of a network of shapes and connectors (lines), each
with associated parameters and values.
A flow rule is an instance of the Rule-Obj-Flow rule type. Flow rules are normally stored in
the PegaRULES database as rows of the pr4_rule_flow table.
A work object is the primary unit of work completion in an application, and the
primary collection of data that a flow operates on. As an application is used, work
objects are created, updated, and eventually resolved. Every work object has a unique
ID, an urgency value, and a status.
A temporary work object is a work object that is created and resolved by a single
operator or through straight-through processing and never saved as a database object.
To create a temporary work object, select the Creates temporary object checkbox in
the flow that creates the object. Temporary work objects can be used in screen flows
and regular flows.
Some of the features like reporting, history, and attachments are not available for
temporary work objects. Also the below points are important in terms of temporary
work object:
Temporary work objects do not have a work object ID.
Temporary work objects cannot be members of a cover.
The Where-Am-I? Display is not available for temporary work objects.
History additions performed on such objects do not cause a flow to fail, but have
no effect.
Flow Editor Toolbar button (
FlowStart Identifies the start task of this flow. Every flow has one Start
shape.
51
Connector Associates a task in the flow with another that may follow the
first task. Connectors leaving assignment tasks may be flow actions.
Connectors leaving other tasks such as decision or utility shapes may be
when conditions.
Assignment Creates an assignment task associated with work object in a
workbasket or worklist. The task must be completed by a person or the
system before the flow can progress. It represents a pause or potential pause
in the flow.
Optionally, after the assignment task is defined, you can associate a service
level rule with it. A clock appears on the diagram, as shown here.
Utility Specifies an activity to run at that point in the flow to perform
automated processing without any user assignment.
Fork Supports automatic selection of one connector from two or more.
Decision Identifies an activity that can make an automated decision about
the progress of the work object through this flow.
Flow Identifies a subflow, which is a flow rule that is referenced in
another flow. For example, add a Flow shape to your flow rule to start
another flow and end processing of the current flow. The second flow is
called a subflow of the first flow.
Router Sends an assignment to a user, workbasket, or agent other than the
current user. Associate a Router task with an assignment task. This activity
determines which worklist or workbasket is to contain the assignment.
Notification Notifies a work party by e-mail or correspondence about the
status or progress of this work object as the assignment is created.
Comment Adds explanatory text comments anywhere on the flow
diagram. Comments do not affect execution of the flow.
Ticket Marks a business exception that might arise at any point in the
flow, such as a cancellation.
Integrator Identifies an activity that can connect to an external system
to send or receive data.
Assignment-Service Passes control to an external system (for example,
using a Connect BPEL rule). Flow execution pauses until Process
Commander receives a service request of the appropriate type.
Spin-off Starts a new flow execution and does not wait for its
completion.
Split-Join Sends the work object to two other flows, both of which must
complete before the current flow resumes.
Split-ForEach Performs an operation or test on each element in a
repeating group.
Pools and swim Lanes Identifies and groups tasks performed by
separate organizational units within one division.
52
A few standard flow rules, harness rules, flow actions, and section rules are known as
templates. These rules have special characteristics and settings. If the Template field
appears on the new dialog, you can select one to use as a base (similar to copying) for
this rule. This can save time and typing.
Classic: Creates a flow rule using V4/5.2 shapes. These differ only in appearance
from the standard shapes introduced in V5.3.
BPMN: Creates a flow rule using Business Process Modeling Notation and
terminology.
CrossFunction: Creates a flow rule consisting entirely of tasks performed by two
or more distinct organization units in one division. See Flow Form Editing in
Visio Swim Lanes.
PolicyOverride: Creates a flow rule to support policy override reviews. This flow
calls the standard flow named FinishPolicyOverride as a final task.
ScreenFlowBPMN: Creates a screen flow rule using Business Process Modeling
Notation and terminology.
ScreenFlowClassic: Creates a screen flow rule a sequence of assignments for
one or a set of users that involves no automated processing tasks. Special
restrictions apply; see Flow Form Editing in Visio Screen Flow Rules.
ScreenFlowStandard: Creates a screen flow rule using the Process Commander
shapes
ScreenFlowStandardTabbed: Creates a screen flow rule using the Process
Commander shapes & the tabbed work object forms
Standard: : Creates a Standard flow rule using the Process Commander shapes
A standard Business Process Modeling Notation (BPMN) will provide businesses
with the capability of understanding their internal business procedures in a graphical
notation and will give organizations the ability to communicate these procedures in a
standard manner.
Types of flows
A flow rule that contains no assignments, and so can execute from start to end
without human input, is known as a straight-through process. A flow rule that
contains assignments that apply only for unusual, rare situations also can be
considered straight.
A flow rule that consists only of assignments or decisions and meets other criteria is
known as a screen flow. After submitting a form, the user is presented with another
simple form (with more questions) that may depend on previous answers. At any
point, the user can backtrack to review, or change, previous answers. Process
Commander flow rules can support such interactions in Screen Flow mode.
A flow that creates a new work object is called a starter flow.
53
A flow that is called by another flow is known as a subflow, the calling flow is called
parent flow. Processing of a subflow is synchronous, meaning that the calling flow
execution pauses for the duration of the subflow. A subflow, also called a subprocess,
that is referenced in another flow rule, so that execution of the other rule may start
execution of the subflow.
54
the
Assignment
Service
task
55
56
Use connectors
(sometimes called arrows)
to connect a shape element in the flow with the
next shape element, to indicate a possible path
for the flow execution. Complete the Connector
Properties panel to identify the connector flow
actions available to a user who performs this
assignment.
In Flow Action select the Action Name
second key part of a flow action. There are two or more outgoing connectors from
a decision or fork shape, one of which is labeled Else. A utility shape can return a
literal constant result using the Task Status-Set method. Similarly, a subflow called
from this flow can return a literal constant result to indicate which FlowEnd shape
was reached.
The summary of actions for connectors when they are coming out of different shapes
is:
Connector
action
Always
Action
Status
When
Else
No
Yes
No
No
No
No
No
Yes
No
Yes
Yes
No
Yes
Yes
Yes
Yes
No
Yes
Yes
Yes
Spin-Off/
Called
flow
/Spilt-join
/Split for
each
Yes
No
No
Yes
Yes
Integrator
Yes
No
No
Yes
Yes
58
A call to another flow with return (one or more incoming connectors, one or more
outgoing connectors)
Part of a Split/Join or Split-forEach shape (at least one incoming and one
outgoing connector)
A flow rule that is branched to or called by another is sometimes informally called
a sub flow.
Define Flow on Identify the objects the flow rule is to update. Select:
On current work Item to continue processing on the current (unresolved) work
object in the next flow.
Choose on another Work Item to start processing on a different work object.
Choose on Embedded Page when this flow is part of a Split-forEach operation.
Use the Split-Join shape to require that multiple subflows of your flow be completed
before the current flow continues execution. This allows subflows to execute
asynchronously, in parallel. For an example, see the standard flow Work.ParallelWork. (
59
When a work object advancing through a flow reaches the Spin-off shape (
),
Process Commander starts execution of a different flow, using the current or a
different work object. Processing in the current flow rule continues in parallel,
without waiting for the other flow to complete.
A flow rule that is reached and started by another is sometimes informally called a
subflow; the original is called the parent flow. However, no field on the rule form
marks a flow rule as a subflow; the term describes how a flow rule is referenced
rather than its characteristics. Some Business Process Management materials use the
term subprocess for a branch flow.
Use pools and swim lanes to define and separate processing performed by distinct
organization units within one division or that depend on the value of a work object
property. This shape defines a series of vertical lane borders, as in an Olympic
swimming pool. Each lane corresponds to an organization unit or specific property
value. To create a flow for which every shape belongs to a lane, choose
CrossFunction as the Template value in the new dialog box.
Flow in Draft mode is a setting that allows you to create and model flows with
shapes that contain rules and flow actions that are not yet defined or complete. For
ease in developing applications, this mode allows you to define and save flows that
reference rules and flow actions that do not exist.
workspace home page. It lists open,
A worklist is an element of the
outstanding (not complete) assignments waiting for a user to perform them. Thus, a
worklist display shows selected instances of the Assign-Worklist class. Usually,
assignments appear on a worklist because an Assignment task in a flow created the
assignment. Assignments appear in order of assignment urgency the most urgent
assignments appear first, those with the highest pxAssignUrgency value.
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.
As work objects progress through a flow execution, the system creates an
assignment. Assignments may be associated either with human users or with a
workbasket.
Assignments leave a workbasket in three ways:
Users who are qualified can remove an assignment from the workbasket to
process the assignment.
An application can automatically route assignments in a workbasket to users
based on work schedules, due dates, skills, workloads, and other factors.
Managers can transfer assignments from a workbasket to user worklists.
Click the Where-am-I? Icon ( ) on a worklist or the Where-am-I? Button ( ) on a
work object form to view, in a separate window, the Visio diagram of the current
60
flow rule, with a larger arrow marking the current assignment. If the current flow
execution is a subflow that was called by another flow rule, you can navigate within
the display to see the call location within the parent flow.
Correspondence is the Process Commander term for outgoing e-mail messages,
printed letters, or facsimile transmissions produced by the system and its users. These
are typically associated with one work object (or a cover or folder) and may consist of
text, images, or both. Create correspondence rules to define, in HTML, templates for
the content of outgoing correspondence. Each correspondence rule contains standard
text for one type of correspondence such as e-mail, letter, or fax. JSP tags or
directives allow correspondence to incorporate property values and calculations.
Correspondence rules are part of the Process category. This is an instance of RuleObj-Corr.
Correspondence rules that use JavaServer Pages tags can incorporate paragraph rules
(Rule-HTML-Paragraph rule type), which provide rich-text editing on the rule form.
Rules of three other rule types can reference correspondence rules:
Flow rules, using Notify tasks
Flow action rules, indirectly through activities identified on the Action tab
Activities
The Pega-ProCom agent periodically sends queued messages. Most correspondence
is sent using e-mail. Outgoing e-mail is supported by an appropriately configured
Data-EmailAccount data instance. If the correspondence is to be printed or faxed, the
HTML file (as a ZIP archive, with image files if any) is sent to a server running
Windows and the Correspondence Output Server.
A correspondence type rule is an instance of the Rule-CorrType class. These rules
determine how the system finds an address for outgoing correspondence. The class
you identify must use the properties pyOwnerKey and pxCreateDateTime as key
parts. You can use any of three standard classes or another class you created:
Data-Corr-Email
Data-Corr-Letter
Data-Corr-PhoneText
Create a correspondence fragment rule to define reusable or boilerplate HTML text
for correspondence, such as a standard heading, footer, or signature. Correspondence
fragment rules are instances of the Rule-Corr-Fragment class. They are part of the
Process category. Using the <pega:include > JSP tag, your application can
incorporate the text in a correspondence fragment rule in multiple correspondence
rules during stream processing.
61
Service level rules define three time intervals, known as goal, deadline, and late
intervals. The goal time is the smallest time interval, the deadline time is a longer
interval, and the late interval defines post-deadline times. Service level rules can be
associated with a work object or an assignment. Service level rules are referenced in
the assignment tasks of flow rules. The Pega-Procom agent a background requestor
detects goals and deadlines not met and performs escalation processing.
A service level rule includes
Goal if an assignment remains open when the goal time is reached, the system
adds this value to urgency value of the assignment.
Deadline if an assignment remains open when the deadline time is reached,
the system adds this value to urgency value of the assignment.
Repeating Interval If an assignment remains open when any repeating
interval ends, the system adds this value to urgency value of the assignment, once
for each repeating interval.
The Standard service level rules are:
Advanceflow: Push the assignment along a flow action automatically.
Default: Imposes a goal of two days and a deadline of five days.
NotifyAssignee: Sends an e-mail reminder to assignee upon reaching goal time or
deadline time.
NotifyManager: Sends e-mail to the assignee's manager upon reaching the
deadline time.
TransferToManager: Transfer assignment to manager upon reaching the
deadline.
62
63
A flow action rule controls how users interact with work object forms to complete
assignments. After selecting one flow action, users may fill in a section of the form to
complete (perform) the assignment. Flow action rules are part of the User Interface
category. A flow action rule is an instance of the Rule-Obj-FlowAction rule type.
There are two types of Flow actions
Connector flow actions appear as lines on Visio presentation in the Diagram tab
of a flow rule. At runtime, users choose a connector flow action, complete the
assignment, and advances the work object along the connector to the next task.
Flow actions of the other type, known as connector flow actions, appear above the
horizontal line. Unlike connector flow actions, local flow actions are not visible
on the Visio diagram of the flow rule. They are recorded in Assignment Properties
panel.
A local flow action, when selected at runtime, causes the assignment to remain
open and on the current user's worklist. Local flow actions are recorded in the
Assignment Properties panel. Local flow actions always are optional. Users may
perform none, one, or multiple local flow actions. A developer can mark a flow
action rule as local on the Flow Action form. On standard work object forms,
local flow actions appear below a horizontal line in the Take Action selection box.
Process Commander generates HTML code, including JSP tags and directives, for
this flow action. In unusual cases, you can author the HTML code directly. In most
cases, the system generates the source HTML automatically.
64
Use activities in Flow action to do certain preprocessing and post processing when
users select this flow action. Associate activities with the flow action, and to control
operation of the Perform harness form.
Run an activity before this flow action is used to perform some pre processing before
this flow action is getting executed from an assignment. After flow action enter the
name of an activity to run after other successful processing of this flow action.
Questions:
1. The Smart Shape used for showing a harness to the customer:
a. Assignment
b. Connector
c. Integrator
d. Flow Action
2. Flow without human interaction is
a. Screen Flow
b. Straight through processing
c. Sub Flow
d. Starter Flow
3. Which harness screen will succeed New Harness?
a) Perform harness.
65
b) Confirm harness.
c) Review harness.
d) Reopen harness.
4. Identify standard local actions
a) AttachANote
b) AttacAURL
c) AttachAFile
d) AttachADocument
5. The Smart Shape is used to skip certain steps of a flow without affecting the flow
is:__________
6. Rules like Notify,Utility,Route belongs
a) Rule-HTML-Property
b) Rule-Obj-Activity
c) Rule-Obj-Flow
d) Rule-Declare-OnChange
7. List at least 3 PRPC predefined data classes that serve the purpose of work parties
8. Where can we specify new work object harness?
a) NewDefaults
b) Model.
c) FlowRule.
d) Harness.
9. What are the possible fields we can give in an assignment properties
a) Flow name
b) Assign Activity
c) Routing Activity
d) SLA
e) Local Action
10. When a Flow is in Draft mode.(Choose 2)
a) You cannot add smart shapes
b) You cannot run the Flow
c) It is not visible to Rule resolution
d) You cannot create Work Objects
11. Agent activity of assignment flow rule is used to ------------ purpose.
a) Sends the assignment to background process rather than to a person.
b) starts the directed web accesses feature
c) Causes the assignment to be placed in a work basket, determined by an
associated router shape.
d) Causes the assignment to be placed on the worklist of the current operator.
12. Which shape is used to start a different flow parallel to the current flow?
a) Split-join
b) Fork
c) Spin-off
d) Swim lane
66
6. Case Management
67
Case Management
A work object is the primary unit of work completion in an application, and the
primary collection of data that a flow operates on. As an application is used, work
objects are created, updated, and eventually closed (resolved).
Every work object has a unique ID (property pyID), an urgency value, status
(property pyStatusWork), and that contains the default prefix W-.
Work object ID will create automatically as a work object is created. The standard
utility activity named Work-.GenerateID uses the standard properties
pyWorkIDPrefix and pyWorkIDSuffix in its computation. The work object ID is
required to contain either a prefix or suffix. For example, the prefix of work object Q1432 is Q. The prefix of the work object MORT-763-K4 is MORT. The suffix of
work object MORT-763-K4 is K4.
The Work- base class, one of thirteen standard top level abstract classes, is a super
class to all the classes that define work objects. A work object is the fundamental unit
that records processed work in an application.
Ordinary work objects, typically belonging to the class derived from the standard
68
themselves may be basic work objects other folders and cover objects. Folder Objects
will have the prefix ID as F-.
The main purpose of folders is to maintain the Parent child relationship between the
Folders, Covers and Covered work objects. For example if we have five work objects
that are dependent on each other then we use the concept of covers and if those work
objects are independent then we use the concept of folders. The folders can contain
the folders, Cover objects and covered objects and those all work objects can be
created processed and resolved in the cover itself.
In Process Commander Work objects capture and process evolving information
about individual units of work.
Covers are intended to coordinate processing on multiple distinct but closely related
work objects.
Folders provide a structure for more loosely associating multiple related work
objects.
The main differences are:
Covers can be resolved automatically when all their constituent ("member") work
objects are resolved.
A standard harness rule is available that displays a cover and lists its member
work objects.
Folders offer a vehicle for keeping track of one or more commonalities among
otherwise disparate work objects.
One work object may be associated with multiple folders, but only with one
cover.
Members of a folder can belong to different work types, which need not belong
all in a single work pool.
The relationships between folder work objects and their contents may be many-tomany.
Relation ship between Work object, covers and Folders:
69
Work objects from the cover itself. The work objects that are related to the cover are
known as covered work objects.
These Covered work objects are created, processed and resolved with in the cover
itself. From the cover we can go to any work object that is covered work object
associated with the cover object and we can create process and resolve it. In case of
the covers, when all the work objects associated with the cover object get resolved
that is the when all the covered objects are resolved then the Cover objects will be
resolved automatically.
Steps for creating a Folder Object:
Create a class group and it is derived from work-.
Create a work type in the class group and the work type belongs to the class group
and name that work type as Folder that inherits from Work-Folder-.
Create a flow for generating folder objects named as Folder.
While creating the folder object there is an option called view folder contents and
by this we can view the folder contents, create the work objects and also we can
add the work objects, covers and folders to the current folder.
Now we can resolve the current folder based on the flow designed.
Steps for Creating Cover objects:
70
To view object locks held by your own requestor session, select View > System >
Locks > My Locks.
Questions:
1. Which will be used to Generated work Object ID in New Release?
a.
Work- ObjectID
b.
Work- GenerateID
c.
Work Object
d.
Work New
2. Folders can contain:
a. Only work objects
b. Work objects or covers
c. Work objects, covers, or other folders
71
3. What are the properties used to set the prefix and suffix for a work object?
a. pyWorkIDPrefix and pyWorkIDSuffix respectively
b. pyPrefix only
c. pyWorkIDSuffix only
d. none of the above
4. Covered work object will be stored in which page?
a. pyWorkPage
b. pyWorkCover
c. Step Page
d. pyWork
5. Covers have some automatic behavior
a. Whenever all of the covered work objects are Resolved-Complete, the Cover
is automatically Resolved
b. Whenever all of the covered work objects are Resolved, the Cover is
automatically Resolved
c. Whenever all of the covered work objects are Resolved, the
AllCoveredResolved Ticket is raised
6. Cover work object is currently on the UI screen. Where can you view the details about
cover?
a. pyWorkCover
b. pyCoveredWork
c. pyWorkPage
d. pyCurrentPage
7. A covered work object is currently opened on the screen. Where can you see the cover
details?
a. pyWorkCover
b. pyCoveredWork
c. pyWorkPage
d. pyCoverPage
72
7. Activities
73
ACTIVITIES
An activity is similar to an instance method. A property is similar to an instance
variable in Java or C++. An activity is an instance of the Rule-Obj-Activity rule type.
An activity when defined consists of a sequence of steps, each of which can contain a
method or an instruction. As an activity form is saved, the system converts
information in the form into server-side Java source code. At runtime, this Java code
is compiled and executed to perform processing, analysis, and decision making.
An activity consists of one or more steps. Each step can call a Process Commander
method, can transfer control to another activity, or execute custom inline Java. The
Run icon executes an activity. The activity must be saved and valid for the Run icon
to be visible. The following are the Fields of the Activity Rule Form
Label (optional) Enter a one- or two-character step label name which will be
used for reference.
Description (optional) Description about the functionality of the step
Step page (optional) The name of the clipboard page that this step operates on.
Method (required) The name of one of 86 predefined methods to call to work
on the step page.
Use a precondition to conditionally skip execution of a step. The system evaluates
whether specified conditions are met before it executes the method or instruction
referenced in the step. If false, the rest of the step is skipped. Different options
available for a Pre condition are,
Continue Whens- Next When Condition is validated
Skip Step- Current Step is skipped and control goes to next step
Skip Whens- The Control goes to the method or instruction referenced in that
step
Exit Activity- Control exits the current activity and goes to the calling activity
Exit Iteration- For the current iteration the step is skipped and the control goes to
next iteration
Jump to Later Step: The Control goes to the step referenced.
74
The Transition step defines any post condition that needs to be validated and based
on the validation, transition of some sort can be done. The significant functionality of
transition step is that it is used for error handling in activities. When ever there is an
exception, the transition step can be used to make the control shift to a later step
which handles the exception. The transition step also has the same options as pre
conditions for the transition to take place.
Iterations are used to repeat a step a number of times or until a condition is met. This
provides a limited form of enumeration or looping. The different options available for
looping are as follows
For each page-option to sequence through all pages of a specified class
75
76
scope and it cannot be used out side the declared activity. The Local Variable can also
be any one of the mentioned data type.
Step Pages are the pages that are defined for the activity to work on it. In Pages &
Classes tab, we define the step pages that are to be used in the activity. When it is
defined, the step method works on the appropriate step page and has the same
visibility characteristics as its class.
A step page specified for a Page-New method indicates the name (and class) of
the page to be created.
A step page specified for a Property-Set method indicates to set the properties of
the page defined
A step page specified for a Show-Page method indicates the XML for the
specified named page
77
local Not a page, a keyword indicating that the name that follows the word
"local" and the period is a local variable, not a property.
Locate A prefix to a page name (in lowercase), indicates that this page is
retrieved or located at runtime through an activity of type Locate.
Mode identifies an indirect page reference.
Param identifies the parameter page for an activity. This page structure is not
part of the clipboard.
Parent in the context of an embedded page, identifies the immediately
containing page to which the embedded page belongs. This keyword may appear
more than once in a property reference. This keyword is used in Declare Index,
decision table, decision tree, and map value rules.
Prompt as a prefix portion of a page name, not a keyword identifies an
indirect page reference in a Call or Branch. The called activity identifies an
indirect page by selecting prompt as the Mode field in the Pages & Classes tab,
and refers to these pages using the syntax "Prompt.pagename".
Top identifies the top-level page to which the current embedded page belongs.
The concept of primary page is a relative term. When an activity is called, two things
are specified: the name of the activity being called and the page it is called to work
on. In the clipboard, the called activity exists within the page on which it is called;
this is referred to as the activitys PRIMARY page. The PRIMARY page of an
activity is determined by the activity that called it, not by the activity itself.
A Process Commander method is a primitive, atomic operation that can be performed
by one step of an activity (Rule-Obj-Activity rule type) or a Parse Structured rule
(Rule-Parse-Structured rule type). Internally, a method is an instance of the RuleMethod rule type. These methods cant be altered or new methods can be added. The
below table consists of all the methods that can be used in an activity.
S.No
1
2
3
4
5
6
7
8
9
10
11
12
Page-Change-Class
Page-Clear-Messages
Page-Copy
Page-Merge-Into
Page-New
Page-Remove
Page-Rename
Page-Set-Messages
Page-Unlock
Page-Validate
Methods for persistent
instances
Commit
Obj-Browse
13
Obj-Delete
Description
Change the class of a page.
Remove page messages from the step page.
Copy contents of one page to another page
Merge two or more pages into one page.
Create a page.
Delete a page from the clipboard.
Rename a page or name a primary page
Associate a message with a page.
Release a lock held after Commit.
Validates all properties on a page.
78
14
Obj-Delete-By-Handle
15
Obj-Filter
16
Obj-List
17
Obj-List-View
18
Obj-Open
19
20
21
Obj-Open-by-Handle
Obj-Refresh-and-Lock
Obj-Save
22
Obj-Save-Cancel
23
24
Obj-Sort
Obj-Validate
25
26
27
28
29
30
Rollback
Control methods and
instructions
Activity-Clear-Status
Activity-Set-Status
Activity-End
Activity-List-Add
Branching to another activity
31
32
Collect
33
34
35
36
37
Exit-Activity
Requestor-Stop
Thread-Clear
Wait
Methods for HTML and XML
streams
Show-HTML
38
Show-Page
39
40
Show-Property
Show-Stream
Property methods
79
41
Apply-Model
42
43
44
45
46
Obj-Sort
Property-Remove
Property-Seek-Value
Property-Set
Property-Set-Corr
47
Property-Set-HTML
48
Property-Set-Messages
49
Property-Set-Stream
50
Property-Set-XML
51
52
53
54
Property-Validate
Flow-related methods
Flow-End
Flow-New
Obj-Set-Tickets
55
TaskStatus-Set
58
History methods
History-Add
History-List
Methods for connectors
Connect-dotNet
59
Connect-EJB
60
Connect-File
61
62
Connect-HTTP
Connect-Java
63
Connect-JCA
64
Connect-JMS
65
Connect-MSMQ
66
67
68
Connect-MQ
Connect-SOAP
Connect-Wait
69
70
71
RDB-Delete
RDB-List
RDB-Open
56
57
80
72
RDB-Save
73
74
75
76
Structured parsing
Apply-Parse-Delimited
Apply-Parse-Structured
Apply-Parse-XML
Map-Structured
77
Parse-Byte-Pos
78
Parse-Char-Pos
79
80
81
82
Parse-Fixed-Binary
Parse-Packed-Decimal
Text-Infer
Text-Normalize
database.
Save the contents of a clipboard page to a relational
database.
Execute a Parse Delimited rule in an activity.
Execute a Parse Structured rule in an activity.
Execute a XML parse rule in an activity.
Use the Map-Structured method to invoke a map
structured rule
Used only in Parse Structured rules for parsing by
byte positions.
Used only in Parse Structured rules for parsing by
char positions
Used only in Parse Structured rules.
Used only in Parse Structured rules.
Evaluate a parse infer rule.
Evaluate a parse normalize rule.
83
Local variables
StringBuffer-Append
84
StringBuffer-Insert
85
StringBuffer-Reset
86
87
Other
Assert-No-Invocation
Connect-FTP
88
Link-Objects
89
Log-Message
90
Privilege-Check
91
Property-Map-DecisionTable
92
Property-Map-DecisionTree
93
Property-Map-Value
81
94
Property-Map-ValuePair
95
Queue-for-Agent
96
Queue instruction
Advanced
97
Java
98
Start-Validate
99
End-Validate
STANDARD METHODS
Use the Obj-Open method to open an instance stored in the PegaRULES database or
in an external database linked to an external class, and save it as a clipboard page. The
system uses the specified class and key fields to find and open the object and place its
data into the specified step page.
Parameter
Description
OpenClass
Lock
ReleaseonCommit
LockInfoPage
PropertyName
PropertyValue
Use Obj-Save method to request that the system save a clipboard page to the
PegaRULES database
82
Parameter
Description
WriteNow
WithErrors
Use the Obj-Browse method to search instances of one class and copy the entire
instances, or specified properties, to the clipboard as an array of embedded pages.
Only properties exposed as columns can be used as selection criteria. However,
values of properties that are not exposed as columns, including embedded properties,
can be returned. Use the Obj-Browse method optionally followed by the Obj-Filter
method to create a list of search results. The Obj-Browse method has five base
parameters and an optional array of selection criteria.
Parameter
Description
PageName
ObjClass
MaxRecords
ReadOnly
Logic
Label
Select
Field
Condition
Value
Sort
Use Obj-Sort method to sort the clipboard pages that are the values of a property of
mode Page List. You can specify one or more properties to sort on, and whether the
sort sequence is ascending or descending for each sort level.
83
Parameter
Description
PageListProperty
Class
SortProperty
Descending
Description
Remove
If selected, the system deletes the page identified in the Step Page
column of this step from your clipboard and marks the
corresponding persistent instance for deletion.
Immediate
Use the Obj-Filter method to filter the embedded pages of a results page (such as a
Code-Pega-List page produced by the Obj-List, RDB-List, Obj-List-View or ObjBrowse methods) based on one or more when condition rules. For example, if each
embedded page on results page contains a Page List property Child and each Child
page contains a Single Value property FirstName, you can use the Obj-Filter method
to remove all embedded pages where no value of FirstName is "Robert".
Parameter
Description
List Page
84
ResultClass
When
Use the Obj-List method to retrieve data to the clipboard as an array of embedded
pages. The Obj-List method searches sequentially through instances of the
PegaRULES database or an external database and retrieves specified data to pages in
the clipboard.
Parameter
Description
PageName*
ObjClass*
RuleObjList
MaxRecords
SelectionProperty
SelectFrom
SelectTo
Like
Lightweight Results
85
Use Property-Set method to set the value of one or more specified properties. The
Property-Set method uses an array of parameters. Each row of the array contains a
property name or reference (the destination), and a value (the source). Order is
significant.
Parameter
Description
PropertiesName
PropertiesValue
HTMLStream
Use Property-Set-XML method to save the contents of an XML rule after stream
processing completes as the value of a Single Value property. The property value can
then be mapped as output and conveyed to an external system.
Parameter
Description
PropertyName
86
XMLType
Message
Field
Use the Page-New method to create a page on the clipboard. The new page may be a
top-level page or an embedded page.
Parameter
Description
Model
Optional. Enter a model (an instance of the Rule-ObjModel rule type) to apply to the new page.
PageList
NewClass
Use Page-Copy method to copy the contents of a source clipboard page to a new or
previously created destination clipboard page. The source page is not altered.
Parameters
Description
CopyFrom
Model
PageList
Use the Page-Clear-Messages method to remove all property messages and all page
messages from the page identified in the Step Page column of the current step.
Use Page-Remove method to delete one or more pages from the clipboard. The
contents of the database are not affected.
Parameter Description
Page
88
Unit testing
Optional. Using the Clipboard tool or other means, set up clipboard pages,
property values, and other initial conditions.
Next, start the Tracer tool to monitor activity execution. Set Tracer options.
Click the Run toolbar button ( ) or the equivalent keyboard shortcut CTRL + R.
A pop-up form appears.
If the text requires a test page, select the Create a Test Page radio button. Click
Run Rule.
Complete the Test Page area. If the activity uses parameters, the system presents
an input form for parameters. Enter constants for input parameters as prompted.
(Some input parameters may be optional.)
Click Execute to start the activity in your requestor session.
As the activity runs, it may update the clipboard, open and alter instances, display
HTML forms, and so on. It uses the current RuleSet list and access roles.
If the execution causes errors, an error form appears.
Use the Clipboard tool and the Tracer tool to uncover errors and view processing
details.
Clipboard contents
Testing with the Run button can create one or more clipboard pages, including copies
of named pages identified on this form. The system retains these pages when the form
is closed; properties on these pages remain available for later tests of this or another
rule tested with the Run button.
Questions
1. What is the class of the top level clipboard page created by the Obj-List method?
(a) Code-Pega-List
(b) Rule-Pega-Obj
(c) pxResults
(d) The same class as the returned instance
2. Which of the following is true about step pages? (Choose 2)
f) Steppages define the default pagecontext during the step execution.
g) Step pages are removed when the activity ended
h) Steppage class is always equal to AppliesTo Key.
i) StepPage is not required on each step of an activity.
3. Which of the following method is used for viewing any step pages info in XML
format (especially for the purpose of debugging?)
a. Show-XML
b. Show-Html
89
c. Show-Page
d. Show-Step-Page
e. Show-Property
4. The following method is used to make Obj-Save method not be effective and hence not
to be taken up by subsequent Commit method
a. Obj- Save-Cancel
b. Obj-Save-Rollback
c. Obj-Save-Drop
d. Obj-All-Rollback
5. ----------- Check box in Obj-Save method and ---------- Check box in Obj-Delete
method facilitate immediate write into database, without actually waiting for Commit
method
a. Immediate, Write-Now
b. Write-Now, Immediate
c. Save-Now, Immediate
d. Immediate, Save-Now
6. Both Assign and Utility activities can not use which of the following methods
a. Show-Html
b. Obj-Save
c. Obj-Open
d. Commit
7. Explain in single line difference between Activity-End and Exit-Activity methods
The Exit-Activity method ends the current activity and returns control to the
calling activity.
If one activity calls another activity that contains the Activity-End method, both
activities end, and the system does not return to the calling activity.
8. To create a work object from an activity:
a. Create a step page of the class of the work object
b. Call the Add activity
c. Enter the name of a starting harness
d. All of the above
e. None of the above; activities cannot create work objects
9. Obj-Open methods open an instance of a class into a step page. Which of the
following statements is true?
a. Before Obj-Open, the step page has to be created using Page-New
b. The step page can be classless if it is temporary
c. An instance of a step page with the same name can be reused and the data must be
cleared using Page-Reset
d. An instance of a step page with the same name can be reused and the data is
cleared automatically
90
91
8. User Interface
92
Introduction
Process Commander includes portals and work object forms that allow application
users to enter, update, and resolve work objects.
Work object forms are HTML based, so can create and change them in place as
needed, without any compiling code. First define layout and Process Commander
generates the basic HTML to display the form.
The User Interface category contains six rule types that control the presentation of
work object forms and other aspects of the user experience:
1. Harness
2. Section
3. Flow Action
4. Paragraph
5. Portal
6. Skin
Harness rule defines an HTML form that supports application users as they enter,
review, update, and resolve work objects. Harness rules are instances of the RuleHTML-Harness class. Harnesses are also called work object forms.
Use harness rules to define the appearance and processing of work object forms used
in application to create work objects and process assignments. Together with section
rules, HTML rules, property rules, and others, harness rules define the structure,
appearance, and behavior of the forms used in applications to create and update work
objects and assignments.
Section is a portion or area of a standard work object form that is incorporated on a
harness form. Sections may contain other sections, informally called subsections.
The appearance, behavior, and contents of a section are defined by a section rule
(Rule-HTML-Section rule type). Section rules are instances of the Rule-HTMLSection class.
Section rules are referenced in:
Harness rules
Other section rules
Flow action rules
Paragraph rules with SmartInfo pop-ups
A flow action rule is an instance of the Rule-Obj-FlowAction class. A flow action is
a choice available to users as an interim or final disposition of an assignment they are
processing.
93
A flow action rule controls how users interact with work object forms to complete
assignments. After selecting one flow action, users may fill in a section of the form to
complete (perform) the assignment.
There are two types of flow actions:
1. Connector flow actions appear as lines on Visio presentation in the Diagram tab
of a flow rule. A line exits from an assignment shape and ends at the next task in
the flow. At runtime, users choose a connector flow action, complete the
assignment, and causes the work object to progress along the connector to the
next task. A connector flow action is an instance of the Rule-Obj-FlowAction rule
type.
2. A local flow action, when selected at runtime, causes the assignment to remain
open and on the current user's worklist. Local flow actions are recorded in the
Assignment Properties panel and are not visible on the Visio flow diagram.
A Paragraph flow action rule is an instance of the Rule-HTML-Paragraph class.
Paragraph rule to provide read-only text for a cell in a work object form that can
include bold, italics, colored text, images, and other rich text.
A portal rule is an instance of the Rule-Portal class. The Process Commander portals
support two user communities:
1. The Developer portal provides an integrated work, test, and development
environment to support application developers. Customization of the Developer
portal is typically not necessary and ordinarily limited to menus and skins.
2. User portals support managers and users of applications workers, as they enter,
update, and resolve work objects. User portals may be customized to reflect the
terminology, layout, facilities, and styles appropriate to each user community.
Developer portal provides quick access to dozens of tools, wizards, reports, and other
capabilities.
The appearance and function of your Process Commander portal depends on
information in your access group, which references a portal rule (Rule-Portal rule
type).
A skin rule is an instance of the Rule-PortalSkin rule type. A skin rule defines four
Cascading Style Sheet (CSS) files, stored as text file rules, that together determine the
colors, fonts, images, and layout of portal, work object, rule forms, and report
displays.
Use the Style Viewer tool to identify and preview the appearance of styles in a CSS
file. Skin rules are referenced in portal rules.
94
95
Defined in class
Work-
Cover
Work-Cover-
Folder
Work-Folder-
Harness Rules
New
NewCovered
Perform
Confirm
Review
Reopen
Perform
Review
Perform
Review
ReviewForExplore
Purpose
Creating new objects
Allows a user to create both a cover work object (for
example, in the Work-Cover-General class) and in
the same form create one or more covered work
objects
96
Perform
Confirm
Review
Reopen
Description
Add an accordion to the harness
Add a container to the harness form.
Add a layout to the harness
Add a panel set to this harness, to support a composite portal.
Add a section rule into this harness
Add a tab to a harness.
Basic Controls
Controls
Description
Place a button into a cell or to the bottom of the form.
Add a text box containing a Date or DateTime value.
Add a check box representing a property value.
Add an icon to the form, in a cell or on a header.
Include an image in the form.
Add an Input Box
Add a static read-only text label into a cell
Add a radio button group representing a property value.
Add a Select control that presents a fixed list of values
Add a TextArea, which can contain more than one line of text.
Place blue, underscored text in a cell. When clicked at runtime, the link
starts an activity
Advanced
Controls
Description
Use an autocomplete text box to present a drop-down list of dynamic
choices computed by an activity.
Add a red label that opens a pop-up SmartInfo section when the user hovers
the mouse pointer over the label.
Adding a Work Area to a composite portal
Add a dynamic drop-down list
For harnesses that are part of a composite application built with Internet
Application Composer only. Add a hidden field to expose a property value,
97
The Rules Inspector tool provides a quick and interactive way for you to identify and
inspect a forms underlying harness, section, flow action, styles and property rules as
well as the associated HTML and property dependency networks.
Use the Rules Inspector tool to:
Learn the name of the top-level harness rule or HTML rule (Rule-Obj-HTML rule
type) that produced any window or form you are viewing.
Learn the names of section rules, flow action rules, paragraph rules and HTML
rules that the top-level rule incorporates through the pega:include JSP tag, the
HTML-based rules referenced by these and so on.
Learn the name of properties referenced in any of these rules.
Identify properties displayed that are computed automatically by Declare
Expression rules.
Find labels and other elements on harness, section, and flow action rules marked
for localization, for which field value rules are defined.
Start the Style Discovery tool, to identify and experiment with changes to the CSS
styles that are applied to a part of a form.
To turn on rules inspection
Four menu settings set or remove rules inspection. When these menu items are
set, a check mark appears before the menu item. Select:
Run > Rules Inspector > HTML Rules to turn on marking of harness, section,
and flow action rules with an
icon. The icon appears above the visible
presentation of the HTML in the rule. This menu selection also marks HTML
rules with an icon. The keyboard shortcut is CTRL+ALT+Y.
Run > Rules Inspector > Property Rules to turn on the marking of visible
properties. A small red
identifies each property reference. The keyboard
shortcut is CTRL+ALT+X.
98
Run > Rules Inspector > Declarative Rules to turn on the marking of
properties computed by Declare Expression rules. A small red
identifies
such properties. The keyboard shortcut is CTRL+ALT+V.
Run > Rules Inspector > Field Value Rules to turn on the marking of portal,
harness, section, and flow action elements that are marked for localization and
supported by field value rules (Rule-Obj-FieldValue rule types). This option is
most useful when testing a localized application. See Localizing with the Field
Values Inspector. The keyboard shortcut is CTRL+ALT+w.
Run > Rules Inspector > Styles to turn on the Style Inspector, allowing you to
determine which CSS styles apply to elements of a form, and experiment with
style changes
Rules Inspector settings affect all forms presented after you turn on the settings. The
enhanced display contains up to four types of icons
Understanding the H, P, D, and A icons
identifies the harness rule. Additional
icons
A top-left yellow icon
identify the start of the visible presentation of a section rule or flow action rule.
A small identifies the visible presentation of an HTML rule or HTML fragment
rule.
A small red identifies a property reference.
identifies a property computed by a Declare Expression rule.
A small red
Any of the following four globe icons may appear at points on a harness, section, or
flow action rule for which the Localized check box (on the HTML tab) is selected and
a language-specific RuleSet is in use:
99
Select and slowly drag the grab area to move the Style Inspector toolbar to
another location within the portal. Drop the toolbar in a location away from the work
object form elements of interest.
Style Explorer
Click to open a pop-up window that starts the Style Explorer. The window lists all
style sheets currently in force for your session, in cascading order; the last CSS to be
applied appears at the bottom of the list.
Search tool
Click to open a pop-up window that support searching for styles using text matching.
You can search through the selectors (style "names") or through the style definitions.
Enter a text string in the Search Styles input box; then check the By Selector box or
the By Definition box (or both). Click Search.
pop-up toggle
Click to disable SmartInfo display of CSS styles and properties. Click again to enable
the display.
Understand the benefit of automatically generating HTML and the
consequences of overriding this feature/ Section rules/ FlowAction not autogenerated: advantages and risks
Auto Generated
The preferred approach for section rules (Rule-HTML-Section rule type) and
flow actions (Rule-Obj-FlowAction) is to use auto-generated HTML and
create the display interactively using the Layout tab (or Format tab).
100
When the Auto-Generate HTML? check box on the HTML tab is selected,
Process Commander generates HTML code each time you save a Section
form or Flow Action form.
This approach generates correct HTML code, conforms to the guardrails and
poses the least risk.
Non Auto-Generated
For special situations involving customized displays, it may be necessary to
clear this check box and enter custom HTML code. This should be used
sparingly and with great care.
The best practice is to create as much of the HTML infrastructure with autogenerated sections and flow actions and use hand-crafted HTML code in small
custom spots. When a non-auto generated section is needed, follow the
guidelines below to allow the browser to correctly render the HTML and to
allow the Harness, Section, and Flow Action forms to correctly incorporate
these hand-crafted section
Complete HTML Element Structure
When creating small HTML snippets, do not code incomplete HTML structures. This
makes it hard for the browser to correctly render these in different contexts and may
cause the rule form to show script errors and/or cause an unrecoverable error.
Illegal HTML Tags
The following HTML tags should not appear in a hand-crafted section rule.
Remember that a section is part of a larger form, not a complete HTML document
itself.
1. <HTML>
The <HTML >tag cannot appear within the scope of another <HTML> tag. The
<HTML> tag is part of the harness rule.
2. <body>
Similarly, an HTML document can have only one <body> tag. The <body> tag is
part of the harness rule
3. <Head>
All sections reside inside the <body> tag of a harness rule.
4. <Link>
According to the definition, <link> tags can only be inside of a <head>. Because
the <head> tag is part of the harness, you cannot include your own <link> tag.
A flow action rule controls how users interact with work object forms to complete
assignments. After selecting one flow action, users may fill in a section of the form to
complete (perform) the assignment.
101
AddtoFolder
AttachAFile
ApproveSample
AttachANote
AttachAScreenShot
Purpose
Add a file attachment and assign it to an attachment category.
Adds a covered work object to the current (covering) object.
Override this standard flow action to specify the work type of the
covered work object.
Start a new flow execution for this work object.
Add multiple file attachments, with a category for each, in a single
action.
Add a party to a work object, as controlled by the associated work
parties rule.
Include this work object as belonging to a cover, another work
object in a Work-Cover- class. This flow action supports a search
for the appropriate cover and selection from search results. By
default, not eligible for bulk processing.
Create a Link-Folder instance associating this work object with a
folder. Select the work pool, then select the folder work object.
Attach a file to the work object, including an explanatory note but
no attachment category. Supports browsing for the file to be
attached. Uses HTTP (or HTTPS) to upload the file
Enter a text note (property .pyDetail) and an actual effort value
(property .pyEffortActual). Does not alter work object status. This
action used in applications created by the (basic) Application
Accelerator.
Type in a text note that becomes an attachment to the work object.
Select one window from a list of windows on the Windows
desktop, and then capture and attach a screen shot JPG image to
102
AttachAUrl
AttachFromScanner
ChangeAssignmentSLA
ChangeOwnerOrg
ChangeSatisfaction
ChangeWorkSLA
EditAttachment
Flows
RequestAssistance
RejectSample
RemoveFromCover
RemoveFromFolder
Save
SelectRecipients
AndAttachments
SendCorrespondence
Transfer
TransferAdvanced
TransferToManager
UrgencyUpdate
VerifyProperty
VerifyPropertywithListing
103
Use Description
Placeholder action with no input requirements.
Y
Enter a note, record the user's approval of some previous
Y
Assign
AttachandHold
CancelAssignment
Y
C
ChangeClass
Classify
ConvertAttachment
toPDF
CorrPrompt
CorrVerify
EditCategorized
Attachment
EngageExternal
Y
N
Y
EngageManager
EngageStaffmember
EnterInformation
EnterInformation
External
Finish
Y
Y
N
GetAppointmentList
assignment or question.
Send the assignment to another operator, by selecting first a
work group and then the operator within that work group.
Generate and attach Word correspondence
Complete the current assignment and display the
Confirmation harness.
Change the work type (class) of the work object to a
different type in the same work pool, re-editing property
values as required. This can be used to correct an incorrect
work type. For example, a work object initially recorded
with a SuspendDelivery work type may actually be a
CancelSubscription work type.
Change the work type of the current work object to another
work type in the current application (work pool), by
selecting that work type from a selection box. For example,
a work object initially entered as an Unclassified work type
may, after more information becomes available, be classified
as a Renewal work type.
Converts an existing work object attachment that has a DOC
file type, created by Microsoft Word, into a new work object
attachment with a PDF file type.
Prompt for correspondence fields.
Verify previously created but unsent correspondence.
Create a version of a Microsoft Word file attachment that
has an attachment category.
Start a new flow on this work object that creates an
assignment to an external party.
Initiate new flow on work object that creates an assignment
to the manager of the assignee.
Initiate a new flow execution on work object that creates an
assignment for another user.
Allows the user to enter a note.
Similar to EnterInformation, but allows an external user to
enter a note.
Save a work object without validation; the validate activity
is not called.
Allows users to query the Microsoft Outlook calendars of
other operators. Typically you use GetAppointmentList and
104
@baseclass.
GoBack
Notify
NotifyExternal
NotifyQuick
PickLanguage
PortletAction
Y
Y
Previous
PreviousOperator
Reject
RemoveSLA
Resolve
ResolveAsDuplicate
ResponseVerified
RetryProblemFlow
N
SampleEmailToCustomer Y
SearchForDuplicates
SelectCorrTemplate
SelectCorrType
SendMeetingRequest
Y
Y
Y
SetTicket
StandardTemplate
TakeOwnership
Y
Y
TransferTo
Workbasket
Verify
Y
N
105
Withdraw
Set (turn on) a ticket on the work object causing the system
to resolve it as withdrawn, including a reason for the
withdrawal.
HTML Property rules are instances of the Rule-HTML-Property class. Use HTML
Property rules to control how properties appear on work object forms,
correspondence, and other HTML forms, for both display and for accepting user
input.
Dynamic Select function in an HTML rule type:
The Dynamic Select control is an optional feature you can add to work object forms
(through HTML rules, harness rules, or section rules) and other HTML forms to
speed user input
The Dynamic Select control displays a drop-down list that contains values returned
from an activity.
This control provides a dynamic alternative to the normal (static) HTML SELECT
element below:
<select Name="name" >
<option Value="red">Red</option>
<option Value="yellow">Yellow</option>
<option Value="green">Green</option>
</select>
Validation
A validate rule is an instance of the Rule-Obj-Validate rule type. To validate a
property or a page means to check its value against certain rules, and add a message
to the property or page if validation fails. An invalid page (a page that has any
associated messages) usually cannot be stored into the database.
Validate rules are part of the Process category. Validate rules test property values,
typically immediately after they are submitted on a browser form.
Rules of four types can reference validate rules:
Flow action rules, to validate user input
Flow rules, to validate user-entered parameter values
Activities, with the Obj-Validate method
Correspondence rules, to validate user responses to prompts
106
Purpose
Defines validation for work objects (not covers) when
the work object is created (entered).
Defines validation for work objects when the work object
is updated.
Defines validation for cover work objects when first
created (entered).
Defines validation for cover objects when updated.
A validation rule may reference edit validate rules (Rule-Edit-Validate rule type).
Use the Edit Validate form to define a Java routine that tests the validity of an input
value in an activity that processes user input. The activity calls the Property-Validate
method, which applies the test defined in an Edit Validate rule.
A property rule (of mode Single Value, Value List or Value Group) may reference an
edit validate rule on the Advanced tab. Use the Property-Validate method in an
activity to execute the edit validate rule when a value is submitted through a user
input form.
Process Commander contains more than 60 standard edit validate rules. The table
describes a few of them:
Name
DoesClassExist
Purpose
Checks whether a text string identifies a Process
Commander class.
FileName
Checks whether a text string is a valid Windows file
name.
FileType
Checks whether a text string is a valid Windows file
type.
InternationalPhone Validates the format of an international phone number
IsNonNegative
Checks whether a value is greater than or equal to zero.
NotFutureDate
Expects a string in theValue in the format
YYYYMMDD. This rule returns true if that date is
today's date or a past date, or false if the date is a future
date or not in the expected format.
OperatorPassword
Supports the optional password management facility.
pyMinimumLength- When applied to the value of a property that is associated
Enforce
with the pyMinimumLength property qualifier, compares
the actual length of the value to the minimum and returns
false (with a message) if the value is too short.
SSN
Validates the format of a U.S. Social Security Number.
107
TIN
Note: Don't confuse validate rules with edit validate rules; the latter require Java
programming skills to develop. Validate rules can call edit validate rules.
Portals
The Process Commander portals support two user communities:
The Developer portal provides an integrated work, test, and development
environment to support application developers. Customization of the Developer
portal is typically not necessary and ordinarily limited to menus and skins.
User portals support managers and users of applications workers, as they enter,
update, and resolve work objects. User portals may be customized to reflect the
terminology, layout, facilities, and styles appropriate to each user community.
The appearance and function of your Process Commander portal depends on
information in your access group which references a portal rule (Rule-Portal rule
type).
108
Field
Default Portal
layout
Secondary Portal
Layouts
Description
Identify a portal rule to indicate which portal
presentation supports those requestors who reference this
access group.
For developers, you can define alternative layouts, to
allow them to quickly switch between layouts; this is
useful in debugging. Enter the name of a portal rule to
make an additional portal presentation available to this
user.
110
Step 1 identifies the name and RuleSet version of the skin rule and other associated
rules to be created.
Step 2 displays the Quick Create feature enabling you to, in one-step, create default
fonts, and the main and accent colors for your portals, work forms, and reports. You
can also add a top header logo for traditional portals.
Step 3 defines general appearance of most UI elements including background, fonts,
and links. It also defines the appearance of the panels built into a harness rules (used
for composite portal types), and enables you to add custom styles.
Steps 4A through 4E define the appearance of smart and custom layouts, as well as
bar, tab, accordion, and repeating (tab, row, and column) layouts.
Steps 5A and 5B define the appearance of menus and grids.
Steps 6A through 6C define the appearance of labels, buttons, and error sections.
Steps 7A and 7B define report components including title bars, columns, and headers.
Steps 8A through 8D define the appearance of UI elements that are unique to
traditional (non-composite) user portal rules.
111
Navigation:
You can open any step without proceeding through them sequentially. Click directly
on a step in the navigation panel to open its screen. A check mark appears next to the
step when you go to another step. Alternatively, use the Next >> and << Back buttons
to navigate.
Some steps contain a set of collapsed sections. You can expand them all by selecting
the expand button () at the top- right corner of the wizard screen.
As you work with the wizard, click Preview to open in a new window a rendering of
most UI elements as configured so far. By default, they are displayed individually as
used in composite portals, work forms, or reports.
Some elements do not display in preview mode. In those cases, save the skin to a
composite-type portal and open the section to review the changes (specify the skin in
the Developer's portal preferences section).
Important Points:
Skins produced from this wizard are not suitable for the Developer portal. Use these
skins only with User portals.
The wizard defines an application skin (Rule-PortalSkin rule type) and its associated
CSS style sheet text files (Rule-File-Text rule type). The skin references images as
binary file rules (Rule-File-Binary rule type) and is linked to portal rules (RulePortal rule type).
112
Questions
1. Select the rule which is not under UI category
a.
Rule-HTML-Harness
b.
Rule-HTML-FlowAction
c.
Rule-HTML-Section
d.
Rule-Obj-FlowAction
2. Which one of the tool is used to view the definition of a section in Harness?
a. Image viewer
b. Form Builder
c. Rules Inspector
d. Clipboard
3.
a.
b.
c.
d.
e.
Which of the following rules are not subject to rule resolution (select two)?
Harness
Section
Binary File rules
Text File rules
Fragment rules
4. Using Rules Inspector, which of the following can be identified (Select all that apply)
a. Flow rules
b. HTML rules
c. Property rules
d. When Rules
e. Declarative Rules
f. Field Value Rules
5. The portal layout for group of users can be generally controlled from which of the
flowing
a. Organization
b. Division
c. Unit
d. Access Group
e. Workgroup
6.
a.
b.
c.
d.
113
a.
b.
c.
d.
8.
Classic
Metal
Both
None of the above
Which of the std. validate rule defines validation for work objects when the work
object is updated.
a. Work-.OnAdd
b. Work-.Validate
c. Work-Cover-.OnAdd
9.
a.
b.
c.
d.
In an Edit Validate form, how is the property value referred in the java code
this
theValue
Value
propertyName
10. _______________ rules control how properties appear on work object forms
Correspondence, and other HTML forms, for both display & accepting User input.
(HTML Property)
11. Local Flow Actions are added to which task form?
a. Assignment
b. Utility
c. Decision
d. Connector
12. The standard privilege ------------allows a user to apply one flow action to a list of
assignments. (Work-.PerformBulk)
114
115
116
If all the conditions in a row evaluate to true, then the Actions and Return
columns of that row are processed. What happens next depends on the Evaluate
All Rows check box (on the Results tab).
If the Evaluate All Rows check box is not selected, processing ends and the
system returns the value in the Return column as the value of the entire rule. If
Evaluate All Rows box is selected, processing continues through all remaining
rows, performing the Actions and Return calculations for any rows for which the
conditions are all true.
If for no rows in the table do all conditions evaluate to true, the system returns a
default result.
Rules of four other types can reference decision table rules:
In a flow rule, you can reference a decision table rule in a decision task,
).
identified by the Decision shape (
In an activity, you can evaluate a decision tree using the Property-MapDecisionTable method.
A Declare Expression rule can call a decision table rule.
A collection rule can call a decision table rule.
Map Value is an instance of Rule-Obj-MapValue. Use a map value rule to convert
one or two input values (text, numbers, or dates) into a single resulting value, where
the decision criteria fit a table or matrix structure. This is a straightforward way to
present decisions and computations that depend on ranges of the input values.
Example: "If the test score falls between 91 and 100, assign a grade of A. If the test
score falls between 81 and 90, assign a B. Assign C for 71 to 80."
Cascading Map Value: Through cascading where one map value calls
another map value rules can provide an output value based on three, four, or
more inputs. One map value cell can reference another map value rule as the
source of its value. Type the word call followed by the name (the second key part)
of another map value rule with the same first key part. SmartPrompt is available.
Click the pencil icon ( ) to open the other map value rule.
Complete the Input tab before the Matrix tab. Optionally, to restrict the possible
results to one of a small known list of literal constants, complete the Results tab
before the Matrix tab.
Rules of five types can reference map value rules:
In a flow rule, you can reference a map value rule in a decision task, identified
by the Decision shape (
).
In an activity, you can evaluate a map value rule using the Property-MapValue method or Property-Map-ValuePair method.
A Declare Expression rule can call a map value rule.
A map value rule can call another map value rule.
A collection rule can call a map value rule.
117
118
Use the fork shape ( ) to represent a point where the flow execution chooses one of
a few different paths (connectors) based on tests on the work object. At runtime, the
system evaluates the conditions on each outgoing connector, starting with the
connector assigned the highest likelihood. The flow execution continues along the
first connector that evaluates to True.
) to reference a map value rule, decision table rule,
Use the Decision task (
decision tree rule or a Boolean expression that when evaluated produces a value that
is the basis of branching in the flow.
At runtime, the system evaluates the decision rule based on inputs from the flow and
the work object, and chooses one of the outgoing connectors based on the result. No
user interaction or input is required.
Choose a decision rule
Type: Map Value or Decision Tree or Decision Table or Boolean Expression.
Rule: Select a map value rule, identified by the second key part.
Declarative Rules:
Declarative processing: It simplifies the application and reduces the number of
activities that needs to be created. The declarative processing facilities support
operation of six rule types:
119
120
121
by the Access Group referenced in the Declare Pages rule, not by the RuleSet list
of individual requestors. The associated access group is defined on this tab.
Note: In a multi node system, each node has its own copy of the clipboard pages
created by this declare pages rule. For each node, the first user to reference the
declare pages rule causes the load activity to run on that node to create the page on
the clipboard.
Refreshing Declare Pages:
The first Refresh Strategy is common to all types of Declare Page types, that is
both thread and node scoped pages. Quite simply, define a period of time in Days,
Hour, Minutes, and Seconds in the appropriate fields. When the page is
referenced, this value is used to check that the page is stale. If the page is older
than the specified time, the Load Activity is executed to recreate it, otherwise, its
classed as fresh.
For Thread Scope pages, there is an additional, optional feature allowing you to
add a When rule. The When rule answers the question Is the Declare Page
fresh? When your declared page is referenced by a rule, if the When rule
evaluates as True, the Load Activity will not be executed because the page is
deemed fresh. If the When rule evaluates as False, the page is deemed stale and
the load activity will be executed.
Function Alias rules are instances of the Rule-Alias-Function class. They belong to
the Technical category. Use an alias function rule to define prompting for a function
rule for users who maintain decision rules. The alias rule provides an optional naturallanguage description and prompting that supports certain selection lists on decision
rule forms.
Complete and test the function rule itself before defining a function alias rule that
references it.
Cannot define an alias for a function rule that returns a complex Java type (that is,
a type other than a Java.lang. String type or a primitive type such as int).
Where referenced
Alias function rules are useful for functions that managers or less technical
developers may use frequently in decision tree rule, when condition rules, Declare
Expression rules, and constraints rules.
Rule Delegation:
A delegated rule is a link to a rule or data instance that provides a quick shortcut.
Click the link to open the form. For managers who use the standard WorkManager
portal, these links appear on the My Business Rules area in the Dashboard workspace.
Depending on access roles and privileges, the manager can update the entire rule form
or only fields in the leftmost tab of the rule form.
122
To mark a rule as delegated, open the rule form and click the Favorites toolbar button
(
Questions:
1. In a Declare-Expression rule, If I want to use an expression, which contains
expressions, function calls constants etc. Which of the following to be used.
a)
b)
c)
d)
123
124
c) When directives
d) Decision Table
11. Which of the following returns a boolean value?
a) When rule
b) Decision tree
c) Decision table
d) Decision Map
12. Examination questions if answered 90-100 Grade A, 70-90 Grade B, 50 -70
Grade C. What are the possible rules which can be used to achieve this?
a) Decision Table
b) Map value
c) When
d) Declarative Expression
125
126
127
Do not use Pega or Pega- as a prefix for your RuleSet names. This usage is
restricted for use by Pegasystems and can cause unexpected behavior.
For legibility, use single-word names with significant letters in uppercase (also
referred to as title case). For example, CandyOrders is easier to read than
candyorders.
Avoid using special characters such as dashes (-), underscores (_), plus signs (+),
or quotation marks (").
Use names that make sense, avoiding obscure acronyms. A name should clearly
describe the RuleSet. For example, QuadStateMortgage is better than QSGMLS
(as an acronym for Quad State Group Mortgage Loan System).
For a test RuleSet, use a name that contains Test or Sample.
A RuleSet version is the process of assigning unique version numbers A RuleSet
version is an instance of the Rule-RuleSet-Version rule type.
The version number in the form NN-NN-NN, defines six digits in three groups that
characterize the evolution and development of a rule instance, and of the application
it belongs with. The three segments are known as the major version, minor version,
and patch version.
In every rule instance, the pyRuleSetVersion property records the version number
(without the name and colon) of that rule.
A few rule types are not versioned:
Application
Class Has a version for File > Export and migration purposes only.
RuleSet
RuleSet Version
Access of Role to Object
Access Deny
Library
Rule Resolution
Rule resolution is the sophisticated internal search algorithm that the system uses to
find the best or most appropriate rule instance to apply in a situation. Rule resolution
applies to most, but not all, classes derived from the Rule- base class.
Rule resolution does not apply to instances of classes derived from the Work-, Data-,
or any other base class.
128
While the rule resolution algorithm is fast and invisible, it is important to understand
how it operates. As you create applications, make your choices of values for key parts
based on how you want rules to be found by rule resolution.
Benefits:
Rules can be shared across applications and organizations. Sharing and reuse is a
major benefit of object-oriented software.
Rules defined at a higher level can be overridden by more specific rules defined at a
lower level. While this dilutes the sharing benefit, it provides often-needed flexibility
while bringing visibility to exceptions.
Rules can have multiple versions, even within one RuleSet, and security rules control
which users see and execute which versions. This facilitates application evolution,
testing, and patching.
One Process Commander system can host multiple applications, multiple
organizations, and multiple versions of one application with minimal concern for
conflicts and interference.
Applications can be developed independently from other applications, yet all can
depend on common rules that are locked (and so won't change)
Rule resolution uses as input values:
129
Different Phase
Phase 0 (Purpose)
Phase 1 (Product)
Phase 2 (User)
Phase 3 (Timing)
Phase 4 (Customer)
Phase 5 (Security)
Description
Match rule type and name
Search up the class hierarchy as necessary
Filter by RuleSet list and availability
Filter based on date and time
Qualify on Circumstance
Enforce Access Roles and Privileges
130
RuleSet Locking:
Select to lock this RuleSet version. If selected, no one can save new rule instances to
this RuleSet version, or update or delete existing instances.
Clear this box to allow developers to save rules associated with this RuleSet version.
You may be prompted for a password upon saving.
Important Points:
Changes made to this box take effect immediately after you save the Version
form, except for rules that a user has open at that moment or that a user has
checked out from this version.
Locking a RuleSet version does not prevent later changes to class rules in the
RuleSet, as a class belongs to a RuleSet but not to a version. To prohibit changes
to class rules, complete the Security tab of the RuleSet form.
As a best practice, compile each library that contains functions in this RuleSet
version once more before locking the version. If a needed function fails to
compile, you won't be able to correct the function rule later, without unlocking the
version.
As a best practice, lock a RuleSet version only at a time when no rules are
checked out from that version. To confirm this, select View > Rules > All
Checkouts by RuleSet, Version and scan the resulting report for rules from this
RuleSet.
131
132
Date Rules that differ depending on the current date or the submission date of a
loan or policy.
Personal RuleSet:
The private RuleSet is sometimes called the personal RuleSet.
Users who have the Allow Rule Check Out? Check box (on their Operator ID
instance) selected can place copies of rule instances into a private RuleSet. The name
of this RuleSet is the same as their Operator ID, such as john_sawyer@abc.com.
The system creates a private RuleSet automatically when needed.
No instance of the Rule-RuleSet-Name class exists for a private RuleSet.
Private RuleSets are used in with check-in and check-out, part of the rule
management facility. When an application developer checks out a rule, it enters his
private RuleSet.
A private RuleSet is always topmost in a user's RuleSet list. Rules in a private
RuleSet are never executed by other users.
As you develop rules, a memory cache similar to, but separate from, the rule cache
contains rules in your private RuleSet. The maximum size of this cache (for all
developers combined) is determined by elements in the fua node of the prconfig.xml
file.
On the requestor page, the standard property pxRequestor.pxSecuritySnapshot.
pxPersonalRuleSetName identifies the private RuleSet; if this is blank, the requestor
cannot check out rules.
Application Rule
An application rule defines a set of RuleSet versions to be added as a unit to a user's
RuleSet list. An application rule is an instance of the Rule-Application rule type,
which is part of the Security category
In some situations, your application RuleSets may include rules that you do not
consider part of the application, or may exclude others you expect.
The application RuleSets does not include your private RuleSet, which contains
rules checked out to you
The application RuleSet does not include rules in RuleSets listed in the Production
RuleSets array of the Access tab.
133
Rules from RuleSet versions listed in the Requestor Type data instance,
Organization data instance, or Division data instance are not included unless these
RuleSets also appear in the application rule.
Ordering of RuleSets in Application Rules:
Order
1st
2nd
3rd
4th
5th
RuleSet Type
Personal RuleSets
Production
RuleSets
Application
RuleSets
Pega Rule Sets
Pega-RULES
RuleSet
Description
The RuleSet that contains rules that are
checked out to a user. Rule resolution
automatically checks this RuleSet first.
RuleSets that are unlocked to allow rule
changes.
RuleSets that are deployed in a production
system; they are usually locked.
1. Pega-ProCom
2. Pega-IntSvcs
3. Pega-WB
Pega-RULES
Note:
This is a collection of RuleSets, not a collection of RuleSet versions
An operator's full RuleSet list in contrast to the Application RuleSets list is
an ordered list of RuleSet versions not RuleSets. Your RuleSet list often
contains additional RuleSets not present on the Application RuleSets list.
The RuleSet list is an internal data structure that the system uses to determine which
rule instances that a requestor can execute. Click the link containing your name at the
top of the navigation panel to review your RuleSet list, presented on the profile
display.
How a RuleSet list is compiled?
Your RuleSet list is assembled bottom-up
The RuleSet list has file sub-lists in two layers
134
The top layer contains one sub-list, of override RuleSet versions (if any). This
sub-list is assembled from those listed in the Override RuleSets area of the
Advanced tab of an application rule that is directly referenced by an access
group listed in one of the five data instances described below in this topic.
(The contents of the Override area of application rules referenced through the
Built on Application field are ignored.) At runtime, rules found by rule
resolution among the RuleSet versions in the top layer supercede all rules
located anywhere in the second layer, unless the rule found in the second layer
has an availability of Final.
The second (bottom) layer may contain four sub-lists: one private RuleSet,
application RuleSet Versions, shared and component RuleSet Versions, and
the locked Pega- RuleSet Versions that define Process Commander.
Note:
Don't confuse the RuleSet list with application RuleSets, a subset of the RuleSet
list relevant to developers who are using the Application Explorer and other
developer tools. The RuleSet list is an ordered set of RuleSet versions. The
application RuleSet is a collection of RuleSets, with no versions.
The standard function rule IsInRuleSetList(RuleSet) tests whether a RuleSet is
included in your own current RuleSet list.
Multivariate Circumstancing
A circumstance is an optional qualification available for all rules. Using a
circumstance allows your application to support multiple variants of a rule. For
example, variations of an ordinary rule instance can be created for different customer
status levels or for different geographic locations.
Circumstance qualified rules
A circumstance-qualified rule instance (often referred to as a "circumstanced
rule") is always based upon an unqualified rule instance (base rule). You can
circumstance a base rule with a single property and its value, or with multiple
properties and their values (called multivariate circumstancing). The
circumstanced rule is selected by rule resolution if the value of the circumstance
property on the rule matches that property's value on the clipboard at runtime.
icon identifies a circumstance-qualified rule instance. A
On many displays, an
icon identifies a base rule instance that has one or more circumstanced
instances. The rule form for a circumstance-qualified rule displays the property
135
and its value next to the Circumstance label located in the top right area of the
form
If you use a single circumstance property, you define the property name and its value
directly in the Save As form. If you use multivariate circumstancing, there are two
rules in the Save As form:
Circumstance Templates (Rule-Circumstance-Template rule type)
Circumstance Definitions (Rule-Circumstance-Definition rule type)
Multivariate circumstancing enable you to specialize a rule by more than one feature.
For example, an insurance company may be required to collect, for every state, claims
that exceed a specific amount and the method by which the claims were conveyed
(letter, phone, email, and so on). Another example may be the need for a rule that is
specialized by an age range and not an absolute value.
Note:
1. Circumstances are available only for certain rule types those with the Allow
Selection based on Property Rules? box selected on the Class form defining the
rule type. As of Version 5.4, you can circumstance-qualify Declare-Constraints,
Declare-Expression, and Declare-OnChange rules.
2. You cannot use circumstances with a final rule
3. If a circumstance-qualified stream rule contains JSP tags (rather than directives),
the base rule must also contain JSP tags rather than directives. Conversely, if the
time-qualified rule contains directives, the base rule must contain directives.
4. If two rules with the same Applies To key part and family name are both
unqualified and each has one or more associated property circumstance-qualified
rules, the same circumstance property must be used. For example, if activity
MyClass. Alpha has an associated circumstance-qualified rule using property
.State, then another activity MyClass. Alpha cannot have a circumstance rule with
any property other than .State.
Database software supporting your Process Commander system limits the number of
columns that can occur in any database table. When creating a Circumstance
Definition rule, you may not exceed this limit.
In releases before V5.2, circumstance-qualified rules with a RuleSet version number
lower than the RuleSet version of a base rule were ignored (never selected) during
rule resolution. Starting with version V5.2, this is not the default rule resolution
behavior: you can copy a base rule to a higher version without the need to also copy
each of the (possibly many) qualified rules associated with the base rule into that
higher version. If desired, you can revert in specific cases to pre-5.2 behavior by
136
selecting the Base Rule check box on the form produced by the Availability toolbar
button (
).
Use the Circumstance Property Issues report (a link in the Rule Reports area of the
Monitor Activity slice) to identify single circumstance-qualified rules that incorrectly
use two or more different properties. Such conflicts can arise when rules are imported
into a RuleSet that already contains some circumstanced rules.
Access Groups
Access groups bind the many aspects of an application. In addition, they determine
which applications and which parts of those applications users can access.
An access group is an instance of the Data-Admin-Operator-AccessGroup class.
Access groups make a set of RuleSet versions available to requestors.
Developers define access groups and associate an access group with each user (each
Data-Admin-Operator-ID instance). Typically, multiple users are associated with or
belong to one access group.
An access group is associated with a user (or other requestor) through the Operator ID
data instance. The access group determines:
Their portal layout
Which work pools are available
The types of work objects they can enter
Which RuleSets appear at the top of their RuleSet list
Which access roles and privileges they hold
The initially displayed RuleSet and version for rules they create with New or Save
As.
The system uses access groups identified in up to four data instances to assemble a
user's RuleSet list during sign-on:
Operator ID
Organization
Division
Requestor type
When referenced in the following, access groups determine the RuleSets and
Versions available to external systems when they request services from a Process
Commander application.
Service package data instances
Listener data instances
Service rules
137
Complete this tab to identify the class groups, RuleSets, and access roles available to
the Operator IDs or requestors that reference this access group.
Field
Description
Application Fields
To update this RuleSet Name rule, a user enters the same
Name
password in this field as the one you specify in the field of the
same name in the Define Passwords section above.
Version
138
139
Use this tab to define the home directory, portal layout, and other capabilities for
users or other requestors who reference this access group.
Field
Login Setting
Default Portal
layout
Description
HTTP/HTTPS
140
Local
Customization
141
Use this read-only tab to review or quickly access Operator ID instances that
reference this access group.
Field
Description
Application Fields
Full Name Full name of an operator, from the Operator Full Name field
on the Operator tab of the Operator ID form. Click to open the
Operator ID form.
Key of an Operator ID instance that references this access
Operator
group on the Operator tab of the Operator ID form. Click to
ID
open the Operator ID form.
When first installed, your system contains the following access groups, each linked to
the standard application rule PegaRULES.05.05.01.
Name
PegaRULES:Administrators
PegaRULES:Agents
Purpose
For developers, users of the Developer portal.
For all Batch requestors. Supports all agents,
listeners, and services, including the PegaProCom agent, which enforces service level
rules. Update this access group to reference
any application RuleSet Versions that contain
service level rules.
For JSR-168-compliant portlet access.
PegaRULES:PortalUsers
PegaRULES:Unauthenticated For guest users. If your organization
implements
the
optional
password
management facility, update this access group
to make the restrictions of the PegaPwdControl
RuleSet apply during login.
PegaRULES:WorkManagers For managers. This is a sample; create access
groups for managers that provide access to the
portal, RuleSets, and privileges appropriate to
their needs.
For users who are not managers. This is a
PegaRULES:WorkUsers
sample; create access groups for managers that
provide access to the portal, RuleSets, and
privileges appropriate to their needs.
142
Security
Rule types and data classes are organized into categories as a learning and navigation
aid. The Security category contains seven rule types and four data classes respectively
Rule types
Access Deny
Access of Role to Object
Access Role
Access When
Attachment Category
Privilege
Setting
Data classes
Access Group
Application ID
Keystore
WS Security Profile
Denial of access to the class can depend on the production level value (1 to
5) of your system or whether certain Access When rules evaluate to true.
By default, Process Commander denies all access to a class except when
explicitly granted by an Access of Role to Object rule.
143
Name rule type) and then create an Access of Role to Object rule for the
appropriate classes.
3. Access Role
4. Access When
Access When rules are instances of the Rule-Access-When class.
An Access When rule defines a test that the system performs to allow, or
disallow, a requestor to perform an operation on an instance of a specific
class.
You can reference Access When rules in Access of Role to Object rules and
Access Deny rules, as an alternative to a system production level number.
Don't confuse the Rule-Access-When rule type referenced only to control
user access to a class with the more widely used Rule-Obj-When rule
type. The forms are similar, but the purpose and references are different.
Note:
1. For each of the eight categories in the array, you can enter an Access When
rule name, or a numeric value between 0 and 5.
2. Enter 0 or leave blank to prohibit all access. Enter a value between 1 and 5 to
provide access. If, at runtime, the production level of your Process
Commander system is not greater than the numeric value, then users with the
specified access role can perform the operation (on objects of that class). If an
Access When rule evaluates to True at runtime, the users with the specified
access role can perform the operation.
5. Attachment Category
a. Attachment Category are instances of the Rule-Obj-AttachmentCategory rule
type.
144
145
f. To require privileges for use of a rule, reference privileges in that rule within
your application. This option is available for selected rule types only
d. After a privilege is defined, you can associate it with specific rules in eight
rule types. One type conveys access and seven types restrict access:
1. Activities To limit use of the rule to users who hold a privilege
2. Attachment category rules To limit operations that can be performed
on an attachment
3. Correspondence To limit use of the rule to users who hold a privilege
4. Flows To limit starting the flow to users who hold a privilege
5. Flow actions To limit selection of the action to users who hold a
privilege
6. List view rules To limit which users can produce the list view report
7. Summary view rules To limit which users can produce the summary
view report or chart
8. The association between access roles and privileges is defined by
instances of the Rule-Access-Role-Obj rule type.
e. Access of Role to Object rules To convey privileges to those users who
hold an access role
7. Setting rules
Use a setting rule to define a name and data type for a setting that your
application's activities can use for finely tuned access control. You assign
values to a setting when you reference it in Access of Role to Object rules
for various class/role combinations. This lets you specify different access to
certain capabilities for different access roles based on the value of a setting.
8. Keystore
A keystore is a file that contains encryption keys. You can attach a keystore
file to a data instance of the class Data-Admin-Security-Keystore, to support
Web
Services
Security.
9. WS Security Profile
146
Authentication
Authentication is the process of determining the identity of a user or other requestor.
Process Commander authenticates users by matching submitted user names and
passwords to those that are stored in Operator ID instances. If the submitted user
credentials match those in an Operator ID, the user is authenticated. A requestor or
user who is not authenticated is known as a guest.
Process Commander supports several types (or schemes) of authentication:
PRBasic Based on passwords in Operator ID data instances and the log-in
form (defined by the HTML rule @baseclass. Web-Login, which your application
can override).
PRSecuredBasic Similar to PRBasic but passes credentials using Secure
Sockets Layer (SSL) using Basic HTTP authentication The log-in form is defined
by the HTML rule @baseclass.Web-Login-SecuredBasic, which your application
can override.
PRCustom Supports access to an external LDAP directory or a custom
authentication scheme.
PRExtAssign Supports external assignments (Directed Web Access).
J2EEContext specifies that the application server in which Process
Commander is deployed use JAAS to authenticate users.
Authorization
Authorization, on the other hand, defines the realm of actions that you are allowed to
perform, and the data and resources you are allowed to access.
Authorization follows authentication (i.e., you must first prove who you are before
the system can determine the list of actions you're authorized to perform and the
resources you are authorized to access).
147
Questions:
1. What is the purpose of locking a RuleSet version?
a) To restrict the access of rules belonging to the RuleSet version
b) To activate the export feature
c) To restrict new instances being added to the RuleSet version
d) To restrict the creation of new RuleSet versions for the RuleSet
2. The best way to create a new Major RuleSet version is to use:
a) Export Rules
b) Load Rules
c) Skim Rules
3. RuleSet versions consist of 3 separate numbers:
a) Patch-Major-Minor
b) Minor-Patch-Major
c) Major-Minor-Patch
d) Minor-Patch-Major-SubMajor
4. Which of the statements below is NOT one of the main purposes of a Rule set?
a) To act as a container for rules.
b) To facilitate migration & shipping (application deployment).
c) To play an important role in rule resolution.
d) To define security for rules
148
b) Division
c) Unit
d) Access group
8. An Access group is associated with a user through the _______ data instance.
(operator id)
9. Access group is not referenced in the following rule(s)
a) Requestor type
b) Unit
c) Operator ID
d) Work Group
10. Access Groups control (Choose 3)
a. Access Role
b. Password
c. Portal Layout
d. WorkPools
e. Operator ID
11. Users of the PegaRULES Process Commander system are defined by:
a. access groups, access roles and operatorIDs
b. access groups, security groups and operatorIDs
c. a user class
d. security groups and access roles
12. The Ruleset list is assembled in which of the following order
a. Alphabetical
b. Chronological
c. Generalized followed by Specialized ruleset
d. Specialized followed by Generalized ruleset
13. The Circumstance feature is defined by:
a. Circumstance Property and Circumstance Level
b. Circumstance Value and Circumstance Level
c. Circumstance Property and Circumstance Value
14. Declarative rules such as Rule-Declare-Expressions and Rule-Declare-Constraints
can be specialized using circumstances. (TRUE/FALSE)
15. Rule resolution applies to all the classes that are derived from Rule- base class.
(True/False)
16. Rule resolution dynamically selects the right rule by searching your profile RuleSet
list across multiple dimensions, including purpose, class, ruleset and version, date and
time range, circumstance and security. (YES/NO)
149
11. Integration
150
Services:
A service receives input from an external system and can respond in some way. For
example, a service can reply with data that the external system requested and it can
process the incoming data to determine that it needs to create a work object and
initiate a workflow.
The following is a high-level description of how a service works:
An external client or system assembles and delivers a message or request to a
Process Commander Service. The message identifies the service package that
contains the service rule or method to invoke.
The service package locates a service rule.
The service rule, in turn, invokes the appropriate rules to map the incoming
parameters to Process Commander Properties.
The service rule invokes an activity. The activity processes the input
Properties and completes the task of the service. As mentioned, perhaps the
service extracts data from the Process Commander database or delivers a work
item to Process Commander. The data mapping for the service rule then maps
appropriate values into output properties.
The service assembles a response message from the output properties and sends
the response.
151
152
15. SnapStart is a lightweight data import facility that conveys data from one
desktop application into Process Commander under the control of a user. Building
a SnapStart interface requires skills in creating HTML forms and writing short
activities. Unlike the other services, the SnapStart service does not rely on a
subclass of Rule-Service.
Service Package: A service begins with a service package data object. A service
package is similar to a container class. A service package represents the service as an
application and the service rules represent individual functions or methods in that
application.
Instance of Data-Admin-ServicePackage
Our SOAP service rules are placed in this package.
The service package has global configuration settings for all the services that belong
to it:
The access group that the service rules use when they run as unauthenticated
users. The service rules must belong to one of the RuleSets listed in the access
group.
Whether the services must run as authenticated users. If so, the incoming message
from the external client application must include the name and password of a
valid Process Commander operator.
Configuration information about the requestor pool when the service rules run as
unauthenticated users and session state is stateless.
Whether the service is stateless or not.
If the service is stateful specify whether to keep the requestor session
open and when to close it in the service rules.
If the service is stateless, the End Requestor option in the service rule does
not apply.
For SOAP, dotNet, BPEL, EJB, Java, Portlet, COM, and CORBA services, use
the service package form to generate deployment files. Process Commander translates
the functions and processing provided by the service rules in that service package into
the appropriate kind of deployment component for a service of that type.
153
154
Service Rule: The service itself is defined by an instance of the appropriate RuleService- subclass. The service rule handles the details for this kind of request; that is,
the service rule maps the input parameters into clipboard properties and then calls an
activity to process the request.
The service rule holds the following types of information:
Class of the primary clipboard page that the service uses
Name of the primary clipboard page that the service uses
Name of the service activity
Information about whether to keep the requestor session open or to close it after
the service rule is finished.
Information about recognizing and reporting exceptions
The list of input and output parameters, their data types, and how their values are
mapped to and from clipboard pages.
A service rule has three key parts:
Name of the service package. The service package must exist before you can
create the service rule.
155
Name of the service class. This name is a string; it is not an instance of Rule-ObjClass. The service package name and service class name are used to group service
rules.
Name of the service method. This name is a string; it is not an instance of RuleMethod. The service method name describes what the service rule does. This is
the only key for an email service rule.
An incoming message must identify the service by specifying all three parts of the
name (package, class, and method) in the message.
156
A service activity evaluates the property values that are stored on clipboard pages
and takes an action. When creating a service rule, designate the service activity by
entering its name in the Activity Name field on the Service tab of the service rule.
Connectors are the mechanism that Process Commander uses to send messages to or
make requests of external systems and then process the results or response.
The following is a high-level description of how connectors work:
A work object triggers an Integrator task in a flow.
The Integrator task calls the connector activity and passes it the appropriate
properties from the clipboard.
The activity calls the connector.
The connector assembles and sends a message or request to the external
system.
The external system replies to the connector with the data the connector
Requested.
157
The connector receives the reply, processes it, and places the data as
PropertyValue pairs on the clipboard. The connector then returns control to the
Integrator task, and the flow resumes.
158
.Net connectors are Microsoft .NET clients that call Web services on external
systems based on the Microsoft .NET Framework.
MQ connectors send request messages to an external system and process
responses through an intermediate server that hosts IBM WebSphere MQ
middleware.
BPEL connectors act as a container for the SOAP services and connectors that
represent Process Commander as a partner of a Business Process Execution
Language (BPEL) process when Process Commander starts the process.
The connector activity is the mechanism that starts the connector. A method in the
activity calls the connector rule. For example, if the connector is a SOAP connector,
the activity uses the Connect-SOAP method to call the connector rule.
159
With the exception of the SQL connector, a connector rule has two key parts:
Name of the class rule it applies to
Service name, which holds the name of the external service or method that it
connects to.
Connect SQL rules are instances of the Rule-Connect-SQL class. They belong to the
Integration-Connectors category. Connect SQL rules are used when the application
needs to run complex Structured Query Language statements such as joins or stored
procedures to update or extract information from an external database.
To configure an SQL connection to an external database, use the following elements
along with the Connect-SQL rule:
An activity that references one or more of four standard methods for operating on
relational databases RDB-Open, RDB-List, RDB-Delete, and RDB-Save. The
names of the methods match the names of the tabs in the connector rule. An
activity that uses RDB-Open to call a connector rule runs the SQL statement on
that connectors Open tab.
A Database instance and one or more Database Table instances that provide
access to the tables or views of the external database.
A JDBC library that provides access to the external database software.
Special data mapping syntax to associate properties with database columns.
160
Use Open tab to open a single row in the data base. To execute the SQL statement
on this tab, an activity uses the RDB-Open method.
Use the Delete tab to enter the SQL to delete a row or rows from a relational
database. The SQL statement in this tab operates in conjunction with an activity
that uses the RDB-Delete method.
Use the Save tab to enter the SQL to save an instance to the database. The SQL
statement in this tab is executed by an activity that includes the RDB-Save
method.
Use the Browse tab (in conjunction with an activity that includes the RDB-List
method) to create a rules that at runtime searches an external relational database
and returns to Process Commander data from the selected rows.
The HTTP integration interface supports interactions between the Process
Commander applications and other systems through Hypertext Transport Protocol.
Use HTTP connector rules when the application wants to send XML or string data
(text) as messages to an external system without the need to comply with messaging
standards or protocols like SOAP.
There are two types of HTTP method which is GET and POST. "GET" is basically
for just getting (retrieving) data whereas "POST" may involve anything, like storing
or updating data, or ordering a product, or sending E-mail. A Connect HTTP is
created which is inherited from Integration-Connectors.
Service tab: Used to identify the external system with which this connector rule
communicates.
Endpoint URL: Enter the URL of the external system to which this rule
connects.
HTTP method: Select which HTTP method to use to send the string: GET or
POST.
Request only: When the HTTP Method is set to POST, select to indicate that
Process Commander is to send the message and close the connection without
waiting for a response.
161
163
XML ParseRule: The incoming data is a stream of XML that must be parsed
using the actions defined in a parse XML rule (an instance of Rule-Parse-XML).
Delimited ParseRule: The incoming data is in a delimited format that must be
processed by a Parse Delimited rule (an instance of Rule-Parse-Delimited).
Structured Parserule: The incoming data has a fixed format with fixedlength fields and must be processed by a structured parse rule (an instance of
Rule-Parse-Structured).
Map To Key: Specify the key to locating the property or the rule in the
destination specified in the Map To field.
If the Map To value is Clipboard, enter the property name to which the data is
to be mapped.
If the Map To value is XML Parse Rule, enter the Namespace name
(secondkey part) and the Element Name - third key part - of the appropriate
XML parse rule. Separate the Namespace from the Element name with a space
using
the
syntax
NamespaceName
ElementName"
rather
than
"NamespaceName.ElementName." The system uses the Applies to class of this
connector rule as the first key part of the parse rule.
If the Map To value is Delimited ParseRule, enter the Namespace and
Record Type names (second and third key parts) of the appropriate delimited
parse rule. The system uses the Applies To class of this service rule as the first
key part of the parse rule.
If the Map To value is Structured ParseRule, enter the Record Type (third key
part) of a structured parse rule. The system uses the Applies To class of this
service rule as the first key part of the parse rule.
If the Map To value is a Rule-Utility-Function function from a MapTo library,
either select a property to hold the results of the function or leave this field blank,
as appropriate for the function.
164
Mapping Connect-HTTP method to the Activity: Specify the name of the method
to be used as Connect-HTTP. In Connect-HTTP method in the activity specify the
name of the Service (name of the Connect HTTP method).Specify the name of
another method as Show Property. Enter the value of the property to which the
MessageData has been mapped.
File Listener
File Listener
A file listener monitors the file directory and calls the file service when files arrive.
The file service uses a parse rule (XML, structured, or delimited) to open and read the
file, evaluate each input record, divide the records into fields, and then write the fields
to the clipboard. The service activity can then process the data pass the data to
another rule, or start a flow and create a work object based on the data.
Both the file listener and the file service have a part in processing the files. When the
listener starts, it creates subdirectories in the file directory it is monitoring. When files
that match the pattern the listener is listening for arrive, the listener moves the files
into a subdirectory named work_<name of listener> and calls the file service.
When the file service finishes processing the file, the listener either deletes the file or
moves it to the work_<name of listener>/completed subdirectory, depending on how
the listener is configured. The listener also creates a reports subdirectory to hold
report files that contain the results of the processing.
165
Use the File Listener form in conjunction with Service File rules to import data from
a file or files into your Process Commander system.
Use the Rules by Type Explorer to review or create file listener data instances, or
click the File Listeners link on the Resources area of the Integration slice ( ). As an
alternative to updating this form directly, you can create a File Listener data instance
through the Service accelerator.
Use file services to read in and process the data in files. The data files may be
exported from another system, or created by users as text files in any of a wide
variety of formats. Before setting up a file service, determine the following:
The target directory, that is the location of the files to be processed
How the listener identifies the files should it process every file it finds, only
those files with a specific file extension or some other distinguishing characteristics,
and so on
How the files are arranged is there one record in each file or multiple records in
each file, what is the data structure of the records, and so on
Note: Verify that it has these access rights, because the listener moves and sometimes
renames files, the Process Commander server must have read and write access to the
file system where the input files arrive. Verify that it has these access rights.
166
167
When you create the service rule in a later task, you will set the service's page class to
that of the work class, and not the class generated from the XSD file. For that reason,
you cannot call the generated XML parse rule directly from the service rule. Instead,
you'll map the incoming file data to a placeholder property and then call the parse rule
from the service activity. Create a single value text property to use to as a temporary
storage place for the incoming data until the XML parse rule can be called from the
service activity.
For example:
168
On the Steps tab, configure a step that creates the page you defined on the Pages
and Classes tab. In the next step, set the Step Page to that page and use the ApplyParse-XML activity method to invoke the XML parse rule. The first key to the rule is
the page class of the step page. Provide values for the methods parameters as
follows:
NameSpace the second key part of the XML parse rule name
ElementName the third key part of the XML parse rule name
SourceProperty the name of the placeholder property that holds the input
record at runtime (the property you created in step 2 of the previous
procedure)
At runtime, the XML parse rule specified parses the data located in the
SourceProperty and puts it on the step page in the clipboard.
In the next step, configure a step that uses Page-Copy to copy the contents of the
Step Page clipboard page to the embedded page property that you created in step 1 of
the previous procedure.
169
170
4.
On the Method tab, describe how the contents of the files are organized. To
continue with the example, you would set Processing Method to file at a time,
specify text only in the Data Mode field, and leave the Character Encoding field
set to Default.
Note that if the files contain multiple records and records of different types need
to be processed differently, you select either record at a time or by record
type. Then you describe how the service rule can determine where one record
ends and another record begins with the fields in the Record Layout and Record
Type Identifier sections.
5.
On the Request tab, use the Parse Segments section to map the data from the file
to the clipboard or a parse rule and to specify the service activity that is to process
the data. Continuing with the example, you would configure one row that maps
the incoming data to the single-value placeholder property you created and
specifies the name of the service activity in the Activity field:
171
Note that if the files contain multiple records and records of different types need
to be processed differently, you create as many rows as you need in the Parse
Segments section. If the records can be identified by type, you use the Record
Type field to indicate which processing definition to use for records of each type.
If the different records always appear in the same sequence but there is no type
indicator, you use the order of the processing definitions to specify which activity
or parse rule to use for each record type.
6.
Save the rule and then test it. Click the Run toolbar button, provide some
representative data for the service rule to process, and click Execute. Do not
continue to the next task until you see a success message similar to this one:
172
If the file listener and service must run as an authenticated requestor, specify the
credential of a valid operator in the User ID and Password fields.
6. On the Process tab, specify how frequently the listener should check the directory
for files, in seconds.
7. Use the Reporting section if you want to keep a record of the results from the file
service processing. For example, perhaps youd like to keep a record of the IDs of
the work object created from the processed files. Specify the page and property
where the information is located in the Source Page Name and Source Property
fields.
5.
173
Optional. On the Error tab, specify how many times the file listener and service
should attempt to process the same file if there are processing errors and what to
do with files that cannot be processed.
9. Save the listener, and then return to the Properties tab. Click Test Connectivity.
Do not continue to the next task until you see a success message similar to this
one:
8.
174
5.
Examine the results and verify that the file service worked the way you expected
it to.
175
176
Debugging
To include the clipboard results of service file processing in the Pega log, temporarily
add the Log-Message method at an appropriate place in the service activity. Set the
LoggingLevel parameter to InfoForced and the Message parameter to: Contents of
page:\n" + myStepPage.getXML());
177
d. Neither
4. COM, CORBA, SOAP and JSR-94 are protocols that can be used with:
a. Services
b. Connectors
c. Both
d. Neither
5. The container that holds all the components of a service is of which class:
a. Data-Service-Requestor
b. Data-Admin-ServicePackage
c. Rule-Admin-Services
d. Rule-Service-Package
6. To prevent the file listener from starting when the PRPC system starts, which must
be edited?
a. prconfig.xml
b. prresources.jar.
c. config.xml
d. resources.jar
7. _____________ is defined as programmatic components that implement an
interface that is defined by an external system. With the Process Commander
application acting as the client and the external system acts as the server.
ANS: Connectors
8. SOAP is a protocol that can be used with:
a. Services
b. Connectors
c. Both a and b
d. Neither a or b
178
179
Preflight Tool
The Application Preflight tool reports the results of several checks on the rules in
the currently selected application. These checks encourage good design and
implementation practice, as codified in the guardrails and elsewhere. A rule in your
application may work correctly and save without errors, but still be marked with a
warning ( ). The Application Preflight tool summarizes these warnings.
For example, a decision table rule may contain two rows that conflict give a
different result for the same inputs. You can save the decision table rule and execute
it within your application, because the uppermost row of the table is used at runtime,
and other conflicting rows are ignored. However, the conflict may indicate that the
rule was not entered correctly.
We can perform the preflight check at any time during development. As a best
practice, use the Application Preflight tool before you lock a RuleSet version.
Research each warning message. Warnings are instances of the Index-Warning class,
which corresponds to the pr_index_warnings database table. Warnings appear only
when a rule is saved in a V4.2SP6 or later system. Rules saved in earlier versions and
not yet resaved in a newer system do not include warnings.
180
If we Click Download High Priority Warnings, the Download warnings for <your
application> dialog appears. Click Download to obtain a list report of high priority
warnings for the RuleSets in your current access group and download it as an Excel
spreadsheet. The File Download dialog appears. Click Open to download the file
and open it in Excel.
The all warnings by rule type display the number of rule instances for each rule type
that contains a warning. You can change the rule type range in the display using the
slider widget at the top of the chart.
181
The summary report specifies, for each rule type, the number of rule instances that
do and do not have warnings. Click a Rule Type name in the summary for a list of the
rules with warnings. Click a list item to open the rule form.
Click the open icon ( ) next to the RuleSet Name field. Select one or more
RuleSets from the list (only RuleSets that contain warnings are included). Click
Apply. Click the Run button (
182
Displays a bar chart and summary report of rule instances that have warnings. The
chart shows the number of rules within each rule set as a percentage of all the rules in
the RuleSet. The summary and Criteria functionality are the same as described above
for the All Warnings by Rule Type report.
Displays a pie chart and summary report of total warnings by severity level (four
levels). Level one signifies a warning that is most likely to compromise expected
processing behavior. Hover your cursor over each section of the chart to display
number of warnings at each level and the percentage each level represents of the total.
The summary and Criteria functionality are the same as described above for the All
Warnings by Rule Type report.
183
Tracer
The Tracer is a tool that monitors an individual requestor session, tracking the
execution of rules. The Tracer tool provides full debugging facilities, the Tracer tool
to debug flows, activities, services, parse rules, and declarative rules. Including stepby-step execution, breakpoints, and watch variables. You can pause and resume
processing, view or set the value of watch variables, and drill down to step-by-step
details. You can view trace events for any requestor connected to your server node,
not just your own session.
How to start the Tracer tool?
1. Select Run > Tracer to trace your current session and Thread.
2. Select Run > Trace Open Rule when a service rule or activity rule is open in the n
workspace. You can start the rule with the Run toolbar tool ( ).
3. Type the keyboard shortcut CTRL + T.
184
Function
Button
Choose a requestor session other than your own. Wait a few seconds
until the Tracer connects.
Connection
Select which RuleSets, rules, and events are to be traced.
Options
Set or change breakpoints.
Breakpoints
Watch
Save
Clear
Pause the session being traced at the next possible moment.
Pause
Resume processing after a Pause button click, or after a breakpoint
Continue event. Appears only after a pause.
Save
Save the Tracer results in the current window into a text file in
Comma-Separated-Values format or as a more detailed XML file,
depending on prconfig.xml settings. See Tracer Adjusting the
buffer size.
You can open and print the saved CSV file with Microsoft Excel. (This
operation is available only on user workstations that have installed the
PegaClientSupport ActiveX control.)
By default, the Tracer displays the 500 most recent trace lines. You can set a
higher value and this requires additional workstation memory.
3) PegaRULES engine started: This alert message occurs each time the
PegaRULES engine starts successfully. This alert is included in V5.1+.
Reason for alert: Process Commander System adds this alert when
initialization completes. The message indicates that the PegaRULES engine
started successfully. In a development environment, this alert may appear
many times in an Alert log, due to developers restarting server nodes.
The prlogging.xml file is a control file for the Process Commander logging
facility, a modified version of the Apache log4j facility. Entries in the
prlogging.xml file follow the syntax of Apache log4j xml configuration entries.
For example, the following settings cause INFO-level logging for every agent,
activity, model, and when rule:
<category name="com.pega.pegarules.engine.context.Agent">
<priority value="info"/>
</category>
<category name="Rule_Obj_Activity">
Log4j
Process Commander includes a central file named prlogging.xml on each node to
control the contents of the server console output and Pega log files. You can
temporarily override settings in this file using the Logging Level Settings tool.
The logging facility is based in part on the log4j facility (v1.2.14) from the
Apache Software Foundation, and operates similarly to that facility. By editing
the prlogging.xml file and incorporating appenders, you can affect the format and
level of detail in the log file as an aid to debugging.
Refactoring tools
We can use the Refactor Rules tool to move rules to a different Applies To class,
RuleSet, or RuleSet version. After selecting the class in your Application
Explorer, you specify the new class, RuleSet, and RuleSet version, and the
individual rules you want to move. The rules are saved to the target class and
removed from the original class.
For example, if the work class MyCo-Mortgage-West- has 200 applicable rules
200 rules which apply to that class in RuleSet version MyCo:03-04-07,
you can move them all into class YourCo-Mortgage-East- and RuleSet version
YourCo:01-01-01 with this tool.
2. The Refactor Rules page displays the below screen and use this page to
specify the criteria for the refactoring, and to select the rules you want to move.
1. A check mark indicates success, and an 'X' indicates an error. Hover over the
error status to display a tool-tip describing the problem.
13. Reporting
Reports:
Rule types in the Reports category define reports that support the Monitor Activity
workspace, the Explorer tools, and other facilities. This category includes two rule
types list view rules and summary view rules.
Any developer can create and maintain these two rule types. Managers who create
reports using the Report Wizard also indirectly create rules of these types.
Managers can define reports in four categories, covering work objects,
assignments, and work object history.
Developers can define reports on any concrete class derived from the Assign-,
Data-, History-, Index-, Log-, Rule-, or System- base classes.
Reports on assignments and work objects operate as in the Monitor Activity
workspace of the WorkManager portal, reflecting only the assignments and work
objects in one currently selected work pool.
In Monitor activity slice you can have the contents of reports and charts you can
access in this area. The Main categories in this slice are
Monitor Assignments reports gather and present information about the open
assignments in one application (work pool). They list assignments that are past
their goals and deadlines, and show assignments by organization.These reports
can also show you the contents of work lists and workbaskets.
Analyze Quality reports summarize data about the resolved work objects
from one application. These reports display data about how many items were
resolved according to the service level agreements configured for the process,
the operators who resolve the most items, and the number of work objects that
were created in a specific time period, and so on.
Operators with the SysAdmin role and using the Developer portal see two
categories in addition to the four listed above:
Rule Reports tally and list the rules in your system. The data included in
these reports is system-wide the data does not depend on the RuleSets or
work pools you have access to.
Data Reports. There are no standard data reports. Application developers may
determine a need to report on instances of classes that inherit from the Database class.
To see all the reports from a category, click the Browse button on the toolbar
in that section.
To start the Report Wizard, click the Create Custom Report button on the
toolbar of the appropriate category.
To see a list of your custom reports, click the Custom Reports button on the
toolbar of the appropriate category.
Most reports display data from a single application (work pool). If you have
access to more than one application, be sure to select the application you are
interested in before running the report.
List View:
A list view rule, an instance of the Rule-Obj-ListView rule type, defines a report.
Users can personalize list view reports easily and interact with them.
In an activity, the Obj-List-View can execute a list view rule to provide searching
and sorting with no display.
Both developers and managers can create and update list view rules.
List reports display lists of data that match selection criteria. For example, an
operators work list is a report of this type. The following report is a workbasket
list.
Three sets of standard list view rules support the Monitor Activity workspace:
Several standard list view rules with an Assign- class as the Applies To key
part support the Monitor Process Assignments group.
Several standard list view reports with Work- as the Applies To key part that
report on open (unresolved) work objects support the Monitor Process group
of reports
Page 193 of 224
Several standard list view reports with History-Work- as the Applies To key
part support the Analyze Process Performance group of reports.
Summary view:
Summaries present the data that match selection criteria as an aggregate that is,
summarized lists that are organized by data point. This report shows open work,
summarized by work status.
To drill down to the individual records, expand the section in the summary report.
For example, a click on the Status: New category in the preceding example makes
the report display a list of those work objects in a separate window.
Interactive charts display the data from a summary report as a pie, bar, column,
area, or line chart. For information about creating charts.
Reports are implemented through list view rules and summary view rules, which
the Report Wizard can generate for you. If you have a system administrator access
role, you can share the reports you create with other users and embed links to them
on the Monitor Activity page.
Report Wizard:
The Report Wizard presents a series of forms that prompt you to enter the
information it needs to define a report selection criteria and which fields to
display.
Work objects, assignments, rules, and data classes have a set of standard
properties whose values are stored both in the blob and in separate columns.
These properties work status, create operator, goal time, for example are
said to be "exposed" and they are what you use as selection criteria for your
reports.
Because reports can select records based only the values of exposed properties, the
application developers considered your reporting needs while planning and
implementing the data design for your applications.
If you determine that you need additional properties to use for selection criteria,
consider the following guidelines:
To expose single value, non-embedded properties, you can directly change the
schema of the existing pc_work tables or other storage tables by adding new
columns for the properties.
To expose complex or embedded properties, you must use declarative
indexing.
To see the columns of the tables in the PegaRULES database, use either the
View/Modify Database Schema Wizard or the database schema reference,
which is located on the installation media.
In the Data Source form, select the appropriate class or work type. The options
that appear depend on the category you started the Report Wizard from. If you
started it from Monitor Processes, the form displays work types.
In the Define Criteria form, specify the selection criteria that is, the fields and
their values to use as the selection criteria for the records to include in the
report. The picture below shows the criteria for a report about open work.
When you are finished with the selection criteria, verify there are records that
match the criteria with the preview count link. Then click Next.
In the Select Fields form, specify the fields you want displayed as columns in the
list report. For example:
In the End form, specify which buttons to display when an operator generates this
report, and then click Next.
In the Preview form, examine the results. Is this what you wanted? If not, click <<
Back and fine-tune the display fields and/or selection criteria until you are
satisfied. When you are finished, click Save View.
In the Save form, name and describe the list view rule that holds your report
definition. The Purpose field holds the report name and the Title field holds the
Short Description. Then click Save.
The wizard saves the report as a list view rule and displays the Delegate View
form.
In the Group By form, specify how you want the data summarized. For example,
for a report about open work objects, you could specify that the data should be
organized by organization unit, division, and organization.
Summary list reports offer the person running the report to drill down to the
individual records. In the Drill Down form, specify the fields you want displayed
as columns in the lists that show the individual records.
In the Chart form, click Next without selecting the chart option
In the End form, specify which buttons to display when an operator generates this
report, and then click Next.
The wizard saves the report as a summary view rule and displays the Delegate
View form.
Questions:
1. Custom reports can be created as all the following rules except:
a. Rule-Obj-Report
b. Rule-Obj-ListView
c. Rule-Obj-SummaryView
2. The first step in the Report Wizard is to:
(a) Indicate source of the data for the report
(b) Select the report layout
(c) Create the SQL to get the data
3. What are the slices available in developer portal (select multiple answers)
a. Cases and Content
b. User Interface
c. Dashboard
d. Monitor Activity
4. The home page of the Developer portal provides rapid access to six facilities,
known as----------.
5. While we are using List report which of the options is not available to Developer?
a. Drill down
b. group by
c. Fields
d. Criteria
Deploying a product
You can create a ZIP archive file from a product rule for use in archive tools such as
the Import Archive tool, the Export Archive tool, or the Migration Wizard.
Different ways of Creating ZIP archives:
These related wizards work with product rules or ZIP files:
Product Migration Wizard Creates a ZIP archive from a product or product
patch rule, migrates the archive, and imports it to one or more destination systems.
Package Work wizard Creates a product rule that (when executed) includes
work objects, work object history, and work object attachments.
Purge/Archive Wizard Removes resolved work objects from your system and
optionally saves them in a ZIP archive.
Basic Navigation:
Access these tools from the File menu. Select:
File > Export Archive To copy rules and data instances from the PegaRULES
database to create a Zip archive file on the server.
File > Migrate Product To create a product rule that packages work objects.
File > Import Archive To upload rules and data instances in a previously
exported ZIP file into the PegaRULES database of the destination Process
Commander system.
About Product Rules
Complete the Product form to define a rule that identifies the RuleSets and versions,
rules and data objects, and other parts of an entire application. This rule supports the
migration and delivery of an application to other Process Commander systems.
After you complete and save a product rule, you can generate a ZIP file containing:
Rules in RuleSets and versions comprising a specific application.
Rules in selected RuleSets and versions.
Instances within any class. These can be filtered using a list view rule, or can be
individually selected from a list.
A post-installation Read Me display.
Product rules are instances of the Rule-Admin-Product class. They belong to the
SysAdmin category.
Procedure (Creating Product Rule):
1. Identify the RuleSets and Versions that comprise your product. As a best practice,
choose View > Rules > All Checkouts to list all rules checked out. Confirm that
none of the rules in these RuleSets are checked out and being worked on. Errors
are reported if you create a ZIP archive at time when any of the rules designated
for it are checked out.
2. Although not required, you may want to review these RuleSet Version rules to
confirm that each RuleSet version is locked. (RuleSet Version Form Locking
Enable the Lock this Version?)
3. Create a product rule by selecting Application > New > Rule > SysAdmin >
Product from the menu.
4. Identify and Select the Application RuleSets
In the RuleSets to Include section, enter the RuleSets and the appropriate RuleSet
versions. Order the RuleSets in the list as they would appear on a RuleSet hierarchy as
shown in this example:
System-User-MyRules Instances
Organization Data Classes
Data-Admin-Organization Always set to Your org name
Data-Admin-OrgDivision The Divisions with your company
Data-Admin-OrgUnit Set to Agency or the internal department
Data-Admin-Workgroup Work group name
Data-Admin-Workbasket Workbasket name should identify the function it is
serving
Services/Connectors Data Classes
Data-Admin-ServicePackage Always reference the appropriate service name
Data-Admin-Connect-EmailListener
Data-Admin-Connect-EmailServer
Data-Admin-Connect-FileListener
Data-Admin-Connect-JCAAAdaper
Data-Admin-Connect-JMSListener
Data-Admin-Connect-JMSProducerModel
Data-Admin-Connect-JNDIServer
Data-Admin-Connect-MQListener
Data-Admin-Connect-MQServer
Data-Admin-EmailAccount
Mapping Data Classes
The following classes control where instances of a class are stored. Since many
applications depend on database tables and class groups, it is a best practice to always
include them:
Data-Admin-DB-Name
Data-Admin-DB-ClassGroup
Data-Admin-DB-Table
Other Application Data Classes
Display Data Instances (not shown above that inherit from Data-)
Note: Some concrete Data- classes contain information that is valid only on a
single Process Commander system, or only on one node of a single system. For
example, the system creates a Data-Agent-Queue record automatically on each
node, and the Node ID is part of the key. Listeners and similar data instances
(Data-Admin-Connect-* ) contain port numbers, computer names, and passwords.
Do not include instances of these Data- classes in a product ZIP archive unless
you have carefully confirmed that they are valid on the target system.
5. Select the Application Data (optional: using When Rule)
To ensure that you include the requisite data objects for your application you can
use either when rules or query data instances from data classes.
Don't create a ZIP archive at time when any of the rules designated for the archive
are checked out. An error is reported identifying each checked-out rule. Neither
the original version nor the checked-out version of the rule is included in the ZIP
archive
Export Archive form
1. Select an export mode
Select to determine the scope of the contents of the ZIP file:
By RuleSet/Version To create a ZIP archive containing all rules in a RuleSet and
Version (or all versions).
By Product
To create a ZIP archive containing rules and data defined by
an existing product rule (Rule-Admin-Product rule type).
By Patch
To create a ZIP archive containing rules and data defined by
an existing product page rules (Rule-Admin-Product-Patch
rule type)
ZIP File on Server
To copy a previously created ZIP file from the Process
Commander server to a local directory.
If you selected By RuleSet/Version, select a RuleSet from those on your RuleSet list
for the RuleSet field.
Complete the RuleSet Version field. Select a single version for that RuleSet, or All
Versions.
If you selected By Product, or By Patch, complete these two fields to identify the two
key parts of an existing product or patch rule.
The second key part (Version) of product and patch rule types is not necessarily
related to RuleSet Versions.
File Name
1. Enter a file name for your Zip file in the File Name field. Use a file name that
is valid for both the destination server and the current server; they may be
hosted on different Windows or UNIX platforms. The ".ZIP" suffix is
optional. Many special characters are allowed in the file name, but you can't
include spaces or an equals sign character (=) in the file name.
2. Click Create ZIP File . The system displays the progress of the extraction,
which may require one to several minutes. A progress bar shows the count of
rules extracted.
3. When the export operation completes, the Zip file created link provides access
to the new file, typically placed in the ServiceExport subdirectory of the server.
4. If errors are reported, click the Total Number of Errors link in the lower right
corner of the display form to see the error messages. You can print this for
later analysis.
5. To save the file now to a local directly, click the Zip file created link. Choose
Save in the pop-up window. (You can download the file later using the ZIP
File on Server option.)
6. Click Close.
Note:
If the RuleSet versions you select contain any checked-out rules, neither the
checked-out copy of the rule nor the checked-in rule is included in the ZIP file
created. Each such rule is noted as an error.
Although Process Commander does not restrict the number of records or size of
the ZIP file, some vendor ZIP utilities limit the file size to 2 gigabytes.
2. Navigate to the local directory that contains the ZIP file, select it, and click
Upload file .
In the File Name field, type in the full path and name of the ZIP file to be
uploaded, or click Browse .
If you attempt to upload a ZIP file when the ServiceExport directory already
contains a file of that name, a prompt appears. Click to confirm that you want
to overwrite the existing file.
Using this facility, by default, you can't upload a ZIP file using this facility
that is larger than 25 MB. This is an intentional design restriction on the
HTTP file copy facility, not a limit on the rule import processing. For larger
files, use File Transfer Protocol (FTP) or another means to place the file into
the ServiceExport directory. Alternatively, you can set a higher (or lower)
upload limit on your system by changing the value for the
Initialization/MaximumFileUploadSizeMB parameter in the prconfig.xml file.
3. Completing the form Zip File On Server
Click to select one file in the boxed text area.
If you do not see the name of the file you want to import, click Back and use the
Upload form to copy the file to the Process Commander server.
This page lists the top-level classes and RuleSets in the import archive in the left
column. In the right column, specify the New Class Names and optionally specify
New RuleSet Names that you want to apply to each class or RuleSet as they are
imported. You cannot use a class name or RuleSet name that already exists in the
system.
If the import archive contains a product rule, the Refactor on Import tool looks for a
previous import of the same Rule-Admin-Product name. If there is a previous import
of this product, the tool will provide the refactor parameters used in that import as the
default values for the current import. You only need to confirm that the changes are
still valid.
When the changes are specified correctly, click Next.
Step 5: Verify Classes
This page displays the changes that will be made to the classes and RuleSets.
When you have confirmed that the changes are correct, click Next to continue.
If the changes are not correct, click Back to reset the parameters or Cancel to exit
from the wizard.
The Pega Log also known as the console log or system log contains
messages created since the server was most recently started. The log file is
usually named PegaRULES-YYYY-MMM-DD.log, where the date portion of
the name indicates the date the application server was recently started (on the
current node).
Log messages
In an activity, use the Log-Message method to add a message to the Pega log.
What is the PegaRULES Log Analyzer tool and how does it work?
The PegaRULES Log Analyzer (PLA) tool is a Web application that consolidates and
summarizes three types of logs from individual JVM server nodes in your application
system. The log data provide key information about operational and system health.
Developers and system administrators can use this information to quickly identify,
diagnose, and remediate issues that may be degrading or compromising:
Performance
Stability
Scalability
after deployment into a production environment. These are the phases when
performance, stability and scaling issues are likely to occur.
Regular monitoring during development and production helps ensure that your
application is operating at its full potential. PLA signals issues that may grow into
major operational problems if not addressed early.
Operational checklist
The results of a PLA import should indicate the following:
Alert log
System log
Garbage collection
log
PLA provides an efficient method for diagnosing the issues and locating their root
causes.
Viewing data in PLA
The Home view in the PLA window (shown below) presents a table summarizing the
benchmark metrics in each type of log. For instance, the log for January 23 there were
198 exceptions. The next day there were 116 alerts of which 5 were critical. These are
issues that need immediate remediation. Given the large number of total alerts (which
include non-critical alerts), you should investigate them to assess their impact on
production and remedied if necessary.
Using view options located in the left panel enables you to display the data in
summary and list reports for each log type. Here is an example of an alerts list report
generated when you click Alerts:
You can sort the tables on almost any of the columns. For example, you can sort the
alert list shown above by Severity so that Critical alerts rise to the top of the report.
From this view you can drill down into an alert to display the alert details including
PAL data, trace list, pega stack, and parameter page. Here is an example for a
PEGA0028 alert:
Rule-Admin-Product: we can add rules and data classes also. In addition, we can
consider more than one ruleset at a time
Move Rules: we can add rules only to zip file. Also we can consider only one
ruleset at a time