1 <?xml version="1.0" encoding="UTF-8"?>
3 ============LICENSE_START=======================================================
4 Copyright (c) 2021 Pantheon.tech.
5 Modifications Copyright (C) 2021 Bell Canada.
6 Modifications Copyright (C) 2021 Nordix Foundation.
7 ================================================================================
8 Licensed under the Apache License, Version 2.0 (the "License");
9 you may not use this file except in compliance with the License.
10 You may obtain a copy of the License at
12 http://www.apache.org/licenses/LICENSE-2.0
14 Unless required by applicable law or agreed to in writing, software
15 distributed under the License is distributed on an "AS IS" BASIS,
16 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 See the License for the specific language governing permissions and
18 limitations under the License.
19 ============LICENSE_END=========================================================
22 <project xmlns="http://maven.apache.org/POM/4.0.0"
23 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
24 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
26 <groupId>org.onap.oparent</groupId>
27 <artifactId>oparent</artifactId>
28 <version>3.2.0</version>
31 <modelVersion>4.0.0</modelVersion>
33 <groupId>org.onap.cps</groupId>
34 <artifactId>cps-parent</artifactId>
35 <version>1.1.0-SNAPSHOT</version>
36 <packaging>pom</packaging>
39 <app>org.onap.cps.Application</app>
40 <docker.repository.push>nexus3.onap.org:10003/</docker.repository.push>
41 <docker.repository.pull>nexus3.onap.org:10001/</docker.repository.pull>
42 <java.version>11</java.version>
43 <jsonschema2pojo-maven-plugin.version>1.1.1</jsonschema2pojo-maven-plugin.version>
44 <minimum-coverage>0.9</minimum-coverage>
45 <nexusproxy>https://nexus.onap.org</nexusproxy>
46 <oparent.version>3.1.0</oparent.version>
47 <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
48 <releaseNexusPath>/content/repositories/releases/</releaseNexusPath>
49 <snapshotNexusPath>/content/repositories/snapshots/</snapshotNexusPath>
50 <spotbugs-maven-plugin.version>4.1.3</spotbugs-maven-plugin.version>
51 <spotbugs.slf4j.version>1.8.0-beta4</spotbugs.slf4j.version>
52 <spotbugs.bug-pattern.version>1.5.0</spotbugs.bug-pattern.version>
53 <spotbugs.version>4.2.0</spotbugs.version>
54 <spring-boot-maven-plugin.version>2.3.3.RELEASE</spring-boot-maven-plugin.version>
55 <swagger-codegen-maven-plugin.version>3.0.18</swagger-codegen-maven-plugin.version>
57 <jacoco.reportDirectory.aggregate>${project.reporting.outputDirectory}/jacoco-aggregate</jacoco.reportDirectory.aggregate>
58 <sonar.coverage.jacoco.xmlReportPaths>
59 ../cps-ri/target/site/jacoco-ut/jacoco.xml,
60 ../cps-ri/target/site/jacoco-aggregate/jacoco.xml,
61 ../cps-service/target/site/jacoco-ut/jacoco.xml,
62 ../cps-service/target/site/jacoco-aggregate/jacoco.xml,
63 ../cps-rest/target/site/jacoco-ut/jacoco.xml,
64 ../cps-rest/target/site/jacoco-aggregate/jacoco.xml,
65 ../cps-ncmp-service/target/site/jacoco-ut/jacoco.xml,
66 ../cps-ncmp-service/target/site/jacoco-aggregate/jacoco.xml,
67 ../cps-ncmp-rest/target/site/jacoco-ut/jacoco.xml,
68 ../cps-ncmp-rest/target/site/jacoco-aggregate/jacoco.xml,
69 ../cps-path-parser/target/site/jacoco-ut/jacoco.xml,
70 ../cps-path-parser/target/site/jacoco-aggregate/jacoco.xml,
71 ../cps-application/target/site/jacoco-ut/jacoco.xml,
72 ../cps-application/target/site/jacoco-aggregate/jacoco.xml
73 </sonar.coverage.jacoco.xmlReportPaths>
76 <distributionManagement>
78 <id>ecomp-releases</id>
79 <name>ECOMP Release Repository</name>
80 <url>${nexusproxy}${releaseNexusPath}</url>
83 <id>ecomp-snapshots</id>
84 <name>ECOMP Snapshot Repository</name>
85 <url>${nexusproxy}${snapshotNexusPath}</url>
87 </distributionManagement>
89 <dependencyManagement>
92 <groupId>org.onap.cps</groupId>
93 <artifactId>cps-dependencies</artifactId>
94 <version>${project.version}</version>
99 <groupId>org.onap.cps</groupId>
100 <artifactId>cps-bom</artifactId>
101 <version>${project.version}</version>
103 <scope>import</scope>
106 </dependencyManagement>
111 <directory>src/main/resources</directory>
112 <filtering>true</filtering>
115 <directory>target/generated-sources/license</directory>
117 <include>third-party-licenses.txt</include>
121 <directory>target/generated-resources/licenses</directory>
123 <include>*.*</include>
125 <targetPath>third-party-licenses</targetPath>
131 <groupId>org.springframework.boot</groupId>
132 <artifactId>spring-boot-maven-plugin</artifactId>
133 <version>${spring-boot-maven-plugin.version}</version>
137 <goal>build-info</goal>
138 <goal>repackage</goal>
143 <!-- Swagger code generation. -->
145 <groupId>io.swagger.codegen.v3</groupId>
146 <artifactId>swagger-codegen-maven-plugin</artifactId>
147 <version>${swagger-codegen-maven-plugin.version}</version>
150 <groupId>com.github.spotbugs</groupId>
151 <artifactId>spotbugs-maven-plugin</artifactId>
152 <version>${spotbugs-maven-plugin.version}</version>
155 <groupId>com.github.spotbugs</groupId>
156 <artifactId>spotbugs</artifactId>
157 <version>${spotbugs.version}</version>
160 <groupId>${project.groupId}</groupId>
161 <artifactId>spotbugs</artifactId>
162 <version>${project.version}</version>
165 <!-- The SpotBugs Maven plugin uses SLF4J 1.8 beta 2 -->
166 <groupId>org.slf4j</groupId>
167 <artifactId>slf4j-simple</artifactId>
168 <version>${spotbugs.slf4j.version}</version>
174 <groupId>jp.skypencil.findbugs.slf4j</groupId>
175 <artifactId>bug-pattern</artifactId>
176 <version>1.5.0</version>
180 Enables analysis which takes more memory but finds more bugs.
181 If you run out of memory, changes the value of the effort element
184 <addSourceDirs>true</addSourceDirs>
186 <!-- Reports all bugs (other values are medium and max) -->
187 <threshold>Low</threshold>
188 <!-- Build doesn't fail if problems are found -->
189 <failOnError>true</failOnError>
190 <!-- References the excluded rules -->
191 <excludeFilterFile>spotbugs-exclude.xml</excludeFilterFile>
192 <!-- Produces XML report -->
193 <xmlOutput>true</xmlOutput>
194 <!-- Configures the directory in which the XML report is created -->
195 <xmlOutputDirectory>${project.build.directory}/spotbugs</xmlOutputDirectory>
199 Ensures that SpotBugs inspects source code when project is compiled.
202 <id>analyze-compile</id>
203 <phase>compile</phase>
211 <groupId>org.jsonschema2pojo</groupId>
212 <artifactId>jsonschema2pojo-maven-plugin</artifactId>
213 <version>${jsonschema2pojo-maven-plugin.version}</version>
215 <targetVersion>${java.version}</targetVersion>
220 <goal>generate</goal>
229 <groupId>org.apache.maven.plugins</groupId>
230 <artifactId>maven-compiler-plugin</artifactId>
232 <source>${java.version}</source>
233 <target>${java.version}</target>
237 <groupId>org.apache.maven.plugins</groupId>
238 <artifactId>maven-checkstyle-plugin</artifactId>
241 <id>onap-license</id>
245 <phase>process-sources</phase>
247 <configLocation>onap-checkstyle/check-license.xml</configLocation>
248 <includeResources>false</includeResources>
249 <includeTestSourceDirectory>true</includeTestSourceDirectory>
250 <includeTestResources>false</includeTestResources>
252 <sourceDirectory>${project.build.sourceDirectory}</sourceDirectory>
254 <consoleOutput>false</consoleOutput>
255 <violationSeverity>warning</violationSeverity>
256 <failOnViolation>true</failOnViolation>
260 <id>onap-java-style</id>
264 <phase>process-sources</phase>
266 <configLocation>onap-checkstyle/onap-java-style.xml</configLocation>
268 <sourceDirectory>${project.build.sourceDirectory}</sourceDirectory>
270 <includeResources>true</includeResources>
271 <includeTestSourceDirectory>true</includeTestSourceDirectory>
272 <includeTestResources>true</includeTestResources>
273 <consoleOutput>false</consoleOutput>
274 <violationSeverity>warning</violationSeverity>
275 <failOnViolation>true</failOnViolation>
279 <id>cps-java-style</id>
283 <phase>process-sources</phase>
285 <configLocation>cps-java-style.xml</configLocation>
287 <sourceDirectory>${project.build.sourceDirectory}</sourceDirectory>
289 <includeResources>true</includeResources>
290 <includeTestSourceDirectory>true</includeTestSourceDirectory>
291 <includeTestResources>true</includeTestResources>
292 <consoleOutput>true</consoleOutput>
293 <violationSeverity>warning</violationSeverity>
294 <failOnViolation>true</failOnViolation>
300 <groupId>org.onap.oparent</groupId>
301 <artifactId>checkstyle</artifactId>
302 <version>${oparent.version}</version>
305 <groupId>${project.groupId}</groupId>
306 <artifactId>checkstyle</artifactId>
307 <version>${project.version}</version>
311 <!-- Mandatory plugins for using Spock -->
313 <!-- The gmavenplus plugin is used to compile Groovy code.
314 To learn more about this plugin, visit https://github.com/groovy/GMavenPlus/wiki -->
315 <groupId>org.codehaus.gmavenplus</groupId>
316 <artifactId>gmavenplus-plugin</artifactId>
317 <version>1.9.0</version>
321 <goal>compileTests</goal>
326 <!-- Required because names of spec classes don't match default
327 Surefire patterns (`*Test` etc.) -->
329 <groupId>org.apache.maven.plugins</groupId>
330 <artifactId>maven-surefire-plugin</artifactId>
332 <!--suppress UnresolvedMavenProperty -->
333 <argLine>${surefireArgLine}</argLine>
334 <useFile>false</useFile>
336 <include>**/*Spec.java</include>
337 <include>**/*Test.java</include> <!-- Just in case of having also "normal" JUnit tests -->
340 <exclude>**/IT*.java</exclude>
342 <environmentVariables>
344 disable privileged container usage to cleanup the test containers;
345 these will be removed automatically on jvm termination;
346 see https://www.testcontainers.org/features/configuration/#disabling-ryuk
348 <TESTCONTAINERS_RYUK_DISABLED>true</TESTCONTAINERS_RYUK_DISABLED>
349 <TESTCONTAINERS_HUB_IMAGE_NAME_PREFIX>${docker.repository.pull}library/</TESTCONTAINERS_HUB_IMAGE_NAME_PREFIX>
350 </environmentVariables>
354 <groupId>org.jacoco</groupId>
355 <artifactId>jacoco-maven-plugin</artifactId>
358 <exclude>org/onap/cps/rest/model/*</exclude>
359 <exclude>org/onap/cps/cpspath/parser/antlr4/*</exclude>
364 <id>default-prepare-agent</id>
366 <goal>prepare-agent</goal>
370 <id>coverage-check</id>
375 <dataFile>${project.build.directory}/code-coverage/jacoco-ut.exec</dataFile>
378 <element>BUNDLE</element>
381 <counter>INSTRUCTION</counter>
382 <value>COVEREDRATIO</value>
383 <minimum>${minimum-coverage}</minimum>
393 <goal>report-aggregate</goal>
395 <phase>verify</phase>
398 <fileInclude>**/code-coverage/jacoco-ut.exec</fileInclude>
405 <groupId>com.github.spotbugs</groupId>
406 <artifactId>spotbugs-maven-plugin</artifactId>
409 <groupId>org.sonarsource.scanner.maven</groupId>
410 <artifactId>sonar-maven-plugin</artifactId>