yesamer opened a new pull request, #6634:
URL: https://github.com/apache/incubator-kie-drools/pull/6634
Summary of Changes in This PR
- Removed the kie-build-tools dependency from the SpotBugs configuration. It
points to an old external module, and version 999-SNAPSHOT is no longer
available, which breaks dependency resolution.
- Removed references to missing SpotBugs exclude filter files. These
references pointed to files that no longer exist and to the kie-build-tools JAR.
- Upgraded the spotbugs-maven-plugin.
- Fixed a potential NullPointerException detected by the
`spotbugs-maven-plugin`.
As a follow-up, we could agree to enable the `spotbugs-maven-plugin` in this
project’s submodules (namely `drools-base`, `drools-compiler`, `drools-core`,
and `drools-drl-parser` that already declare it) so that the build fails when
SpotBugs detects any issues at compile time.
It appears there was already an intention to enable this behavior in the
past, since the following configuration is present in the Drools build-parent
POM:
```
<!-- Set to "true" on every project that has no violations. -->
<spotbugs.failOnViolation>false</spotbugs.failOnViolation>
```
To enable this in specific submodules, we should:
1. In the target submodule’s pom.xml, set spotbugs.failOnViolation to true
under <properties>.
2. Keep the spotbugs-maven-plugin execution bound to the verify phase, with
both the spotbugs and check goals enabled:
```
<plugin>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<executions>
<execution>
<id>spotbugs</id>
<phase>verify</phase>
<goals>
<goal>spotbugs</goal>
<goal>check</goal>
</goals>
</execution>
</executions>
</plugin>
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]