blob: 49dce9f844a7381ff11f30f575ac9f2e46a61736 [file] [log] [blame]
Bruno Sakoto4a56deb2021-02-17 17:26:33 -05001<?xml version="1.0" encoding="UTF-8"?>
2<!--
3 ============LICENSE_START=======================================================
4 Copyright (c) 2021 Bell Canada.
5 ================================================================================
6 Licensed under the Apache License, Version 2.0 (the "License");
7 you may not use this file except in compliance with the License.
8 You may obtain a copy of the License at
9
10 http://www.apache.org/licenses/LICENSE-2.0
11
12 Unless required by applicable law or agreed to in writing, software
13 distributed under the License is distributed on an "AS IS" BASIS,
14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 See the License for the specific language governing permissions and
16 limitations under the License.
17 ============LICENSE_END=========================================================
18-->
19
20<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
21 xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
22 <modelVersion>4.0.0</modelVersion>
Bruno Sakoto472d2e82021-02-25 23:23:09 -050023
Bruno Sakoto4a56deb2021-02-17 17:26:33 -050024 <parent>
Bruno Sakoto472d2e82021-02-25 23:23:09 -050025 <groupId>org.onap.oparent</groupId>
26 <artifactId>oparent</artifactId>
27 <version>3.2.0</version>
28 <relativePath/>
Bruno Sakoto4a56deb2021-02-17 17:26:33 -050029 </parent>
Bruno Sakoto472d2e82021-02-25 23:23:09 -050030
Bruno Sakoto4a56deb2021-02-17 17:26:33 -050031 <groupId>org.onap.cps</groupId>
32 <artifactId>cps-temporal</artifactId>
33 <version>0.0.1-SNAPSHOT</version>
34 <name>cps-temporal</name>
35 <description>CPS Temporal Service</description>
Bruno Sakoto472d2e82021-02-25 23:23:09 -050036
Bruno Sakoto4a56deb2021-02-17 17:26:33 -050037 <properties>
38 <java.version>11</java.version>
Bruno Sakoto472d2e82021-02-25 23:23:09 -050039 <minimum-coverage>0.8</minimum-coverage>
puthuparambil.aditya2bd625b2021-04-27 11:39:32 +010040 <cps.checkstyle.version>1.0.1</cps.checkstyle.version>
41 <cps.spotbugs.version>1.0.1</cps.spotbugs.version>
42 <oparent.version>3.2.0</oparent.version>
43 <spotbugs-maven-plugin.version>4.1.3</spotbugs-maven-plugin.version>
44 <spotbugs.slf4j.version>1.8.0-beta4</spotbugs.slf4j.version>
45 <spotbugs.version>4.2.0</spotbugs.version>
Bruno Sakoto4a56deb2021-02-17 17:26:33 -050046 </properties>
Bruno Sakoto472d2e82021-02-25 23:23:09 -050047
48 <dependencyManagement>
49 <dependencies>
50 <dependency>
51 <groupId>org.springframework.boot</groupId>
52 <artifactId>spring-boot-dependencies</artifactId>
53 <version>2.3.8.RELEASE</version>
54 <type>pom</type>
55 <scope>import</scope>
56 </dependency>
57 <dependency>
58 <groupId>org.spockframework</groupId>
59 <artifactId>spock-bom</artifactId>
60 <version>2.0-M4-groovy-3.0</version>
61 <type>pom</type>
62 <scope>import</scope>
63 </dependency>
64 </dependencies>
65 </dependencyManagement>
66
Bruno Sakoto4a56deb2021-02-17 17:26:33 -050067 <dependencies>
68 <dependency>
69 <groupId>org.springframework.boot</groupId>
70 <artifactId>spring-boot-starter</artifactId>
71 </dependency>
72 <dependency>
73 <groupId>org.springframework.boot</groupId>
74 <artifactId>spring-boot-starter-web</artifactId>
75 </dependency>
Bruno Sakoto05855d52021-04-20 08:22:56 -040076 <dependency>
77 <groupId>org.springframework.boot</groupId>
78 <artifactId>spring-boot-starter-data-jpa</artifactId>
79 </dependency>
80 <dependency>
81 <groupId>org.liquibase</groupId>
82 <artifactId>liquibase-core</artifactId>
83 <version>4.3.2</version>
84 </dependency>
85 <!-- Runtime dependencies-->
86 <dependency>
87 <groupId>org.postgresql</groupId>
88 <artifactId>postgresql</artifactId>
89 <scope>runtime</scope>
90 </dependency>
Bruno Sakoto472d2e82021-02-25 23:23:09 -050091 <!-- Test dependencies-->
92 <dependency>
93 <groupId>org.codehaus.groovy</groupId>
94 <artifactId>groovy</artifactId>
95 <version>3.0.7</version>
96 </dependency>
Bruno Sakoto4a56deb2021-02-17 17:26:33 -050097 <dependency>
98 <groupId>org.springframework.boot</groupId>
99 <artifactId>spring-boot-starter-test</artifactId>
100 <scope>test</scope>
101 <exclusions>
102 <exclusion>
103 <groupId>org.junit.vintage</groupId>
104 <artifactId>junit-vintage-engine</artifactId>
105 </exclusion>
106 </exclusions>
107 </dependency>
Bruno Sakoto472d2e82021-02-25 23:23:09 -0500108 <dependency>
109 <groupId>org.spockframework</groupId>
110 <artifactId>spock-core</artifactId>
111 <scope>test</scope>
112 </dependency>
Bruno Sakoto05855d52021-04-20 08:22:56 -0400113 <dependency>
114 <groupId>org.testcontainers</groupId>
115 <artifactId>junit-jupiter</artifactId>
116 <version>1.15.2</version>
117 <scope>test</scope>
118 </dependency>
119 <dependency>
120 <groupId>org.testcontainers</groupId>
121 <artifactId>postgresql</artifactId>
122 <version>1.15.2</version>
123 <scope>test</scope>
124 </dependency>
Bruno Sakoto4a56deb2021-02-17 17:26:33 -0500125 </dependencies>
126
127 <build>
128 <plugins>
129 <plugin>
130 <groupId>org.springframework.boot</groupId>
131 <artifactId>spring-boot-maven-plugin</artifactId>
Bruno Sakoto05855d52021-04-20 08:22:56 -0400132 <version>2.3.3.RELEASE</version>
Bruno Sakoto4a56deb2021-02-17 17:26:33 -0500133 </plugin>
Bruno Sakoto472d2e82021-02-25 23:23:09 -0500134 <plugin>
135 <!-- The gmavenplus plugin is used to compile Groovy code. To learn more about this plugin,
136 visit https://github.com/groovy/GMavenPlus/wiki -->
137 <groupId>org.codehaus.gmavenplus</groupId>
138 <artifactId>gmavenplus-plugin</artifactId>
139 <version>1.12.1</version>
140 <executions>
141 <execution>
142 <goals>
143 <goal>compile</goal>
144 <goal>compileTests</goal>
145 </goals>
146 </execution>
147 </executions>
148 </plugin>
149 <plugin>
150 <groupId>org.apache.maven.plugins</groupId>
puthuparambil.aditya2bd625b2021-04-27 11:39:32 +0100151 <artifactId>maven-checkstyle-plugin</artifactId>
152 <executions>
153 <execution>
154 <id>onap-license</id>
155 <goals>
156 <goal>check</goal>
157 </goals>
158 <phase>process-sources</phase>
159 <configuration>
160 <configLocation>onap-checkstyle/check-license.xml</configLocation>
161 <includeResources>false</includeResources>
162 <includeTestSourceDirectory>true</includeTestSourceDirectory>
163 <includeTestResources>false</includeTestResources>
164 <sourceDirectories>
165 <sourceDirectory>${project.build.sourceDirectory}</sourceDirectory>
166 </sourceDirectories>
167 <consoleOutput>false</consoleOutput>
168 <violationSeverity>warning</violationSeverity>
169 <failOnViolation>true</failOnViolation>
170 </configuration>
171 </execution>
172 <execution>
173 <id>onap-java-style</id>
174 <goals>
175 <goal>check</goal>
176 </goals>
177 <phase>process-sources</phase>
178 <configuration>
179 <configLocation>onap-checkstyle/onap-java-style.xml</configLocation>
180 <sourceDirectories>
181 <sourceDirectory>${project.build.sourceDirectory}</sourceDirectory>
182 </sourceDirectories>
183 <includeResources>true</includeResources>
184 <includeTestSourceDirectory>true</includeTestSourceDirectory>
185 <includeTestResources>true</includeTestResources>
186 <consoleOutput>false</consoleOutput>
187 <violationSeverity>warning</violationSeverity>
188 <failOnViolation>true</failOnViolation>
189 </configuration>
190 </execution>
191 <execution>
192 <id>cps-java-style</id>
193 <goals>
194 <goal>check</goal>
195 </goals>
196 <phase>process-sources</phase>
197 <configuration>
198 <configLocation>cps-java-style.xml</configLocation>
199 <sourceDirectories>
200 <sourceDirectory>${project.build.sourceDirectory}</sourceDirectory>
201 </sourceDirectories>
202 <includeResources>true</includeResources>
203 <includeTestSourceDirectory>true</includeTestSourceDirectory>
204 <includeTestResources>true</includeTestResources>
205 <consoleOutput>true</consoleOutput>
206 <violationSeverity>warning</violationSeverity>
207 <failOnViolation>true</failOnViolation>
208 </configuration>
209 </execution>
210 </executions>
211 <dependencies>
212 <dependency>
213 <groupId>org.onap.oparent</groupId>
214 <artifactId>checkstyle</artifactId>
215 <version>${oparent.version}</version>
216 </dependency>
217 <dependency>
218 <groupId>org.onap.cps</groupId>
219 <artifactId>checkstyle</artifactId>
220 <version>${cps.checkstyle.version}</version>
221 </dependency>
222 </dependencies>
223 </plugin>
224 <plugin>
225 <groupId>com.github.spotbugs</groupId>
226 <artifactId>spotbugs-maven-plugin</artifactId>
227 <version>${spotbugs-maven-plugin.version}</version>
228 <dependencies>
229 <dependency>
230 <groupId>com.github.spotbugs</groupId>
231 <artifactId>spotbugs</artifactId>
232 <version>${spotbugs.version}</version>
233 </dependency>
234 <dependency>
235 <groupId>org.onap.cps</groupId>
236 <artifactId>spotbugs</artifactId>
237 <version>${cps.spotbugs.version}</version>
238 </dependency>
239 <dependency>
240 <!-- The SpotBugs Maven plugin uses SLF4J 1.8 beta 2 -->
241 <groupId>org.slf4j</groupId>
242 <artifactId>slf4j-simple</artifactId>
243 <version>${spotbugs.slf4j.version}</version>
244 </dependency>
245 </dependencies>
246 <configuration>
247 <plugins>
248 <plugin>
249 <groupId>jp.skypencil.findbugs.slf4j</groupId>
250 <artifactId>bug-pattern</artifactId>
251 <version>1.5.0</version>
252 </plugin>
253 </plugins>
254 <!--
255 Enables analysis which takes more memory but finds more bugs.
256 If you run out of memory, changes the value of the effort element
257 to 'Low'.
258 -->
259 <effort>Max</effort>
260 <!-- Reports all bugs (other values are medium and max) -->
261 <threshold>Low</threshold>
262 <!-- Build doesn't fail if problems are found -->
263 <failOnError>true</failOnError>
264 <!-- References the excluded rules -->
265 <excludeFilterFile>spotbugs-exclude.xml</excludeFilterFile>
266 <!-- Produces XML report -->
267 <xmlOutput>true</xmlOutput>
268 <!-- Configures the directory in which the XML report is created -->
269 <xmlOutputDirectory>${project.build.directory}/spotbugs</xmlOutputDirectory>
270 </configuration>
271 <executions>
272 <!--
273 Ensures that SpotBugs inspects source code when project is compiled.
274 -->
275 <execution>
276 <id>analyze-compile</id>
277 <phase>compile</phase>
278 <goals>
279 <goal>check</goal>
280 </goals>
281 </execution>
282 </executions>
283 </plugin>
284 <plugin>
285 <groupId>org.apache.maven.plugins</groupId>
Bruno Sakoto472d2e82021-02-25 23:23:09 -0500286 <artifactId>maven-surefire-plugin</artifactId>
287 <configuration>
288 <!--suppress UnresolvedMavenProperty -->
289 <argLine>${surefireArgLine}</argLine>
290 <useFile>false</useFile>
291 <includes>
292 <include>**/*Spec.java</include>
293 <include>**/*Test.java</include>
294 </includes>
Bruno Sakoto05855d52021-04-20 08:22:56 -0400295 <environmentVariables>
296 <!--
297 Disable privileged container usage to cleanup the test containers;
298 these are removed automatically on jvm termination;
299 see https://www.testcontainers.org/features/configuration/#disabling-ryuk
300 -->
301 <TESTCONTAINERS_RYUK_DISABLED>true</TESTCONTAINERS_RYUK_DISABLED>
302 </environmentVariables>
Bruno Sakoto472d2e82021-02-25 23:23:09 -0500303 </configuration>
304 </plugin>
305 <plugin>
306 <groupId>org.jacoco</groupId>
307 <artifactId>jacoco-maven-plugin</artifactId>
308 <version>0.8.6</version>
309 <executions>
310 <execution>
311 <id>coverage-prepare-agent</id>
312 <goals>
313 <goal>prepare-agent</goal>
314 </goals>
315 </execution>
316 <execution>
317 <id>coverage-check</id>
318 <goals>
319 <goal>check</goal>
320 </goals>
321 <configuration>
322 <dataFile>${project.build.directory}/code-coverage/jacoco-ut.exec</dataFile>
323 <rules>
324 <rule>
325 <element>BUNDLE</element>
326 <limits>
327 <limit>
328 <counter>INSTRUCTION</counter>
329 <value>COVEREDRATIO</value>
330 <minimum>${minimum-coverage}</minimum>
331 </limit>
332 </limits>
333 </rule>
334 </rules>
335 </configuration>
336 </execution>
337 <execution>
338 <id>coverage-report</id>
339 <goals>
340 <goal>report</goal>
341 </goals>
342 <configuration>
343 <dataFile>${project.build.directory}/code-coverage/jacoco-ut.exec</dataFile>
344 </configuration>
345 </execution>
346 </executions>
347 </plugin>
Bruno Sakoto4a56deb2021-02-17 17:26:33 -0500348 </plugins>
349 </build>
Bruno Sakoto4a56deb2021-02-17 17:26:33 -0500350</project>