diff options
Diffstat (limited to 'cps-parent')
-rw-r--r-- | cps-parent/pom.xml | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/cps-parent/pom.xml b/cps-parent/pom.xml index 55db1a198e..1f6ae2c8c7 100644 --- a/cps-parent/pom.xml +++ b/cps-parent/pom.xml @@ -26,7 +26,11 @@ <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <releaseNexusPath>/content/repositories/releases/</releaseNexusPath> <repository.name>nexus3.onap.org:10001/onap/cps-service</repository.name> + <spotbugs-maven-plugin.version>4.1.3</spotbugs-maven-plugin.version> <spring-boot-maven-plugin.version>2.3.3.RELEASE</spring-boot-maven-plugin.version> + <spotbugs.slf4j.version>1.8.0-beta4</spotbugs.slf4j.version> + <spotbugs.bug-pattern.version>1.5.0</spotbugs.bug-pattern.version> + <spotbugs.version>4.2.0</spotbugs.version> <swagger-codegen-maven-plugin.version>3.0.18</swagger-codegen-maven-plugin.version> <snapshotNexusPath>/content/repositories/snapshots/</snapshotNexusPath> <tag.version>${project.version}</tag.version> @@ -197,6 +201,66 @@ </to> </configuration> </plugin> + <plugin> + <groupId>com.github.spotbugs</groupId> + <artifactId>spotbugs-maven-plugin</artifactId> + <version>${spotbugs-maven-plugin.version}</version> + <dependencies> + <dependency> + <groupId>com.github.spotbugs</groupId> + <artifactId>spotbugs</artifactId> + <version>${spotbugs.version}</version> + </dependency> + <dependency> + <groupId>${project.groupId}</groupId> + <artifactId>spotbugs</artifactId> + <version>${project.version}</version> + </dependency> + <dependency> + <!-- The SpotBugs Maven plugin uses SLF4J 1.8 beta 2 --> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>${spotbugs.slf4j.version}</version> + </dependency> + </dependencies> + <configuration> + <plugins> + <plugin> + <groupId>jp.skypencil.findbugs.slf4j</groupId> + <artifactId>bug-pattern</artifactId> + <version>1.5.0</version> + </plugin> + </plugins> + <!-- + Enables analysis which takes more memory but finds more bugs. + If you run out of memory, changes the value of the effort element + to 'Low'. + --> + <effort>Max</effort> + <!-- Reports all bugs (other values are medium and max) --> + <threshold>Low</threshold> + <!-- Build doesn't fail if problems are found --> + <failOnError>false</failOnError> + <!-- References the excluded rules --> + <excludeFilterFile>spotbugs-exclude.xml</excludeFilterFile> + <!-- Produces XML report --> + <xmlOutput>true</xmlOutput> + <!-- Configures the directory in which the XML report is created --> + <xmlOutputDirectory>${project.build.directory}/spotbugs</xmlOutputDirectory> + </configuration> + <executions> + <!-- + Ensures that SpotBugs inspects source code when project is compiled. + --> + <execution> + <id>analyze-compile</id> + <phase>compile</phase> + <goals> + <goal>check</goal> + </goals> + </execution> + </executions> + </plugin> </plugins> </pluginManagement> <plugins> @@ -360,6 +424,10 @@ </execution> </executions> </plugin> + <plugin> + <groupId>com.github.spotbugs</groupId> + <artifactId>spotbugs-maven-plugin</artifactId> + </plugin> </plugins> </build> </project>
\ No newline at end of file |