Rule resolution is the search algorithm used by the method to find the correct or most suitable example of a rule to be implemented in a situation. Pega regulates the perfect rule to run while an application calls it.
The resolution of the rule extends to all but a few forms of rule, classes inherited from the base class of the rule. The resolution of the rule shall not extend to instances of classes originating from the working class, data class, or any other basic class.
Although the algorithm for rule resolution is fast and invisible, it is necessary to understand how it works. When designing applications, depending on how you want rules to be found by rule resolution, make your choice of values for key pieces.
An in-memory rule cache allows the process of rule resolution to run faster. If the machine detects an example (or instances) of the rule in question in the cache, it recognizes what is in the cache as the rules of the candidate and skips several steps (see below in the PEGA resolution process.
To get in-Depth knowledge on Pega cssa you can enroll for a live demo on Pega cssa training.
Benefits of PEGA rule resolution
The advantages of PEGA rule resolution include the following.
- It is possible to share rules across applications and organizations. Sharing and reuse are major advantages of the development of object-oriented applications.
- Rules defined at a higher level may be overridden by rules defined at a lower level that are more precise. While this dilutes the advantage of sharing, it offers the versatility often needed, while providing exceptions with visibility.
- Even within one ruleset, rules may have several versions, and security rules regulate which users see and execute which versions. This allows the evolution, testing, and patching of applications.
- With minimal consideration for conflicts and interference, one PEGA 7 Platform system can host multiple things. Like many applications, multiple organizations, and multiple versions of one application.
- PEGA Applications can be built independently of other applications, but all can rely (and will not alter) on universal rules that are locked.
PEGA rule resolution process
The inputs to the process of rule resolution are as follows.
- Searched for key parts of a rule case, such as its Applies to class and name
- The list of user rulesets, compiled when the user logs in,
- The hierarchy of the class- the arrangement of parent classes and subclasses below the ultimate base class.
- Access responsibilities and privileges retained by the individual, as defined by the access community group
- Laws for protection and access control, such as Function to Object access rules and privileges
Get hands-on experience on PEGA CSSA with expert knowledge through the Pega csa training at Onlineitguru.
Availability of rules:
The rules are open, blocked, final, removed, or not accessible
- If constraints of time and date impact the rules are available for this session
- In certain situations, the worth of a property under the circumstances
The first rule found to meet all the parameters is the performance of the resolution process. (No instance of a rule is found and execution stops sometimes. The machine then executes the selected rule. This also allows one or more extra rules to become required. These are also discovered by PEGA rule resolution.
The method of PEGA rule resolution
The steps in the process of rule resolution are as follows.
Step 1: Search the cache for rules.
Additional database lookups are avoided by using rules already in the rules cache.
If there’s a rule then, go to Step 8. Continue to Step 2 if not.
Step 2: With the correct intent, pick instances.
The purpose, or “family name” combines all the main properties of law, with the exception of the class defined on”
The key properties of an activity law include:
- Applies to the class in which defines the operation.
- The Name of the Operation.
The activity name is the aim in this case.
The key properties for a Field Value include:
As above “Applies” To class
- Name of the Area
- The benefit of the Field
- In this case, the purpose is the field name plus the field value, such as ‘pyActionPrompt.ViewHistory.’
- The device selects all objects for the relevant purpose and positions them in a temporary list.
Step 3: Dispose of rules with Availability = No.
The device removes from the temporary list the inaccessible rules.
Step 4: Discard unenforceable variants and rulesets.
The system removes rules belonging to rulesets and versions that are not allowed by the current requestor from the list. For example, if the user profile contains the version of the ruleset ThisRuleSet: 05–01, the rules belonging to ThisRuleSet: 04- or ThisRuleSet: 06- will be dropped.
Step 5: Discard all candidates in the ‘ancestor tree’ not specified in a class.
The list will only maintain rules contained in classes from which the current class descends by either pattern or direct inheritance.
This step is not used for rules that do not have the Use Class-based Inheritance check box selected in their class description to come up with the correct rule to execute.
Step 6: Rate the majority of the applicants.
The scheme classifies the remaining rules on the list in order of applicants.
Please note that:
The PEGA rule set and version rankings in the user profile are based on the ordered list.
A rule with a particular qualifier ranks higher than one that has no qualifier.
Circumstantiated laws are alphabetically ranked by the importance of the situation.
Circumstance Rank of dates in descending meaning.
Date/Time ranges are ranked first by their end date (in ascending order) and then in descending order) by their start date.
Step 6a: Discard choices that occur after the first rule of “default”
For any scenario, circumstance date, or date/time set, a default rule (with no qualifiers defined) is called a match. The method, therefore, discards any rules that are lower in the list than the first default rule that it finds.
Step 7: The cache is set.
The method adds to the cache, as selectable for use, the rules that remain on the list.
Step 8: The best instance is identified and duplicates are tested.
The method will check the list for the first rule:
Corresponds exactly to an inferred law
Has the right circumstantiated date
The right date/time range is
With no qualifiers, this is the default rule.
The method checks if the next rule in the list is similarly right when it finds a rule meeting these conditions. If it is the process sends a message stating that the system has redundant rules and stops processing.
If no duplicates are found, the system will be ready to use a rule matching the conditions specified.
Read More Info Here: Pega cssa certification training
Step 9: Check that availability has not been blocked.
The process checks Availability again to see if, for this law, it is set to block. If so the machine sends a message that it has not been able to find a suitable rule to use.
Step 10: The requestor is required to check that the rule is visible.
Finally, the procedure verifies that the requestor has permission to access the selected law. The machine uses it if so. If not, it sends a message that an acceptable rule can not be found to be used.
Example of PEGA rule resolution in a PEGA application
Using an application will cause the PEGA 7 Platform to look for a flow in the Work-Contract-Application-Complete class called Repair.
In the Work-Contract-Application-Complete class, the method first explores and then searches (if no match is found) for higher classes in the hierarchy of classes. Candidates are all flows belonging to rulesets and variants that are present on the list of rulesets.
The Final word
A few rule types have instances that are not associated with a rule set and version, and when an instance of these classes is requested, no rule resolution processing happens. Access roles (Rule-Access-Role-Name form of rule) must, for example, have specific system-wide names.
Additionally, certain other types of rules do not support processing qualified for circumstances or time. You can learn about rule resolution and more through PEGA CSSA online training.