Skip to content

Commit

Permalink
SONARJAVA-4200 Fixes from review
Browse files Browse the repository at this point in the history
* Replace reference to SQ version with release season
* Replace "checks" with "rules"
* Link to custom rules
  • Loading branch information
dorian-burihabwa-sonarsource committed Mar 25, 2022
1 parent 85862bc commit a619258
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions sonar-java-plugin/src/main/resources/static/documentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,14 +73,14 @@ If needed, it is possible to run the parsing file by file by setting `sonar.java
More details can be found [here](https://github.com/SonarSource/sonar-java/wiki/Batch-mode).

## Skipping unchanged files
Starting with SonarQube 9.4, and by default, the Java analyzer optimizes the analysis of unchanged files in pull requests.
In practice, this means that on a file that has not changed, the analyzer only runs a restricted list of checks.
Starting from April 2022, and by default, the Java analyzer optimizes the analysis of unchanged files in pull requests.
In practice, this means that on a file that has not changed, the analyzer only runs a restricted list of rules.
To get a better understanding of the rule exclusion mechanism, keep in mind that:
* Rules that need to run on multiple files to decide whether they need to raise issues are always executed
* Rules that need to run at the end of the analysis to decide whether they need to raise issues are always executed
* Rules that are defined out of the `sonar.java.checks` package are always executed

This last criteria implies that checks defined in custom plugins cannot be skipped.
This last criteria implies that [custom rules](https://redirect.sonarsource.com/doc/java-custom-rules-guide.html) cannot be skipped.

If you wish to disable this optimization, you can set the value of the analysis parameter `sonar.java.skipUnchanged` to `false`.
Leaving the parameter untouched is equivalent to having `sonar.java.skipUnchanged` set to `true`.
Expand Down

0 comments on commit a619258

Please sign in to comment.