Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 53 Next »

These parameters can be set while analyzing projects. They can be defined in the Maven pom, in the Ant task or in command-line parameters



Default value



Sometimes, for security or other reasons, project sources must not be stored and displayed.


since 1.5


It becomes quickly necessary to input historical data and to highlight some events. It is possible by going for example in a subversion tag and use the sonar.projectDate option. Format is yyyy-MM-dd, for example 2010-12-25.

Current date

since 1.5


The project version, usually overridden when sonar.projectDate is set

Version as defined in project

since 1.5


Sets the language of source code. By default, Sonar is using Java source code analysers. If a Sonar plugin allows to analyse another given language, the associated source code analysers can be activated with the property 'sonar.language'.


since 2.0


Exclude files from analysis. This property is usually set in the page Settings of the project. It's a comma separated list of wildcard patterns. Paths are defined from the source base directory. Example: com/mycompany/*/.java,**/*


since 1.8


Some project modules should not be analyzed and consolidated with global project measures, for instance samples, integration tests or generated code.
If a module's artifactId differs from its module name (the directory name) : it is the artifactId that should be use instead of the module name. Format is a comma-separated list of modules : module1_toexclude,module2_toexclude.


since 1.5


Comma-separated list of the modules to analyse, all others modules are automatically ignored. Be careful : the root project must be added to the list.
If a module's artifactId differs from its module name (the directory name) : it is the artifactId that should be use instead of the module name.


since 2.2


Manage SCM branches. Two branches of the same project are considered as different projects in Sonar.


since 1.10


Through the Sonar web interface, you can define as many quality profiles as you want and you can easily associate one of this quality profile to a given project. You can also make this association by using the property "sonar.profile". The value of this property overload any configuration made in the Sonar web interface.


since 1.6


Deactivate Java bytecode analysis. Since Sonar 2.0, the java bytecode is analyzed by Sonar in order to extract dependencies between packages and files. Those dependencies are used for instance to display the DSM (Dependency System Matrix). This bytecode analysis can be deactivated.


since 2.0


Run maven phase or goal prior to analysis. When Sonar needs a phase or maven goal to be executed prior to analysis, this parameter can be used. For example sonar.phase=generate-sources. This property is used only for Maven analysis.


since 1.10 and

Increasing HTTP timeouts of requests to Sonar server. The Maven plugin executes some HTTP requests to the Sonar server. Two timeouts makes the call fail if the server connection is too slow. In such a case the timeouts can be increased from Maven properties.

respectively 30'000 and 60'000 milliseconds

since 1.12


Sonar has an embedded purge mechanism which is fairly powerful to avoid keeping useless data. This mechanism is using a minimum period during which a resource created should not be suppressed whatever its state. This is set by default to 12 hours and should not be changed. The only situation you could want to change this is in case a projects takes more than 12 hours to be analyzed by Sonar.


since 2.4


Enables to reuse Findbugs report that has already been generated.


since 2.3

Dynamic analysis



Default value



Dynamic analysis relates to unit tests. By default, those unit tests are executed but you can optionally decide to do only static analysis or to reuse existing reports which have been previously generated. Possible values are true, false, reuseReports.


since 1.7


The absolute or relative path of the surefire reports directory. Used only if sonar.dynamicAnalysis is reuseReports.


since 1.7


The absolute or relative path of the cobertura xml report file. Used only if sonar.dynamicAnalysis is reuseReports.


since 1.7


The absolute or relative path of the clover xml report file. Used only if sonar.dynamicAnalysis is reuseReports.


since 1.7

  • No labels