Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make SAT thread-safe, improve performance and update SpotBugs
This PR makes the SAT Maven plugins thread-safe when used in parallel Maven builds. Fixes the following theading issues: * SpotBugs is only thread-safe when it uses the forking mode which is enabled by default but disabled in the SAT configuration. SpotBugs uses Apache Commons BCEL as dependency which is not thread-safe. Forking the SpotBugs execution works around this issue. Without forking enabled parallel builds using SpotBugs will also lock up (see spotbugs/spotbugs-maven-plugin#104). * Use lock files for synchronizing the SAT summary report updates. Because multiple classloaders are used in Maven builds, it's not possible to use a static lock for synchronization in the ReportUtility Mojo. The Mojos have also been marked as threadSafe so Maven no longer shows warnings when they are executed in parallel. For the SpotBugs updates see: * Spotbugs 3.1.12 release notes: https://github.com/spotbugs/spotbugs/blob/3.1.12/CHANGELOG.md#3112---2019-02-28 * findbugs-slf4j 1.5.0 release notes: https://github.com/KengoTODA/findbugs-slf4j/blob/master/CHANGELOG.md#150---2019-07-04 The errors resulting from the findbugs-slf4j upgrade have already been fixed by: * openhab/openhab-core#1213 * openhab/openhab2-addons#6394 Performance has also been improved considerably by moving the HTML summary generation to an extension. This way SAT can periodically update the HTML summary instead of continuously. Updating the HTML summaries can take 20 seconds or more when there are many findings. Fixes openhab#200 Signed-off-by: Wouter Born <github@maindrain.net>
- Loading branch information