Anypoint Studio - Rules Playground
Rules Playground is a tool for quick and easy development of Custom Rules
Rules Playground functionality is part of Anypoint Studio plugin. Refer to Installing Anypoint Studio plugin for more information.
Features
Develop/Create a custom rule definition and evaluate against the project
Provides feedback about any syntax errors in the rule definition
Capability to evaluate the rule definition on Mule components, APIs, property files, pom.xml, etc.
Publish the rule definition to the configured server and activate it
Custom Rule Editor
Click on
Window->Show View->Other->IZ Scan->Custom Rule EditorCustom rule editor properties -
Rule Name- Name of the new custom ruleType- Select the type of rule, which can be one ofCode Smell
Bug
Vulnerability
Security Hotspot
Severity- Select the rule severity, which can be one ofBlocker
Critical
Major
Minor
Info
Rule Definition- Groovy definition for the custom rule
Evaluating Custom Rule
Click on
Evaluate Rulebutton to validate and execute the rule definitionCustom rule will be applied on the current project and results will be displayed in
Evaluation ResultssectionResults in case of valid rule definition

Results in case of syntax errors in the rule definition

Publishing Custom Rule
Before publishing a custom rule, make sure you have:
Created a custom Quality Profile from the default Profile.
Appropriate access in the server to publish the rule.
Expand the
Publish RulesectionEnter the Rule Key and Description -
Key- Unique key for the custom rule. The key will be auto populated, which can be changed if there are any conflictsDescription- Description of the rule. Markdown syntax can be used to describe the rule
Click on
Publish Ruleto upload the rule to the configured server. Rule will be activated in the selected Quality Profile.
See Also
Last updated
Was this helpful?

