Anypoint Studio Analysis
Code Analysis in Studio
Before analyzing the source code in Studio, make sure you have either:
Installed IZ Scan - Anypoint Studio Plugin
Configured the plugin either for:
On The Fly Results
On The Fly Results table/view will display the issues related to the project that the user is working on. Project is determined based on the current active file (i.e., the file that the user is working on) in Anypoint Studio.
Issues will be detected and reported as and when the connectors are configured in the editor. With this, the issues can be fixed even before they exist.
Follow the steps below to explore On The Fly Results view.
Go to
Window->Show View->other->IZ Scan-> selectOn the Fly Results
Open any mule project xml, the issues will be automatically detected and the results can be seen in
On the Fly Resultspanel.NOTE:
On The Fly Resultsscans the whole project corresponding to current mule project xml and displays the results

On The Fly Results Tab Features
The Results tab provides options such as start or stop analysis, sync rules from the server, reload on the fly results, and helps us to quickly sort through the results based on file type, component type, and severity.
Navigate to
Window->Show View->other->IZ Scan-> selectOn the Fly Results. The options are displayed at the top right corner.
By default, the analysis is active and will immediately report any issues it sees fit. Clicking on the
Stop Buttonwill stop the analysis. You can start it at a later time once a part of your development is completed.
Your organization might have added new rules or updated the rules in server. By clicking on the
Sync Rulesoption, you will be importing these updated rules onto Anypoint studio.
By Clicking on
Reload on the fly resultsoption, your project will be validated against the rules to refresh the tab so as to display any new issues along with the previously displayed issues.
The Issues seen in the On The Fly Results tab can be grouped based on file type, component type and severity.
Grouping based on
File Type.
Grouping based on
Component Type.
Grouping based on
Severity.
== Issue Fix Recommendation
On The Fly Results precisely point out the problem in each file with line number, but many users might not be aware of the issue fix.
Issue fix recommendation helps to deal with this scenario with a detailed description and examples on how to fix the issue.
Double-click on any issue that needs a fix to open up the
Rule Descriptionview.
Rule Descriptionview provides information about:Type of Issue. E.g.:
Code Smell,BugDetailed description of the violated rule/issue
Noncompliant Code Example
Compliant Code Example, which guides developers on how to fix the issue
Optionally, an external link to any official documentation for further information about the fix
Upload to Server
After development is complete, users might want to upload the project to the server and save the analysis results or for any other purposes.
IZ Analyzer provides an easy option to upload a project to the server from Anypoint Studio.
This step assumes that the server details are configured well in advance as mentioned in Installing Studio Plugin SonarQube version 9.x and above requires Java version 11 to scan the projects. It is recommended to use Anypoint Studio version greater than 7.9.0 to use this feature with the latest versions of SonarQube.
Right-click on the project that needs to be uploaded to the server, then click on
IZ Scan - Server Upload
Fill in the values required for server upload and click on
Finish:Project Key - Unique key of the project
Project Name - Display name of the project
Project version - Version of the project
Detailed logs of upload/scanner process will be displayed in
consoleview
Results of analysis can be further explored in web application dashboard

See Also
Last updated
Was this helpful?

