Dynamic Action Plans

The easiest way to instruct Squore to build a dynamic action plan for your model based on the findings generated during an analysis is to ensure that your model folder contains no Decision/Bundle.xml file. A list of the Top 40 valuable actions will be created for the project. This list is shown to all users in the Action Items tab of the Explorer.

Part of the Top 40 valuable actions dynamically generated for a source code project

By default, action items are created based on findings in the project using these criteria:

This can be specified in your Bundle.xml as follows:

$SQUORE_HOME/configuration/MyModelFolder/Decision/Bundle.xml:
<Bundle>
	<FindingsActionPlan limit="40">
		<CategoryCriterion type="COST" scaleId="SCALE_REMEDIATION" preferenceLevel="MEDIUM" excludeLevels="UNKNOWN;NONE" />
		<CategoryCriterion type="BENEFIT" scaleId="SCALE_SEVERITY" preferenceLevel="MEDIUM" excludeLevels="UNKNOWN;INFORMATION" />
		<OccurrencesCriterion type="COST" preferenceLevel="MEDIUM" />
	</FindingsActionPlan>
</Bundle>

Dynamic Action Plan Syntax

The FindingsActionPlan element accepts the following attributes:

There are three types of criteria that you can use to prioritise findings:

Each type of criterion accepts the following attributes:

Here is an example that expands on the default shown earlier to take into account the test coverage of artefacts and make sure that action items are generated mostly for artefacts with a high test coverage ratio. The scale used as well only contains five levels from P1 to P5 and will single out very high and very log priority items (the relevancy of an action item is a number between 0 and 100 that is measured against this scale to define the priority):

$SQUORE_HOME/configuration/MyModelFolder/Decision/Bundle.xml:
<Bundle>
	<FindingsActionPlan limit="40" priorityScaleId="SCALE_LEVEL_FIVE">
		<CategoryCriterion type="COST" scaleId="SCALE_REMEDIATION" preferenceLevel="MEDIUM" excludeLevels="UNKNOWN;NONE" />
		<CategoryCriterion type="BENEFIT" scaleId="SCALE_SEVERITY" preferenceLevel="MEDIUM" excludeLevels="UNKNOWN;INFORMATION" />
		<OccurrencesCriterion type="COST" preferenceLevel="MEDIUM" />
		<VariableCriterion type="BENEFIT" preferenceLevel="VERY_HIGH" indicatorId="TEST_COVERAGE" />
  </FindingsActionPlan>
<Bundle>

Where SCALE_LEVEL_FIVE is:
<Scale scaleId="SCALE_LEVEL_FIVE">
	<ScaleLevel levelId="P0" bounds="[0;5]" rank="0" />
	<ScaleLevel levelId="P1" bounds="]5;15]" rank="1" />
	<ScaleLevel levelId="P2" bounds="]15;65]" rank="2" />
	<ScaleLevel levelId="P3" bounds="]65;85]" rank="3" />
	<ScaleLevel levelId="P4" bounds="]85;95]" rank="4" />
	<ScaleLevel levelId="P5" bounds="]95;100]" rank="5" />
</Scale>