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