Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Blueriq Model Analyzer(BMA) is designed to evaluate Blueriq Models and assess its maintainability and quality. The Model Analyzer is developed to work with the well known code quality platform called SonarQube. The BMA itself is a SonarQube plugin which will run inside SonarQube.

 

 

Software requirements

...

Table of Contents

 

...

How does it work

SonarQube uses indexed folders and files of a project to assign issues and measures on. With a Java or C# project the source directory is scanned and indexed into SonarQube. After the files have been indexed an analyzer is run to scan the files for issues and collects its measures. Since Blueriq doesn't work with a source directory but with a branch export from the Management Service, we need to create our own folder structure. Therefore a property needs to be set sonar.blueriq.workingDir, where the BMA can create a folder structure that represents a blueriq project structure. This includes the repository and branch.

...

The Blueriq Model Analyzer is capable of calculating the following measures:

Measure
Explanation
Number of modulesCounts the number of modules in you Blueriq Model.
Number of reusable expressions Counts the number of reusable expressions in your Blueriq Model.
Number complex expressionCounts the number of complex expressions in you Blueriq Model.

You can view the measures of your Blueriq Model by clicking the Measures tab in the upper left corner of your screen, calculated measures are shown at the bottom of the screen:

...

The Blueriq Model Analyzer is capable of detecting the following issues:

Rule
Explanation
Elements in flowThis rule counts the number of elements within one flow and reports back an issue when the configured maximum number of elements is exceeded. It is recommended for maintainability issues, to keep the number of elements in flows below this maximum, otherwise the flow is seen as complex.
Flow viewportThis rule calculates whether or not your flow can be displayed on a standard screen. If not, you are advised to refactor for maintainability reasons.
Included library in projectThis rule searches for libraries in your Blueriq Model and reports back an issue when unused libraries are found. In case a library is connected to the project its modules should be used in the project. If it is connected, but not used the rule will trigger. However, there is an exception: there are libraries that does not contain modules, e.g. the AquimaLibrary which only uses globals. So this rule checks also if a library uses global elements.
DiamondThis rule checks whether modules are configured in such a way that a diamond, i.e. a closed circuit occurs in your Blueriq Model. If so, it is advised to refactor your model on this. From a modeling point of view this module structure could be curious. Additionally the model can behave unexpected in case specialization is used.
Expression duplicatesDetects duplicate expressions per module, considering all modules in scope. This is an indication that expressions have to be maintained in multiple places which is bad for maintainability reasons.
Reusable expression duplicatesThis rule checks whether a reusable expression is duplicated somewhere in your Blueriq Model, even across modules within a project which are not in each other's scope.
Gaps in Decision TableThis rule compares all conditions in a decision table for gaps between conditions. If there is a gap between two conditions an issue will be created. An issue can consist out of multiple warnings since multiple gaps may exist in a decision table.
Simplify ExpressionThis rule checks whether boolean logic in an expression can be simplified. If so, the simplified expression is reported as issue.

You can view the issues of your Blueriq Model by clicking the Issues tab in the upper left corner of your screen:

...