c086f58f41bdeadeb5495b7cc4619e8b6dcb249d
[nonrtric/plt/a1policymanagementservice.git] / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3 * ========================LICENSE_START=================================
4 * O-RAN-SC
5 * %%
6 * Copyright (C) 2019-2023: Nordix Foundation
7 * Copyright (C) 2023-2024: OpenInfra Foundation Europe
8 * %%
9 * Licensed under the Apache License, Version 2.0 (the "License");
10 * you may not use this file except in compliance with the License.
11 * You may obtain a copy of the License at
12 *
13 * http://www.apache.org/licenses/LICENSE-2.0
14 *
15 * Unless required by applicable law or agreed to in writing, software
16 * distributed under the License is distributed on an "AS IS" BASIS,
17 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
18 * See the License for the specific language governing permissions and
19 * limitations under the License.
20 * ========================LICENSE_END===================================
21 -->
22 <project
23     xmlns="http://maven.apache.org/POM/4.0.0"
24     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
25     xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
26     <modelVersion>4.0.0</modelVersion>
27     <parent>
28         <groupId>org.springframework.boot</groupId>
29         <artifactId>spring-boot-starter-parent</artifactId>
30         <version>3.2.0</version>
31         <relativePath />
32     </parent>
33     <groupId>org.o-ran-sc.nonrtric.plt</groupId>
34     <artifactId>a1policymanagementservice</artifactId>
35     <version>2.8.0-SNAPSHOT</version>
36     <licenses>
37         <license>
38             <name>The Apache Software License, Version 2.0</name>
39             <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
40         </license>
41     </licenses>
42     <repositories>
43         <repository>
44             <id>onap-releases</id>
45             <name>onap-releases</name>
46             <url>https://nexus.onap.org/content/repositories/releases/</url>
47         </repository>
48     </repositories>
49     <properties>
50         <java.version>17</java.version>
51         <json.version>20231013</json.version>
52         <maven-compiler-plugin.version>3.10.0</maven-compiler-plugin.version>
53         <formatter-maven-plugin.version>2.13.0</formatter-maven-plugin.version>
54         <spotless-maven-plugin.version>2.30.0</spotless-maven-plugin.version>
55         <docker-maven-plugin>0.43.0</docker-maven-plugin>
56         <sonar-maven-plugin.version>3.7.0.1746</sonar-maven-plugin.version>
57         <jacoco-maven-plugin.version>0.8.8</jacoco-maven-plugin.version>
58         <exec-maven-plugin.version>3.1.0</exec-maven-plugin.version>
59         <software.amazon.awssdk.version>2.19.17</software.amazon.awssdk.version>
60         <springdoc.version>2.0.2</springdoc.version>
61         <springdoc.openapi-ui.version>1.6.14</springdoc.openapi-ui.version>
62         <surefire-maven-plugin.version>3.0.0-M8</surefire-maven-plugin.version>
63         <surefire-report-plugin.version>3.0.0-M8</surefire-report-plugin.version>
64     </properties>
65     <dependencies>    
66         <dependency>
67             <groupId>commons-io</groupId>
68             <artifactId>commons-io</artifactId>
69             <version>2.14.0</version>
70         </dependency>
71         <dependency>
72             <groupId>com.google.guava</groupId>
73             <artifactId>guava</artifactId>
74             <version>32.0.1-jre</version>
75         </dependency>
76         <dependency>
77             <groupId>org.springframework.boot</groupId>
78             <artifactId>spring-boot-starter-web</artifactId>
79         </dependency>
80         <dependency>
81             <groupId>org.springframework.boot</groupId>
82             <artifactId>spring-boot-starter-thymeleaf</artifactId>
83         </dependency>
84         <dependency>
85             <groupId>org.springframework.boot</groupId>
86             <artifactId>spring-boot-starter-webflux</artifactId>
87         </dependency>
88         <dependency>
89             <groupId>org.springframework.boot</groupId>
90             <artifactId>spring-boot-starter-aop</artifactId>
91         </dependency>
92         <dependency>
93             <groupId>org.springframework.boot</groupId>
94             <artifactId>spring-boot-devtools</artifactId>
95             <optional>true</optional>
96         </dependency>
97         <dependency>
98             <groupId>org.springframework.boot</groupId>
99             <artifactId>spring-boot-starter-validation</artifactId>
100         </dependency>
101         <dependency>
102             <groupId>org.springframework</groupId>
103             <artifactId>spring-webflux</artifactId>
104         </dependency>
105         <dependency>
106             <groupId>com.google.code.gson</groupId>
107             <artifactId>gson</artifactId>
108         </dependency>
109         <dependency>
110             <groupId>org.json</groupId>
111             <artifactId>json</artifactId>
112             <version>${json.version}</version>
113         </dependency>
114         <dependency>
115             <groupId>org.springframework.boot</groupId>
116             <artifactId>spring-boot-configuration-processor</artifactId>
117             <optional>true</optional>
118         </dependency>
119         <dependency>
120             <groupId>org.projectlombok</groupId>
121             <artifactId>lombok</artifactId>
122             <scope>provided</scope>
123         </dependency>
124         <dependency>
125             <groupId>org.glassfish.jersey.inject</groupId>
126             <artifactId>jersey-hk2</artifactId>
127         </dependency>
128         <!-- Actuator dependencies -->
129         <dependency>
130             <groupId>org.springframework.boot</groupId>
131             <artifactId>spring-boot-starter-actuator</artifactId>
132         </dependency>
133         <!--REQUIRED
134         TO GENERATE DOCUMENTATION -->
135         <dependency>
136             <groupId>org.springdoc</groupId>
137             <artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
138             <version>${springdoc.version}</version>
139         </dependency>
140         <dependency>
141             <groupId>org.springdoc</groupId>
142             <artifactId>springdoc-openapi-ui</artifactId>
143             <version>${springdoc.openapi-ui.version}</version>
144         </dependency>
145         <!-- TEST -->
146         <dependency>
147             <groupId>org.springframework.boot</groupId>
148             <artifactId>spring-boot-test</artifactId>
149             <scope>test</scope>
150         </dependency>
151         <dependency>
152             <groupId>org.springframework.boot</groupId>
153             <artifactId>spring-boot-starter-test</artifactId>
154             <scope>test</scope>
155         </dependency>
156         <dependency>
157             <groupId>org.awaitility</groupId>
158             <artifactId>awaitility</artifactId>
159             <scope>test</scope>
160         </dependency>
161         <dependency>
162             <groupId>io.projectreactor</groupId>
163             <artifactId>reactor-test</artifactId>
164             <scope>test</scope>
165         </dependency>
166         <dependency>
167             <groupId>org.junit.jupiter</groupId>
168             <artifactId>junit-jupiter-engine</artifactId>
169             <scope>test</scope>
170         </dependency>
171         <dependency>
172             <groupId>org.mockito</groupId>
173             <artifactId>mockito-junit-jupiter</artifactId>
174             <scope>test</scope>
175         </dependency>
176         <dependency>
177             <groupId>org.mockito</groupId>
178             <artifactId>mockito-core</artifactId>
179             <scope>test</scope>
180         </dependency>
181         <dependency>
182             <groupId>com.squareup.okhttp3</groupId>
183             <artifactId>mockwebserver</artifactId>
184             <scope>test</scope>
185         </dependency>
186         <dependency>
187             <groupId>com.github.erosb</groupId>
188             <artifactId>everit-json-schema</artifactId>
189             <version>1.14.1</version>
190         </dependency>
191         <dependency>
192             <groupId>software.amazon.awssdk</groupId>
193             <artifactId>s3</artifactId>
194             <version>${software.amazon.awssdk.version}</version>
195         </dependency>
196         <dependency>
197             <groupId>io.micrometer</groupId>
198             <artifactId>micrometer-registry-prometheus</artifactId>
199         </dependency>
200     </dependencies>
201     <build>
202         <plugins>
203             <plugin>
204                 <groupId>org.springframework.boot</groupId>
205                 <artifactId>spring-boot-maven-plugin</artifactId>
206             </plugin>
207             <plugin>
208                 <groupId>org.apache.maven.plugins</groupId>
209                 <artifactId>maven-surefire-plugin</artifactId>
210                 <version>${surefire-maven-plugin.version}</version>
211                 <configuration>
212                     <skipTests>false</skipTests>
213                 </configuration>
214             </plugin>
215             <plugin>
216                 <artifactId>maven-failsafe-plugin</artifactId>
217             </plugin>
218             <plugin>
219                 <groupId>org.codehaus.mojo</groupId>
220                 <artifactId>build-helper-maven-plugin</artifactId>
221                 <executions>
222                     <execution>
223                         <id>add-additional-source-dirs</id>
224                         <phase>generate-sources</phase>
225                         <goals>
226                             <goal>add-source</goal>
227                         </goals>
228                         <configuration>
229                             <sources>
230                                 <source>${project.build.directory}/generated-sources/annotations/</source>
231                                 <source>${project.basedir}/add-src/main/java</source>
232                                 <source>${project.basedir}/add-src/main/resources</source>
233                             </sources>
234                         </configuration>
235                     </execution>
236                     <execution>
237                         <id>add-additional-testsource-dirs</id>
238                         <phase>generate-sources</phase>
239                         <goals>
240                             <goal>add-test-source</goal>
241                         </goals>
242                         <configuration>
243                             <sources>
244                                 <source>${project.basedir}/add-src/test/java</source>
245                                 <source>${project.basedir}/add-src/test/resources</source>
246                             </sources>
247                         </configuration>
248                     </execution>
249                 </executions>
250             </plugin>
251             <plugin>
252                 <groupId>org.jacoco</groupId>
253                 <artifactId>jacoco-maven-plugin</artifactId>
254                 <version>${jacoco-maven-plugin.version}</version>
255                 <executions>
256                     <execution>
257                         <id>default-prepare-agent</id>
258                         <goals>
259                             <goal>prepare-agent</goal>
260                         </goals>
261                     </execution>
262                     <execution>
263                         <id>default-report</id>
264                         <phase>prepare-package</phase>
265                         <goals>
266                             <goal>report</goal>
267                         </goals>
268                     </execution>
269                 </executions>
270             </plugin>
271             <plugin>
272                 <groupId>io.fabric8</groupId>
273                 <artifactId>docker-maven-plugin</artifactId>
274                 <version>${docker-maven-plugin}</version>
275                 <inherited>false</inherited>
276                 <executions>
277                     <execution>
278                         <id>generate-a1policymanagementservice-image</id>
279                         <phase>package</phase>
280                         <goals>
281                             <goal>build</goal>
282                         </goals>
283                         <configuration>
284                             <pullRegistry>${env.CONTAINER_PULL_REGISTRY}</pullRegistry>
285                             <images>
286                                 <image>
287                                     <name>
288                                         o-ran-sc/nonrtric-plt-a1policymanagementservice:${project.version}</name>
289                                     <build>
290                                         <cleanup>try</cleanup>
291                                         <contextDir>${basedir}</contextDir>
292                                         <dockerFile>Dockerfile</dockerFile>
293                                         <filter>false</filter>
294                                         <args>
295                                             <JAR>${project.build.finalName}.jar</JAR>
296                                         </args>
297                                         <tags>
298                                             <tag>${project.version}</tag>
299                                         </tags>
300                                     </build>
301                                 </image>
302                             </images>
303                         </configuration>
304                     </execution>
305                     <execution>
306                         <id>push-a1policymanagementservice-image</id>
307                         <goals>
308                             <goal>build</goal>
309                             <goal>push</goal>
310                         </goals>
311                         <configuration>
312                             <pullRegistry>${env.CONTAINER_PULL_REGISTRY}</pullRegistry>
313                             <pushRegistry>${env.CONTAINER_PUSH_REGISTRY}</pushRegistry>
314                             <images>
315                                 <image>
316                                     <name>
317                                         o-ran-sc/nonrtric-plt-a1policymanagementservice:${project.version}</name>
318                                     <build>
319                                         <contextDir>${basedir}</contextDir>
320                                         <dockerFile>Dockerfile</dockerFile>
321                                         <filter>false</filter>
322                                         <args>
323                                             <JAR>${project.build.finalName}.jar</JAR>
324                                         </args>
325                                         <tags>
326                                             <tag>${project.version}</tag>
327                                             <tag>latest</tag>
328                                         </tags>
329                                     </build>
330                                 </image>
331                             </images>
332                         </configuration>
333                     </execution>
334                 </executions>
335             </plugin>
336             <!-- support sonar in multi-module project -->
337             <plugin>
338                 <groupId>org.sonarsource.scanner.maven</groupId>
339                 <artifactId>sonar-maven-plugin</artifactId>
340                 <version>${sonar-maven-plugin.version}</version>
341             </plugin>
342             <plugin>
343                 <groupId>org.codehaus.mojo</groupId>
344                 <artifactId>exec-maven-plugin</artifactId>
345                 <version>${exec-maven-plugin.version}</version>
346                 <executions>
347                     <execution>
348                         <id>git submodule update</id>
349                         <phase>initialize</phase>
350                         <configuration>
351                             <executable>git</executable>
352                             <arguments>
353                                 <argument>submodule</argument>
354                                 <argument>update</argument>
355                                 <argument>--init</argument>
356                                 <argument>--recursive</argument>
357                             </arguments>
358                         </configuration>
359                         <goals>
360                             <goal>exec</goal>
361                         </goals>
362                     </execution>
363                     <execution>
364                         <id>copy configuration</id>
365                         <phase>initialize</phase>
366                         <configuration>
367                             <executable>cp</executable>
368                             <arguments>
369                                 <argument>-r</argument>
370                                 <argument>onap/oran/a1-policy-management/config</argument>
371                                 <argument>.</argument>
372                             </arguments>
373                         </configuration>
374                         <goals>
375                             <goal>exec</goal>
376                         </goals>
377                     </execution>
378                 </executions>
379             </plugin>
380         </plugins>
381     </build>
382     <issueManagement>
383         <system>JIRA</system>
384         <url>https://jira.o-ran-sc.org/</url>
385     </issueManagement>
386     <reporting>
387         <plugins>
388             <plugin>
389                 <groupId>org.apache.maven.plugins</groupId>
390                 <artifactId>maven-surefire-report-plugin</artifactId>
391                 <version>${surefire-report-plugin.version}</version>
392             </plugin>
393         </plugins>
394     </reporting>
395 </project>