Migrate servlet libraries
[music.git] / music-rest / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3  ============LICENSE_START==========================================
4  org.onap.music
5  ===================================================================
6   Copyright (c) 2017 AT&T Intellectual Property
7  ===================================================================
8   Modifications Copyright (c) 2019 IBM.
9  ===================================================================
10   Licensed under the Apache License, Version 2.0 (the "License");
11   you may not use this file except in compliance with the License.
12   You may obtain a copy of the License at
13
14      http://www.apache.org/licenses/LICENSE-2.0
15
16   Unless required by applicable law or agreed to in writing, software
17   distributed under the License is distributed on an "AS IS" BASIS,
18   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19   See the License for the specific language governing permissions and
20   limitations under the License.
21
22  ============LICENSE_END=============================================
23  ====================================================================
24 -->
25 <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">
26     <modelVersion>4.0.0</modelVersion>
27     <groupId>org.onap.music</groupId>
28     <artifactId>MUSIC-rest</artifactId>
29     <packaging>jar</packaging>
30     <version>3.2.37-SNAPSHOT</version>
31     <description>
32             This is the MUSIC Spring-based REST service.
33     </description>
34     <name>music-rest</name>
35
36     <parent>
37         <groupId>org.onap.music</groupId>
38         <artifactId>MUSIC</artifactId>
39         <version>3.2.37-SNAPSHOT</version>
40     </parent>
41
42     <properties>
43         <start-class>org.onap.music.MusicApplication</start-class>
44         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
45         <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
46         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
47         <java.version>1.8</java.version>
48         <jersey1.version>1.19</jersey1.version>
49         <jersey2.version>2.25.1</jersey2.version>
50         <jaxrs.version>2.0.1</jaxrs.version>
51
52         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
53         <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
54         <!--nexus -->
55         <nexusproxy>https://nexus.onap.org</nexusproxy>
56         <onap.nexus.url>https://nexus.onap.org</onap.nexus.url>
57         <snapshotNexusPath>/content/repositories/snapshots/</snapshotNexusPath>
58         <releaseNexusPath>/content/repositories/releases/</releaseNexusPath>
59         <stagingNexusPath>/content/repositories/staging/</stagingNexusPath>
60         <sitePath>/content/sites/site/org/onap/music/${project.version}</sitePath>
61         <!--maven -->
62         <timestamp>${maven.build.timestamp}</timestamp>
63         <maven.build.timestamp.format>yyyy.MM.dd.HH.mm</maven.build.timestamp.format>
64         <!--skip checkstyle -->
65         <maven.check.skip>false</maven.check.skip>
66         <!--docker -->
67         <docker.tag>${project.version}-${timestamp}</docker.tag>
68         <docker.latest.tag>${project.version}-latest</docker.latest.tag>
69         <maven.compiler.source>1.8</maven.compiler.source>
70         <maven.compiler.target>1.8</maven.compiler.target>
71     </properties>
72
73     <dependencyManagement>
74         <dependencies>
75             <dependency>
76                 <groupId>org.springframework.boot</groupId>
77                 <artifactId>spring-boot-dependencies</artifactId>
78                 <version>2.1.1.RELEASE</version>
79                 <type>pom</type>
80                 <scope>import</scope>
81             </dependency>
82         </dependencies>
83     </dependencyManagement>
84
85     <dependencies>
86         <!-- Development -->
87         <dependency>
88             <groupId>javax.servlet</groupId>
89             <artifactId>javax.servlet-api</artifactId>
90             <version>4.0.1</version>
91         </dependency>
92         <!-- Springboot -->
93         <dependency>
94             <groupId>org.springframework.boot</groupId>
95             <artifactId>spring-boot-starter</artifactId>
96         </dependency>
97         <dependency>
98             <groupId>org.springframework.data</groupId>
99             <artifactId>spring-data-cassandra</artifactId>
100         </dependency>
101         <dependency>
102             <groupId>org.springframework.boot</groupId>
103             <artifactId>spring-boot-starter-jersey</artifactId>
104         </dependency>
105         <dependency>
106             <groupId>org.springframework.boot</groupId>
107             <artifactId>spring-boot-starter-web</artifactId>
108         </dependency>
109         <dependency>
110             <groupId>org.springframework.boot</groupId>
111             <artifactId>spring-boot-starter-tomcat</artifactId>
112         </dependency>
113         <dependency>
114             <groupId>org.springframework.boot</groupId>
115             <artifactId>spring-boot-starter-test</artifactId>
116             <scope>test</scope>
117         </dependency>
118         <dependency>
119             <groupId>org.springframework</groupId>
120             <artifactId>spring-aop</artifactId>
121             <scope>compile</scope>
122         </dependency>
123         <dependency>
124             <groupId>org.springframework.boot</groupId>
125             <artifactId>spring-boot-autoconfigure</artifactId>
126         </dependency>
127         <dependency>
128             <groupId>org.aspectj</groupId>
129             <artifactId>aspectjweaver</artifactId>
130             <scope>compile</scope>
131         </dependency>
132         <!-- Springboot -->
133         <dependency>
134           <groupId>org.onap.music</groupId>
135           <artifactId>MUSIC-core</artifactId>
136           <version>3.2.37-SNAPSHOT</version>
137         </dependency>
138         <!-- Jersey -->
139         <dependency>
140             <groupId>com.sun.jersey</groupId>
141             <artifactId>jersey-client</artifactId>
142             <version>${jersey1.version}</version>
143         </dependency>
144         <dependency>
145             <groupId>com.sun.jersey</groupId>
146             <artifactId>jersey-server</artifactId>
147             <version>${jersey1.version}</version>
148         </dependency>
149         <dependency>
150             <groupId>com.sun.jersey</groupId>
151             <artifactId>jersey-json</artifactId>
152             <version>${jersey1.version}</version>
153         </dependency>
154         <dependency>
155             <groupId>com.sun.jersey</groupId>
156             <artifactId>jersey-servlet</artifactId>
157             <version>${jersey1.version}</version>
158         </dependency>
159         <!-- /Jersey -->
160         <!-- Testing -->
161         <dependency>
162             <groupId>junit</groupId>
163             <artifactId>junit</artifactId>
164             <version>4.12</version>
165             <scope>test</scope>
166         </dependency>
167         <dependency>
168             <groupId>org.cassandraunit</groupId>
169             <artifactId>cassandra-unit-spring</artifactId>
170             <version>3.5.0.1</version>
171             <scope>test</scope>
172             <exclusions>
173                 <exclusion>
174                     <groupId>org.slf4j</groupId>
175                     <artifactId>slf4j-log4j12</artifactId>
176                 </exclusion>
177                 <exclusion>
178                     <groupId>ch.qos.logback</groupId>
179                     <artifactId>logback-core</artifactId>
180                 </exclusion>
181                 <exclusion>
182                     <groupId>ch.qos.logback</groupId>
183                     <artifactId>logback-classic</artifactId>
184                 </exclusion>
185                 <exclusion>
186                     <groupId>org.cassandraunit</groupId>
187                     <artifactId>cassandra-unit</artifactId>
188                 </exclusion>
189                 <exclusion>
190                     <groupId>io.dropwizard.metrics</groupId>
191                     <artifactId>metrics-core</artifactId>
192                 </exclusion>
193                 <exclusion>
194                     <groupId>com.addthis.metrics</groupId>
195                     <artifactId>reporter-config-base</artifactId>
196                 </exclusion>
197             </exclusions>
198         </dependency>
199         <dependency>
200             <groupId>org.cassandraunit</groupId>
201             <artifactId>cassandra-unit-shaded</artifactId>
202             <version>3.5.0.1</version>
203             <scope>test</scope>
204         </dependency>
205         <dependency>
206             <groupId>org.mockito</groupId>
207             <artifactId>mockito-core</artifactId>
208             <version>2.23.4</version>
209             <scope>test</scope>
210         </dependency>
211         <!--  /Testing -->
212     </dependencies>
213
214     <build>
215         <plugins>
216             <plugin>
217                 <groupId>org.springframework.boot</groupId>
218                 <artifactId>spring-boot-maven-plugin</artifactId>
219                 <version>2.1.1.RELEASE</version>
220                 <configuration>
221                     <mainClass>org.onap.music.MusicApplication</mainClass>
222                     <outputDirectory>${project.basedir}/distribution/music/</outputDirectory>
223                     <addResources>true</addResources>
224                     <finalName>MUSIC-SB</finalName>
225                 </configuration>
226                 <executions>
227                     <execution>
228                         <phase>package</phase>
229                         <goals>
230                             <goal>repackage</goal>
231                         </goals>
232                     </execution>
233                 </executions>
234             </plugin>
235         </plugins>
236         <pluginManagement><!-- lock down plugins versions to avoid using Maven defaults (may be moved to parent pom) -->
237             <plugins>
238                 <!-- clean lifecycle, see https://maven.apache.org/ref/current/maven-core/lifecycles.html#clean_Lifecycle -->
239                 <plugin>
240                     <artifactId>maven-clean-plugin</artifactId>
241                     <version>3.1.0</version>
242                 </plugin>
243                 <!-- default lifecycle, jar packaging: see https://maven.apache.org/ref/current/maven-core/default-bindings.html#Plugin_bindings_for_jar_packaging -->
244                 <plugin>
245                     <artifactId>maven-resources-plugin</artifactId>
246                     <version>3.0.2</version>
247                 </plugin>
248                 <plugin>
249                     <artifactId>maven-compiler-plugin</artifactId>
250                     <version>3.8.0</version>
251                 </plugin>
252                 <plugin>
253                     <artifactId>maven-surefire-plugin</artifactId>
254                     <version>2.22.1</version>
255                 </plugin>
256                 <plugin>
257                     <artifactId>maven-jar-plugin</artifactId>
258                     <version>3.0.2</version>
259                 </plugin>
260                 <plugin>
261                     <artifactId>maven-install-plugin</artifactId>
262                     <version>2.5.2</version>
263                 </plugin>
264                 <plugin>
265                     <artifactId>maven-deploy-plugin</artifactId>
266                     <version>2.8.2</version>
267                 </plugin>
268                 <!-- site lifecycle, see https://maven.apache.org/ref/current/maven-core/lifecycles.html#site_Lifecycle -->
269                 <plugin>
270                     <artifactId>maven-site-plugin</artifactId>
271                     <version>3.7.1</version>
272                 </plugin>
273                 <plugin>
274                     <artifactId>maven-project-info-reports-plugin</artifactId>
275                     <version>3.0.0</version>
276                 </plugin>
277             </plugins>
278         </pluginManagement>
279     </build>
280     <profiles>
281         <profile>
282             <id>docker</id>
283             <build>
284                 <plugins>
285                     <plugin>
286                         <groupId>io.fabric8</groupId>
287                         <artifactId>docker-maven-plugin</artifactId>
288                         <version>0.19.1</version>
289                         <configuration>
290                             <verbose>true</verbose>
291                             <apiVersion>1.23</apiVersion>
292                             <registry>nexus3.onap.org:10003</registry>
293                             <images>
294                                 <!-- MUSIC War -->
295                                 <image>
296                                     <name>onap/music/music_sb</name>
297                                     <alias>docker_music</alias>
298                                     <build>
299                                         <cleanup>true</cleanup>
300                                         <tags>
301                                             <tag>${docker.tag}</tag>
302                                             <tag>${docker.latest.tag}</tag>
303                                         </tags>
304                                         <dockerFileDir>${project.basedir}/distribution/music</dockerFileDir>
305                                     </build>
306                                 </image>
307                                 <!-- Cassandra -->
308                                 <image>
309                                     <name>onap/music/cassandra_3_11</name>
310                                     <alias>docker_cassandra_sec</alias>
311                                     <build>
312                                         <cleanup>true</cleanup>
313                                         <tags>
314                                             <tag>${docker.tag}</tag>
315                                             <tag>${docker.latest.tag}</tag>
316                                         </tags>
317                                         <dockerFileDir>${project.basedir}/distribution/cassandra</dockerFileDir>
318                                     </build>
319                                 </image>
320                                 <!-- Cassandra Job -->
321                                 <image>
322                                     <name>onap/music/cassandra_job</name>
323                                     <alias>docker_cassandra_job</alias>
324                                     <build>
325                                         <cleanup>true</cleanup>
326                                         <tags>
327                                             <tag>${docker.tag}</tag>
328                                             <tag>${docker.latest.tag}</tag>
329                                         </tags>
330                                         <dockerFileDir>${project.basedir}/distribution/cassandra_job</dockerFileDir>
331                                     </build>
332                                 </image>
333                             </images>
334                         </configuration>
335                         <executions>
336                             <execution>
337                                 <id>clean-images</id>
338                                 <phase>pre-clean</phase>
339                                 <goals>
340                                     <goal>remove</goal>
341                                 </goals>
342                                 <configuration>
343                                     <removeAll>true</removeAll>
344                                     <image>music</image>
345                                 </configuration>
346                             </execution>
347                             <execution>
348                                 <id>generate-images</id>
349                                 <phase>package</phase>
350                                 <goals>
351                                     <goal>build</goal>
352                                 </goals>
353                             </execution>
354                             <execution>
355                                 <id>push-images</id>
356                                 <phase>deploy</phase>
357                                 <goals>
358                                     <goal>push</goal>
359                                 </goals>
360                                 <configuration>
361                                     <image>onap/music/music</image>
362                                 </configuration>
363                             </execution>
364                         </executions>
365                     </plugin>
366                 </plugins>
367             </build>
368         </profile>
369         <profile>
370             <id>default</id>
371         </profile>
372     </profiles>
373 </project>