What is rule availability in pega
Rule availability in pega determines if the rule is accessible in a rule resolution algorithm and can we SaveAs, edit, and Open a rule in Dev Studio.
Rule resolution algorithm in pega
"Rule resolution is a search algorithm used to find the most appropriate instance of a rule to execute in any situation."
Types of rule availability in pega
We have below five rule availability options in pega.
- Available (Yes)
- Final
- Not Available (No)
- Blocked
- Withdrawn
Rule Availability of a rule is visible on the rule form next to the rule name or description.
Available (Yes):
When we create a rule the default availability is "Available" and it determines the rule is accessible during the rule resolution process. We can view, save as, edit, and execute rules in Dev Studio.
Final:
If the rule availability is Final indicates that rule may be used during the rule resolution process.
We can not save as or edit the rule into another ruleset if the availability is Final however we can open and see the rule and execute it in dev studio.
If we see any pega OOTB rules marked as final indicates the rules may be changed in future releases.
Not Available (No):
If the rule availability is "Not Available" indicates that rule may not be used during the rule resolution process but the next highest version of the rule instance will be used.
Activity "Uploadusers" instance is there in 3 versions and the highest version is marked as "Not Available".
We can SaveAs, view, and edit NotAvailable rules in dev studio but we can not execute it. We will set the availability of a rule to Not Available during initial development which allows us to save a rule without validation.
Blocked:
If the rule availability is "Blocked" indicates that rule may be used during the rule resolution process but will not be executed. If the selected rule is the highest versioned instance and is marked as Blocked, execution will be stopped and will see an error message in the logs as well.
Activity "Uploadusers" instance is there in 3 versions and the highest version is marked as "Blocked" and it will be selected during rule resolution but not executed, system stops the process and throws an error.
At run time we can see an exception in the tracer.
We can SaveAs, view, and edit Blocked rules in dev studio but we can not execute it.Withdrawn:
If the rule availability is "Withdrawn" indicates that the Withdrawn version and below (lower) versions of the same rule (same rule type, name, and class) will not be selected during the rule resolution process.
For example:
from the below table, the availability of the rule (Section) named RequestForm in the Training:01-01-10 ruleset is set to Withdrawn. All rules that are in the same ruleset with an equal or lower version number and have the same purpose and Apply to class are not considered during rule resolution. The rule named RequestForm in the Training:01-01-15 is considered during rule resolution because the ruleset version is higher than the ruleset version of the withdrawn rule.
If the rule in Training:01-01-15 did not exist, a rule in the parent class, TGB-Training-Work, will be selected.
Thanks for the information with detailed explanation
ReplyDeleteExcellent information
ReplyDelete