Support Article
Performance degrades after update to Pega 7.2.1 (RUF Assembly)
Summary
After updating their Pega 7.x systems to Pega 7.2.1 (with Oracle JRE 1.8), users see performance degradation during a load test. Their analysis finds that the database table <rule schema>.pz_assembledclasses is updated for each Service REST invocation. This degrades performance.
To perform their root cause analysis, the users ran the following query, which shows the updates to the <rule schema>.pr_assembledclasses table for the Pega-RULES:DecisionTable and the Pega-RULES:Sort libraries.
select * from <rule schema>.pr_assembledclasses where pzpackage = 'com/pegarules/generated' and pzclass in ( 'pega_rules_decisiontable.class', 'pega_rules_sort.class')
Error Messages
Not Applicable
Steps to Reproduce
- Query the <rule schema>.pz_assembledclasses table and sort by the pzLastModified column in descending order.
Note the record and value of the pzLastModified column. - Invoke the Service REST rule that references a library function rule.
This can be any operation, not just the Service REST calls. - Query the <rule schema>.pz_assembledclasses table and sort by the pzLastModified column in descending order.
- Unless there is a rule change, there should be no change in the pzLastModified value returned rows compared to the value returned by the query in Step 1.
Root Cause
A defect in Pegasystems’ code or rules
There is an unnecessary library compilation by the SORT action in the Data Transform rule. The expected behavior is that, unless there are changes in the library or function rules, the library rule should not be assembled and compiled for an invocation; it should use the existing assembled version of the rule.
In the case reported here, for each Service REST invocation, the library is compiled and stored in the database. This causes performance to degrade and get worse, depending on the number of nodes. The more nodes, the greater the performance degradation.
You can see this in the <rule schema>.pz_assembledclasses table, where the assembled rules are saved and the pzLastModified column is changing for each invocation, indicating that the rule is being repeatedly assembled and saved.
Resolution
Update or upgrade to the latest release of the Pega Platform.
If you cannot update or upgrade your Pega deployment, apply HFix-31073.
You must restart the JVM for the hotfix to take effect.
See also Pega 7.2.2 SA-32475, https://pdn.pega.com/support-articles/performance-degrades-after-update-pega-722-ruf-assembly.
Published April 26, 2018 - Updated October 8, 2020
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.