Skip to main content

         This documentation site is for previous versions. Visit our new documentation site for current releases.      

This content has been archived and is no longer being updated.

Links may not function; however, this content may be relevant to outdated versions of the product.

More about Harnesses

Updated on April 5, 2022

Use harnesses to define the appearance and processing of user forms used in your application to create work items and process assignments.

Linked property references

For fields that are always displayed as read-only, you can enter a linked property reference, of the form .AAAA.BBBB, where AAAA is the linked property and BBBB is any property reference in the object identified by the value of AAAA as a key.

For example, if the property AAAA has a value corresponding to a key of a Data-Admin-Operator-ID instance, then .AAAA.pyUserName presents that Operator ID's full name.

This allows values from that object to display (read-only) in the run-time display of the section, although your processing does not explicitly load the object onto the clipboard.

Activities and clipboard page names

Use the standard activity @baseclass.Show-Harness to display harness forms. This activity and the standard harnesses expect to find (by convention) objects on the following page names:

  • pyWorkPage — Conventional name for the page that contains a work item. This page usually has a class derived from the Work-Object- class.
  • pyWorkCover — Conventional name for the page that contains a covering work item, if one exists. This page has a class derived from the Work-Cover- class.
  • NewAssignPag — Conventional name for the page that contains an assignment object. This page has a class derived from the Assign- base class.
Note: These page name conventions do not apply to applications that do not depend on harnesses, because the work item page can have any name established in the flow.

You can view the generated Java code of a rule by clicking ActionsView Java. You can use this code to debug your application or to examine how rules are implemented.

Preview and Run

After you save this rule form, select the Preview toolbar action to see a more faithful split-screen presentation of the runtime appearance of the harness.

Note: Many harnesses depend on context. Even when the rule is correctly configured, the Preview display may fail and report JSP errors if this harness depends on clipboard contents that do not exist or other rules that cannot be found.

Select the Run toolbar action to test the harness with data from the clipboard.

As with the Layout tab, the system renders both the Preview and Run displays using the styles of the skin rule identified in the Using skinpreference. If the Using skin field is blank, these displays use the styles marked Work on the Styles tab of the skin identified in your current portal rule.

Parent class

Through directed inheritance, the immediate parent class of the Rule-HTML-Harness class is the Rule-Obj-HTML class.


If your application rulesets contain harnesses that are not auto-generated, run the Rule Security Analyzer before locking a ruleset version, to look for possible security issues.

  • JavaServer Pages tags
  • Stream processing of JSP tags
  • Rule Security Analyzer

    To make Pega Platform applications more secure, you can run the Rule Security Analyzer. This tool searches through non-autogenerated rules to find specific JavaScript or SQL coding patterns that match regular expression rules, some of which might indicate security vulnerabilities, as detailed below.

  • Unit testing a Service SOAP rule

    Services start their processing in response to a request from an external application. Before you add the external application to your testing process, use the Simulate SOAP Service Execution feature to verify that the service processes data appropriately. When using this feature, you manually provide some representative data to process. You specify a test page for the rule to use, provide sample data as the input, run the rule, and examine the results to see if they are what you expect.

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best. is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us