Merge "[DCAEGEN-2] Added Junit for nfFilter schema validation"
[dcaegen2/services.git] / components / slice-analysis-ms / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3 /*******************************************************************************
4  *  ============LICENSE_START=======================================================
5  *  slice-analysis-ms
6  *  ================================================================================
7  *   Copyright (C) 2020 Wipro Limited.
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  *******************************************************************************/
23   -->
24 <project xmlns="http://maven.apache.org/POM/4.0.0" 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.onap.oparent</groupId>
29         <artifactId>oparent</artifactId>
30         <version>2.0.0</version>
31     </parent>
32
33         <groupId>org.onap.dcaegen2.services.components</groupId>
34         <artifactId>slice-analysis-ms</artifactId>
35         <version>1.0.4-SNAPSHOT</version>
36         <name>dcaegen2-services-slice-analysis-ms</name>
37         <description>Network slice PM analyser</description>
38         <packaging>jar</packaging>
39
40         <properties>
41                 <java.version>11</java.version>
42                 <sdk.version>1.1.4</sdk.version>
43                 <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
44                 <maven.compiler.source>11</maven.compiler.source>
45                 <maven.compiler.target>11</maven.compiler.target>
46                 <docker.image.name>onap/${project.groupId}.${project.artifactId}</docker.image.name>
47                 <!-- NEXUS RELATED SETTINGS -->
48                 <nexusproxy>https://nexus.onap.org</nexusproxy>
49                 <snapshots.path>content/repositories/snapshots/</snapshots.path>
50                 <releases.path>content/repositories/releases/</releases.path>
51                 <site.path>content/sites/site/org/onap/dcaegen2/services/${project.artifactId}/${project.version}</site.path>
52                 <maven.build.timestamp.format>yyyyMMdd'T'HHmmss</maven.build.timestamp.format>
53                 <sonar.coverage.jacoco.xmlReportPaths>
54                 ${project.reporting.outputDirectory}/jacoco-ut/jacoco.xml
55                 </sonar.coverage.jacoco.xmlReportPaths>
56         </properties>
57
58         <dependencies>
59                 <!-- https://mvnrepository.com/artifact/org.apache.tomcat/tomcat-util -->
60                 <dependency>
61                         <groupId>org.apache.tomcat</groupId>
62                         <artifactId>tomcat-util</artifactId>
63                         <version>9.0.37</version>
64                 </dependency>
65                 <!-- https://mvnrepository.com/artifact/org.springframework.boot/spring-boot-autoconfigure -->
66                 <dependency>
67                         <groupId>org.springframework.boot</groupId>
68                         <artifactId>spring-boot-autoconfigure</artifactId>
69                         <version>2.3.1.RELEASE</version>
70                 </dependency>
71                 <dependency>
72                         <groupId>org.springframework</groupId>
73                         <artifactId>spring-webmvc</artifactId>
74                         <version>5.2.7.RELEASE</version>
75                 </dependency>
76                 <dependency>
77                          <groupId>org.springframework</groupId>
78                          <artifactId>spring-core</artifactId>
79                          <version>5.2.7.RELEASE</version>
80                 </dependency>
81                 <dependency>
82                         <groupId>org.springframework</groupId>
83                         <artifactId>spring-beans</artifactId>
84                         <version>5.2.7.RELEASE</version>
85                 </dependency>
86                 <dependency>
87                         <groupId>org.springframework</groupId>
88                         <artifactId>spring-expression</artifactId>
89                         <version>5.2.7.RELEASE</version>
90                 </dependency>
91                 <dependency>
92                         <groupId>org.springframework</groupId>
93                         <artifactId>spring-web</artifactId>
94                         <version>5.2.7.RELEASE</version>
95                 </dependency>
96                 <dependency>
97                         <groupId>org.springframework</groupId>
98                         <artifactId>spring-tx</artifactId>
99                         <version>5.2.7.RELEASE</version>
100                 </dependency>
101                 <dependency>
102                         <groupId>org.springframework.data</groupId>
103                         <artifactId>spring-data-commons</artifactId>
104                         <version>2.2.0.RELEASE</version>
105                 </dependency>
106                 <!-- cbs client -->
107                 <dependency>
108                         <groupId>org.onap.dcaegen2.services.sdk.rest.services</groupId>
109                         <artifactId>cbs-client</artifactId>
110                         <version>${sdk.version}</version>
111                 </dependency>
112
113                 <dependency>
114                         <groupId>org.onap.dcaegen2.services.sdk.security.crypt</groupId>
115                         <artifactId>crypt-password</artifactId>
116                         <version>${sdk.version}</version>
117                 </dependency>
118                 <dependency>
119                         <!-- Import dependency management from Spring Boot -->
120                         <groupId>org.springframework.boot</groupId>
121                         <artifactId>spring-boot-dependencies</artifactId>
122                         <version>2.1.3.RELEASE</version>
123                         <type>pom</type>
124                         <scope>import</scope>
125                 </dependency>
126                 <dependency>
127                         <groupId>com.att.nsa</groupId>
128                         <artifactId>cambriaClient</artifactId>
129                         <version>0.0.1</version>
130                 </dependency>
131                 <dependency>
132                         <groupId>junit</groupId>
133                         <artifactId>junit</artifactId>
134                         <scope>test</scope>
135                 </dependency>
136                 <dependency>
137                         <groupId>com.fasterxml.jackson.core</groupId>
138                         <artifactId>jackson-core</artifactId>
139                         <version>2.11.0</version>
140                 </dependency>
141                 <dependency>
142                 <groupId>net.javacrumbs.json-unit</groupId>
143                 <artifactId>json-unit-assertj</artifactId>
144                 <version>2.14.0</version>
145                 <scope>test</scope>
146                 </dependency>
147                 <dependency>
148                         <groupId>com.fasterxml.jackson.core</groupId>
149                         <artifactId>jackson-databind</artifactId>
150                         <version>2.11.0</version>
151                 </dependency>
152                 <!-- https://mvnrepository.com/artifact/javax.json/javax.json-api -->
153                 <dependency>
154                         <groupId>javax.json</groupId>
155                         <artifactId>javax.json-api</artifactId>
156                         <version>1.1.2</version>
157                 </dependency>
158                 <dependency>
159                         <groupId>org.springframework.boot</groupId>
160                         <artifactId>spring-boot-starter-web</artifactId>
161                         <version>2.1.3.RELEASE</version>
162                         <exclusions>
163                                 <exclusion>
164                                         <groupId>org.springframework.boot</groupId>
165                                         <artifactId>spring-boot-starter-tomcat</artifactId>
166                                 </exclusion>
167                         </exclusions>
168                 </dependency>
169                 <dependency>
170                         <groupId>org.postgresql</groupId>
171                         <artifactId>postgresql</artifactId>
172                         <version>42.2.5</version>
173                 </dependency>
174                 <dependency>
175                         <groupId>org.springframework.boot</groupId>
176                         <artifactId>spring-boot-starter-data-jpa</artifactId>
177                         <version>2.1.3.RELEASE</version>
178                 </dependency>
179                 <dependency>
180                         <groupId>org.hibernate.javax.persistence</groupId>
181                         <artifactId>hibernate-jpa-2.0-api</artifactId>
182                         <version>1.0.1.Final</version>
183                 </dependency>
184                 <!-- https://mvnrepository.com/artifact/org.springframework/spring-beans -->
185                 <dependency>
186                         <groupId>org.springframework.boot</groupId>
187                         <artifactId>spring-boot-starter-test</artifactId>
188                         <version>2.1.3.RELEASE</version>
189                         <scope>test</scope>
190                         <!-- exclusions> <exclusion> <groupId>org.mockito</groupId> <artifactId>mockito-core</artifactId>
191                                 </exclusion> </exclusions -->
192                 </dependency>
193                 <!-- https://mvnrepository.com/artifact/org.mockito/mockito-core -->
194                 <dependency>
195                         <groupId>org.mockito</groupId>
196                         <artifactId>mockito-core</artifactId>
197                         <version>2.21.0</version>
198                         <scope>test</scope>
199                 </dependency>
200             <dependency>
201                 <groupId>com.openpojo</groupId>
202                 <artifactId>openpojo</artifactId>
203                 <version>0.8.10</version>
204             </dependency>
205                 <dependency>
206                         <groupId>junit</groupId>
207                         <artifactId>junit</artifactId>
208                         <version>4.12</version>
209                         <scope>test</scope>
210                 </dependency>
211                 <!-- https://mvnrepository.com/artifact/org.powermock/powermock-api-mockito2 -->
212                 <dependency>
213                         <groupId>org.powermock</groupId>
214                         <artifactId>powermock-api-mockito2</artifactId>
215                         <version>2.0.2</version>
216                         <exclusions>
217                                 <exclusion>
218                                         <groupId>org.mockito</groupId>
219                                         <artifactId>mockito-all</artifactId>
220                                 </exclusion>
221                         </exclusions>
222                 </dependency>
223                 <!-- https://mvnrepository.com/artifact/org.powermock/powermock-module-junit4 -->
224                 <dependency>
225                         <groupId>org.powermock</groupId>
226                         <artifactId>powermock-module-junit4</artifactId>
227                         <version>2.0.2</version>
228                         <scope>test</scope>
229                 </dependency>
230
231                 <dependency>
232                     <groupId>org.functionaljava</groupId>
233                     <artifactId>functionaljava</artifactId>
234                     <version>3.0</version>
235             </dependency>
236
237             <dependency>
238                     <groupId>org.apache.httpcomponents</groupId>
239                     <artifactId>httpclient</artifactId>
240                 <version>4.5.7</version>
241             </dependency>
242
243            <!-- https://mvnrepository.com/artifact/commons-beanutils/commons-beanutils -->
244             <dependency>
245                    <groupId>commons-beanutils</groupId>
246                    <artifactId>commons-beanutils</artifactId>
247                    <version>1.9.4</version>
248             </dependency>
249             <!-- mvnrepository.com/artifact/org.eclipse.jetty/jetty-server -->
250             <dependency>
251                    <groupId>org.eclipse.jetty</groupId>
252                    <artifactId>jetty-server</artifactId>
253                    <version>9.4.17.v20190418</version>
254             </dependency>
255             <!-- https://mvnrepository.com/artifact/org.webjars/bootstrap -->
256             <dependency>
257                    <groupId>org.webjars</groupId>
258                    <artifactId>bootstrap</artifactId>
259                    <version>4.3.1</version>
260             </dependency>
261             <!-- https://mvnrepository.com/artifact/javax.xml.bind/jaxb-api -->
262             <dependency>
263                    <groupId>javax.xml.bind</groupId>
264                    <artifactId>jaxb-api</artifactId>
265                    <version>2.3.0</version>
266             </dependency>
267             <!-- https://mvnrepository.com/artifact/org.javassist/javassist -->
268             <dependency>
269                    <groupId>org.javassist</groupId>
270                    <artifactId>javassist</artifactId>
271                    <version>3.24.1-GA</version>
272             </dependency>
273             <dependency>
274                     <groupId>org.apache.tomcat.embed</groupId>
275                     <artifactId>tomcat-embed-core</artifactId>
276                    <version>9.0.36</version>
277             </dependency>
278         </dependencies>
279
280                 <build>
281                 <plugins>
282
283                         <plugin>
284                                 <groupId>org.springframework.boot</groupId>
285                                 <artifactId>spring-boot-maven-plugin</artifactId>
286                                 <version>2.3.1.RELEASE</version>
287                                 <executions>
288                                         <execution>
289                                                 <goals>
290                                                         <goal>repackage</goal>
291                                                 </goals>
292                                         </execution>
293                                 </executions>
294                         </plugin>
295                         <plugin>
296                                 <groupId>com.spotify</groupId>
297                                 <artifactId>docker-maven-plugin</artifactId>
298                                 <configuration>
299                                         <serverId>${onap.nexus.dockerregistry.daily}</serverId>
300
301                                         <imageName>${onap.nexus.dockerregistry.daily}/${docker.image.name}</imageName>
302                                         <imageTags>
303                                                 <imageTag>${project.version}-${maven.build.timestamp}Z</imageTag>
304                                                 <imageTag>${project.version}</imageTag>
305                                                 <imageTag>latest</imageTag>
306                                         </imageTags>
307                                         <baseImage>openjdk:11.0.6-jre-slim</baseImage>
308                                         <user>sliceanalysis</user>
309                                         <resources>
310                                                 <resource>
311                                                         <targetPath>/bin</targetPath>
312                                                         <directory>${project.build.directory}</directory>
313                                                         <include>${project.artifactId}-${project.version}.jar</include>
314                                                 </resource>
315                                                 <resource>
316                                                         <targetPath>/bin</targetPath>
317                                                         <directory>${project.basedir}</directory>
318                                                         <include>entry.sh</include>
319                                                 </resource>
320                                         </resources>
321                                         <runs>
322                                                 <!-- Maven is loosing file permissions during artifacts copy -->
323                                                 <run>adduser --disabled-password sliceanalysis </run>
324                                                 <run>mv /bin/*.jar /bin/application.jar</run>
325                                                 <run>chmod -R 777 /bin</run>
326                                                 <run>chmod +x /bin/entry.sh</run>
327                                         </runs>
328                                         <exposes>
329                                                 <expose>8080</expose>
330                                         </exposes>
331                                         <entryPoint>./bin/entry.sh</entryPoint>
332                                 </configuration>
333                         </plugin>
334                 </plugins>
335         </build>
336
337 </project>