Use version 2.4.2 parent poms
[ccsdk/oran.git] / a1-policy-management / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3   ~ ============LICENSE_START=======================================================
4   ~ ONAP : ccsdk oran
5   ~ ================================================================================
6   ~ Copyright (C) 2020 Nordix Foundation. All rights reserved.
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
11   ~
12   ~     http://www.apache.org/licenses/LICENSE-2.0
13   ~
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=======================================================
20   ~
21 -->
22 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
23     <modelVersion>4.0.0</modelVersion>
24     <parent>
25         <groupId>org.onap.ccsdk.parent</groupId>
26         <artifactId>spring-boot-26-starter-parent</artifactId>
27         <version>2.4.2</version>
28         <relativePath/>
29     </parent>
30     <groupId>org.onap.ccsdk.oran</groupId>
31     <artifactId>a1-policy-management-service</artifactId>
32     <version>1.4.0-SNAPSHOT</version>
33     <name>ccsdk-oran :: ${project.artifactId}</name>
34     <properties>
35         <java.version.source>11</java.version.source>
36         <java.version.target>11</java.version.target>
37         <springfox.version>3.0.0</springfox.version>
38         <gson.version>2.9.0</gson.version>
39         <json.version>20220320</json.version>
40         <formatter-maven-plugin.version>2.13.0</formatter-maven-plugin.version>
41         <spotless-maven-plugin.version>2.5.0</spotless-maven-plugin.version>
42         <commons-io.version>2.11.0</commons-io.version>
43         <docker-maven-plugin>0.30.0</docker-maven-plugin>
44         <surefire-maven-plugin.version>3.0.0-M5</surefire-maven-plugin.version>
45         <!-- Version must be higher than version 2.19.1 that is defined in the parent pom for JUnit 5 tests to be run. Do not remove! -->
46         <jacoco-maven-plugin.version>0.8.6</jacoco-maven-plugin.version>
47         <swagger-codegen-maven-plugin.version>3.0.11</swagger-codegen-maven-plugin.version>
48         <exec.skip>true</exec.skip>
49         <ccsdk.project.version>${project.version}</ccsdk.project.version>
50     </properties>
51     <dependencies>
52         <dependency>
53             <groupId>org.springframework.boot</groupId>
54             <artifactId>spring-boot</artifactId>
55         </dependency>
56         <dependency>
57             <groupId>org.springframework</groupId>
58             <artifactId>spring-beans</artifactId>
59         </dependency>
60         <dependency>
61             <groupId>org.springframework</groupId>
62             <artifactId>spring-context</artifactId>
63         </dependency>
64         <dependency>
65             <groupId>org.springframework.boot</groupId>
66             <artifactId>spring-boot-autoconfigure</artifactId>
67         </dependency>
68         <dependency>
69             <groupId>org.springframework</groupId>
70             <artifactId>spring-web</artifactId>
71         </dependency>
72         <dependency>
73             <groupId>org.springframework</groupId>
74             <artifactId>spring-webmvc</artifactId>
75         </dependency>
76         <dependency>
77             <groupId>org.springframework.boot</groupId>
78             <artifactId>spring-boot-starter-webflux</artifactId>
79         </dependency>
80         <dependency>
81             <groupId>org.springframework</groupId>
82             <artifactId>spring-webflux</artifactId>
83         </dependency>
84         <dependency>
85             <groupId>io.springfox</groupId>
86             <artifactId>springfox-spring-web</artifactId>
87             <version>${springfox.version}</version>
88         </dependency>
89         <dependency>
90             <groupId>io.springfox</groupId>
91             <artifactId>springfox-spi</artifactId>
92             <version>${springfox.version}</version>
93         </dependency>
94         <dependency>
95             <groupId>io.springfox</groupId>
96             <artifactId>springfox-core</artifactId>
97             <version>${springfox.version}</version>
98         </dependency>
99         <dependency>
100             <groupId>org.aspectj</groupId>
101             <artifactId>aspectjweaver</artifactId>
102         </dependency>
103         <dependency>
104             <groupId>com.fasterxml.jackson.core</groupId>
105             <artifactId>jackson-databind</artifactId>
106         </dependency>
107         <dependency>
108             <groupId>org.apache.tomcat.embed</groupId>
109             <artifactId>tomcat-embed-core</artifactId>
110         </dependency>
111         <dependency>
112             <groupId>javax.validation</groupId>
113             <artifactId>validation-api</artifactId>
114         </dependency>
115         <dependency>
116             <groupId>com.google.guava</groupId>
117             <artifactId>guava</artifactId>
118         </dependency>
119         <dependency>
120             <groupId>com.google.code.gson</groupId>
121             <artifactId>gson</artifactId>
122             <version>${gson.version}</version>
123         </dependency>
124         <dependency>
125             <groupId>org.json</groupId>
126             <artifactId>json</artifactId>
127             <version>${json.version}</version>
128         </dependency>
129         <dependency>
130             <groupId>org.projectlombok</groupId>
131             <artifactId>lombok</artifactId>
132             <scope>provided</scope>
133         </dependency>
134         <!-- Actuator dependencies -->
135         <dependency>
136             <groupId>org.springframework.boot</groupId>
137             <artifactId>spring-boot-starter-actuator</artifactId>
138             <scope>runtime</scope>
139         </dependency>
140         <!--REQUIRED TO GENERATE DOCUMENTATION -->
141         <dependency>
142             <groupId>io.springfox</groupId>
143             <artifactId>springfox-swagger2</artifactId>
144             <version>${springfox.version}</version>
145         </dependency>
146         <dependency>
147             <groupId>io.springfox</groupId>
148             <artifactId>springfox-swagger-ui</artifactId>
149             <version>${springfox.version}</version>
150             <scope>runtime</scope>
151         </dependency>
152         <!-- For development help -->
153         <dependency>
154             <groupId>org.springframework.boot</groupId>
155             <artifactId>spring-boot-devtools</artifactId>
156             <optional>true</optional>
157             <scope>runtime</scope>
158         </dependency>
159         <dependency>
160             <groupId>org.springframework.boot</groupId>
161             <artifactId>spring-boot-configuration-processor</artifactId>
162             <optional>true</optional>
163             <scope>runtime</scope>
164         </dependency>
165         <!-- TEST -->
166         <dependency>
167             <groupId>org.springdoc</groupId>
168             <artifactId>springdoc-openapi-ui</artifactId>
169             <version>1.6.6</version>
170             <scope>test</scope>
171         </dependency>
172         <dependency>
173             <groupId>org.springframework.boot</groupId>
174             <artifactId>spring-boot-test</artifactId>
175             <scope>test</scope>
176         </dependency>
177         <dependency>
178             <groupId>org.springframework.boot</groupId>
179             <artifactId>spring-boot-starter-test</artifactId>
180             <scope>test</scope>
181         </dependency>
182         <dependency>
183             <groupId>org.awaitility</groupId>
184             <artifactId>awaitility</artifactId>
185             <scope>test</scope>
186         </dependency>
187         <dependency>
188             <groupId>io.projectreactor</groupId>
189             <artifactId>reactor-test</artifactId>
190             <scope>test</scope>
191         </dependency>
192         <dependency>
193             <groupId>org.junit.jupiter</groupId>
194             <artifactId>junit-jupiter-engine</artifactId>
195             <scope>test</scope>
196         </dependency>
197         <dependency>
198             <groupId>org.mockito</groupId>
199             <artifactId>mockito-junit-jupiter</artifactId>
200             <scope>test</scope>
201         </dependency>
202         <dependency>
203             <groupId>org.mockito</groupId>
204             <artifactId>mockito-core</artifactId>
205             <scope>test</scope>
206         </dependency>
207         <dependency>
208             <groupId>com.squareup.okhttp3</groupId>
209             <artifactId>mockwebserver</artifactId>
210             <scope>test</scope>
211         </dependency>
212         <dependency>
213             <groupId>commons-io</groupId>
214             <artifactId>commons-io</artifactId>
215             <version>${commons-io.version}</version>
216             <scope>test</scope>
217         </dependency>
218         <!-- https://mvnrepository.com/artifact/com.github.erosb/everit-json-schema -->
219         <dependency>
220             <groupId>com.github.erosb</groupId>
221             <artifactId>everit-json-schema</artifactId>
222             <version>1.14.0</version>
223         </dependency>
224     </dependencies>
225     <build>
226         <plugins>
227             <plugin>
228                 <groupId>org.codehaus.groovy.maven</groupId>
229                 <artifactId>gmaven-plugin</artifactId>
230                 <executions>
231                     <execution>
232                         <phase>validate</phase>
233                         <goals>
234                             <goal>execute</goal>
235                         </goals>
236                         <configuration>
237                             <source>${basedir}/TagVersion.groovy</source>
238                         </configuration>
239                     </execution>
240                 </executions>
241             </plugin>
242             <plugin>
243                 <groupId>org.springframework.boot</groupId>
244                 <artifactId>spring-boot-maven-plugin</artifactId>
245             </plugin>
246             <plugin>
247                 <groupId>net.revelc.code.formatter</groupId>
248                 <artifactId>formatter-maven-plugin</artifactId>
249                 <version>${formatter-maven-plugin.version}</version>
250                 <configuration>
251                     <lineEnding>LF</lineEnding>
252                     <configFile>${project.basedir}/eclipse-formatter.xml</configFile>
253                 </configuration>
254                 <!-- https://code.revelc.net/formatter-maven-plugin/ use mvn formatter:format
255                                         spotless:apply process-sources -->
256             </plugin>
257             <plugin>
258                 <groupId>com.diffplug.spotless</groupId>
259                 <artifactId>spotless-maven-plugin</artifactId>
260                 <version>${spotless-maven-plugin.version}</version>
261                 <configuration>
262                     <lineEndings>UNIX</lineEndings>
263                     <java>
264                         <removeUnusedImports/>
265                         <importOrder>
266                             <order>com,java,javax,org</order>
267                         </importOrder>
268                     </java>
269                 </configuration>
270                 <!-- https://github.com/diffplug/spotless/tree/master/plugin-maven use
271                                         mvn spotless:apply to rewrite source files use mvn spotless:check to validate
272                                         source files -->
273             </plugin>
274             <plugin>
275                 <groupId>org.apache.maven.plugins</groupId>
276                 <artifactId>maven-surefire-plugin</artifactId>
277                 <version>${surefire-maven-plugin.version}</version>
278                 <configuration>
279                     <skipTests>false</skipTests>
280                 </configuration>
281             </plugin>
282             <plugin>
283                 <artifactId>maven-failsafe-plugin</artifactId>
284             </plugin>
285             <plugin>
286                 <groupId>org.codehaus.mojo</groupId>
287                 <artifactId>build-helper-maven-plugin</artifactId>
288                 <executions>
289                     <execution>
290                         <id>add-source</id>
291                         <phase>generate-sources</phase>
292                         <goals>
293                             <goal>add-source</goal>
294                         </goals>
295                         <configuration>
296                             <sources>
297                                 <source>${project.build.directory}/generated-sources/annotations/</source>
298                             </sources>
299                         </configuration>
300                     </execution>
301                 </executions>
302             </plugin>
303             <plugin>
304                 <groupId>org.jacoco</groupId>
305                 <artifactId>jacoco-maven-plugin</artifactId>
306                 <version>${jacoco-maven-plugin.version}</version>
307                 <executions>
308                     <execution>
309                         <id>default-prepare-agent</id>
310                         <goals>
311                             <goal>prepare-agent</goal>
312                         </goals>
313                     </execution>
314                     <execution>
315                         <id>default-report</id>
316                         <phase>prepare-package</phase>
317                         <goals>
318                             <goal>report</goal>
319                         </goals>
320                     </execution>
321                 </executions>
322             </plugin>
323             <plugin>
324                 <groupId>io.swagger.codegen.v3</groupId>
325                 <artifactId>swagger-codegen-maven-plugin</artifactId>
326                 <version>${swagger-codegen-maven-plugin.version}</version>
327                 <executions>
328                     <execution>
329                         <phase>test</phase>
330                         <goals>
331                             <goal>generate</goal>
332                         </goals>
333                         <configuration>
334                             <inputSpec>${project.basedir}/api/pms-api.json</inputSpec>
335                             <language>openapi-yaml</language>
336                             <output>${project.basedir}/api</output>
337                             <configOptions>
338                                 <outputFile>pms-api.yaml</outputFile>
339                             </configOptions>
340                         </configuration>
341                     </execution>
342                 </executions>
343             </plugin>
344             <plugin>
345                 <artifactId>maven-resources-plugin</artifactId>
346                 <executions>
347                     <execution>
348                         <id>copy-resource-one</id>
349                         <phase>install</phase>
350                         <goals>
351                             <goal>copy-resources</goal>
352                         </goals>
353                         <configuration>
354                             <outputDirectory>${project.basedir}/../docs/offeredapis/swagger</outputDirectory>
355                             <resources>
356                                 <resource>
357                                     <directory>${project.basedir}/api</directory>
358                                     <includes>
359                                         <include>pms-api.*</include>
360                                     </includes>
361                                 </resource>
362                             </resources>
363                         </configuration>
364                     </execution>
365                 </executions>
366             </plugin>
367             <plugin>
368                 <groupId>io.fabric8</groupId>
369                 <artifactId>docker-maven-plugin</artifactId>
370                 <version>${docker-maven-plugin}</version>
371                 <inherited>false</inherited>
372                 <executions>
373                     <execution>
374                         <id>generate-policy-management-service-image</id>
375                         <phase>package</phase>
376                         <goals>
377                             <goal>build</goal>
378                         </goals>
379                         <configuration>
380                             <images>
381                                 <image>
382                                     <name>onap/ccsdk-oran-a1policymanagementservice:${project.version}</name>
383                                     <build>
384                                         <cleanup>try</cleanup>
385                                         <contextDir>${basedir}</contextDir>
386                                         <dockerFile>Dockerfile</dockerFile>
387                                         <args>
388                                             <JAR>${project.build.finalName}.jar</JAR>
389                                         </args>
390                                         <tags>
391                                             <tag>${project.version}</tag>
392                                         </tags>
393                                     </build>
394                                 </image>
395                             </images>
396                         </configuration>
397                     </execution>
398                     <execution>
399                         <id>push-policy-management-service-image</id>
400                         <goals>
401                             <goal>build</goal>
402                             <goal>push</goal>
403                         </goals>
404                         <configuration>
405                             <images>
406                                 <image>
407                                     <name>onap/ccsdk-oran-a1policymanagementservice:${project.version}</name>
408                                     <build>
409                                         <contextDir>${basedir}</contextDir>
410                                         <dockerFile>Dockerfile</dockerFile>
411                                         <args>
412                                             <JAR>${project.build.finalName}.jar</JAR>
413                                         </args>
414                                         <tags>
415                                             <tag>${project.docker.latestminortag.version}</tag>
416                                             <tag>${project.docker.latestfulltag.version}</tag>
417                                             <tag>${project.docker.latesttagtimestamp.version}</tag>
418                                         </tags>
419                                     </build>
420                                 </image>
421                             </images>
422                         </configuration>
423                     </execution>
424                 </executions>
425             </plugin>
426         </plugins>
427     </build>
428 </project>