Servlet library provided
[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             <scope>provided</scope>
92         </dependency>
93         <!-- Springboot -->
94         <dependency>
95             <groupId>org.springframework.boot</groupId>
96             <artifactId>spring-boot-starter</artifactId>
97         </dependency>
98         <dependency>
99             <groupId>org.springframework.data</groupId>
100             <artifactId>spring-data-cassandra</artifactId>
101         </dependency>
102         <dependency>
103             <groupId>org.springframework.boot</groupId>
104             <artifactId>spring-boot-starter-jersey</artifactId>
105         </dependency>
106         <dependency>
107             <groupId>org.springframework.boot</groupId>
108             <artifactId>spring-boot-starter-web</artifactId>
109         </dependency>
110         <dependency>
111             <groupId>org.springframework.boot</groupId>
112             <artifactId>spring-boot-starter-tomcat</artifactId>
113         </dependency>
114         <dependency>
115             <groupId>org.springframework.boot</groupId>
116             <artifactId>spring-boot-starter-test</artifactId>
117             <scope>test</scope>
118         </dependency>
119         <dependency>
120             <groupId>org.springframework</groupId>
121             <artifactId>spring-aop</artifactId>
122             <scope>compile</scope>
123         </dependency>
124         <dependency>
125             <groupId>org.springframework.boot</groupId>
126             <artifactId>spring-boot-autoconfigure</artifactId>
127         </dependency>
128         <dependency>
129             <groupId>org.aspectj</groupId>
130             <artifactId>aspectjweaver</artifactId>
131             <scope>compile</scope>
132         </dependency>
133         <!-- Springboot -->
134         <dependency>
135           <groupId>org.onap.music</groupId>
136           <artifactId>MUSIC-core</artifactId>
137           <version>3.2.37-SNAPSHOT</version>
138         </dependency>
139         <!-- Jersey -->
140         <dependency>
141             <groupId>com.sun.jersey</groupId>
142             <artifactId>jersey-client</artifactId>
143             <version>${jersey1.version}</version>
144         </dependency>
145         <dependency>
146             <groupId>com.sun.jersey</groupId>
147             <artifactId>jersey-server</artifactId>
148             <version>${jersey1.version}</version>
149         </dependency>
150         <dependency>
151             <groupId>com.sun.jersey</groupId>
152             <artifactId>jersey-json</artifactId>
153             <version>${jersey1.version}</version>
154         </dependency>
155         <dependency>
156             <groupId>com.sun.jersey</groupId>
157             <artifactId>jersey-servlet</artifactId>
158             <version>${jersey1.version}</version>
159         </dependency>
160         <!-- /Jersey -->
161         <!-- Testing -->
162         <dependency>
163             <groupId>junit</groupId>
164             <artifactId>junit</artifactId>
165             <version>4.12</version>
166             <scope>test</scope>
167         </dependency>
168         <dependency>
169             <groupId>org.cassandraunit</groupId>
170             <artifactId>cassandra-unit-spring</artifactId>
171             <version>3.5.0.1</version>
172             <scope>test</scope>
173             <exclusions>
174                 <exclusion>
175                     <groupId>org.slf4j</groupId>
176                     <artifactId>slf4j-log4j12</artifactId>
177                 </exclusion>
178                 <exclusion>
179                     <groupId>ch.qos.logback</groupId>
180                     <artifactId>logback-core</artifactId>
181                 </exclusion>
182                 <exclusion>
183                     <groupId>ch.qos.logback</groupId>
184                     <artifactId>logback-classic</artifactId>
185                 </exclusion>
186                 <exclusion>
187                     <groupId>org.cassandraunit</groupId>
188                     <artifactId>cassandra-unit</artifactId>
189                 </exclusion>
190                 <exclusion>
191                     <groupId>io.dropwizard.metrics</groupId>
192                     <artifactId>metrics-core</artifactId>
193                 </exclusion>
194                 <exclusion>
195                     <groupId>com.addthis.metrics</groupId>
196                     <artifactId>reporter-config-base</artifactId>
197                 </exclusion>
198             </exclusions>
199         </dependency>
200         <dependency>
201             <groupId>org.cassandraunit</groupId>
202             <artifactId>cassandra-unit-shaded</artifactId>
203             <version>3.5.0.1</version>
204             <scope>test</scope>
205         </dependency>
206         <dependency>
207             <groupId>org.mockito</groupId>
208             <artifactId>mockito-core</artifactId>
209             <version>2.23.4</version>
210             <scope>test</scope>
211         </dependency>
212         <!--  /Testing -->
213     </dependencies>
214
215     <build>
216         <plugins>
217             <plugin>
218                 <groupId>org.springframework.boot</groupId>
219                 <artifactId>spring-boot-maven-plugin</artifactId>
220                 <version>2.1.1.RELEASE</version>
221                 <configuration>
222                     <mainClass>org.onap.music.MusicApplication</mainClass>
223                     <outputDirectory>${project.basedir}/distribution/music/</outputDirectory>
224                     <addResources>true</addResources>
225                     <finalName>MUSIC-SB</finalName>
226                 </configuration>
227                 <executions>
228                     <execution>
229                         <phase>package</phase>
230                         <goals>
231                             <goal>repackage</goal>
232                         </goals>
233                     </execution>
234                 </executions>
235             </plugin>
236         </plugins>
237         <pluginManagement><!-- lock down plugins versions to avoid using Maven defaults (may be moved to parent pom) -->
238             <plugins>
239                 <!-- clean lifecycle, see https://maven.apache.org/ref/current/maven-core/lifecycles.html#clean_Lifecycle -->
240                 <plugin>
241                     <artifactId>maven-clean-plugin</artifactId>
242                     <version>3.1.0</version>
243                 </plugin>
244                 <!-- default lifecycle, jar packaging: see https://maven.apache.org/ref/current/maven-core/default-bindings.html#Plugin_bindings_for_jar_packaging -->
245                 <plugin>
246                     <artifactId>maven-resources-plugin</artifactId>
247                     <version>3.0.2</version>
248                 </plugin>
249                 <plugin>
250                     <artifactId>maven-compiler-plugin</artifactId>
251                     <version>3.8.0</version>
252                 </plugin>
253                 <plugin>
254                     <artifactId>maven-surefire-plugin</artifactId>
255                     <version>2.22.1</version>
256                 </plugin>
257                 <plugin>
258                     <artifactId>maven-jar-plugin</artifactId>
259                     <version>3.0.2</version>
260                 </plugin>
261                 <plugin>
262                     <artifactId>maven-install-plugin</artifactId>
263                     <version>2.5.2</version>
264                 </plugin>
265                 <plugin>
266                     <artifactId>maven-deploy-plugin</artifactId>
267                     <version>2.8.2</version>
268                 </plugin>
269                 <!-- site lifecycle, see https://maven.apache.org/ref/current/maven-core/lifecycles.html#site_Lifecycle -->
270                 <plugin>
271                     <artifactId>maven-site-plugin</artifactId>
272                     <version>3.7.1</version>
273                 </plugin>
274                 <plugin>
275                     <artifactId>maven-project-info-reports-plugin</artifactId>
276                     <version>3.0.0</version>
277                 </plugin>
278             </plugins>
279         </pluginManagement>
280     </build>
281     <profiles>
282         <profile>
283             <id>docker</id>
284             <build>
285                 <plugins>
286                     <plugin>
287                         <groupId>io.fabric8</groupId>
288                         <artifactId>docker-maven-plugin</artifactId>
289                         <version>0.19.1</version>
290                         <configuration>
291                             <verbose>true</verbose>
292                             <apiVersion>1.23</apiVersion>
293                             <registry>nexus3.onap.org:10003</registry>
294                             <images>
295                                 <!-- MUSIC War -->
296                                 <image>
297                                     <name>onap/music/music_sb</name>
298                                     <alias>docker_music</alias>
299                                     <build>
300                                         <cleanup>true</cleanup>
301                                         <tags>
302                                             <tag>${docker.tag}</tag>
303                                             <tag>${docker.latest.tag}</tag>
304                                         </tags>
305                                         <dockerFileDir>${project.basedir}/distribution/music</dockerFileDir>
306                                     </build>
307                                 </image>
308                                 <!-- Cassandra -->
309                                 <image>
310                                     <name>onap/music/cassandra_3_11</name>
311                                     <alias>docker_cassandra_sec</alias>
312                                     <build>
313                                         <cleanup>true</cleanup>
314                                         <tags>
315                                             <tag>${docker.tag}</tag>
316                                             <tag>${docker.latest.tag}</tag>
317                                         </tags>
318                                         <dockerFileDir>${project.basedir}/distribution/cassandra</dockerFileDir>
319                                     </build>
320                                 </image>
321                                 <!-- Cassandra Job -->
322                                 <image>
323                                     <name>onap/music/cassandra_job</name>
324                                     <alias>docker_cassandra_job</alias>
325                                     <build>
326                                         <cleanup>true</cleanup>
327                                         <tags>
328                                             <tag>${docker.tag}</tag>
329                                             <tag>${docker.latest.tag}</tag>
330                                         </tags>
331                                         <dockerFileDir>${project.basedir}/distribution/cassandra_job</dockerFileDir>
332                                     </build>
333                                 </image>
334                             </images>
335                         </configuration>
336                         <executions>
337                             <execution>
338                                 <id>clean-images</id>
339                                 <phase>pre-clean</phase>
340                                 <goals>
341                                     <goal>remove</goal>
342                                 </goals>
343                                 <configuration>
344                                     <removeAll>true</removeAll>
345                                     <image>music</image>
346                                 </configuration>
347                             </execution>
348                             <execution>
349                                 <id>generate-images</id>
350                                 <phase>package</phase>
351                                 <goals>
352                                     <goal>build</goal>
353                                 </goals>
354                             </execution>
355                             <execution>
356                                 <id>push-images</id>
357                                 <phase>deploy</phase>
358                                 <goals>
359                                     <goal>push</goal>
360                                 </goals>
361                                 <configuration>
362                                     <image>onap/music/music</image>
363                                 </configuration>
364                             </execution>
365                         </executions>
366                     </plugin>
367                 </plugins>
368             </build>
369         </profile>
370         <profile>
371             <id>default</id>
372         </profile>
373     </profiles>
374 </project>