Merge "sonar-463 Immediately return this expression instead of assigning it to the...
[music.git] / 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</artifactId>
29     <packaging>jar</packaging>
30     <version>3.2.35-SNAPSHOT</version>
31     <description>
32             This is the MUSIC REST interface, packaged as a Springboot jar file.
33     </description>
34
35     <parent>
36         <groupId>org.onap.oparent</groupId>
37         <artifactId>oparent</artifactId>
38         <version>2.0.0</version>
39         <relativePath/>
40     </parent> 
41
42     <dependencyManagement>
43         <dependencies>
44             <!-- <dependency>
45                 <groupId>org.springframework.boot</groupId>
46                 <artifactId>spring-boot-starter-data-jpa</artifactId>
47                 <version>2.0.3.RELEASE</version>
48             </dependency> -->
49             <dependency>
50                 <groupId>org.springframework.boot</groupId>
51                 <artifactId>spring-boot-dependencies</artifactId>
52                 <version>2.1.1.RELEASE</version>
53                 <type>pom</type>
54                 <scope>import</scope>
55             </dependency>
56         </dependencies>
57     </dependencyManagement>
58     <properties>
59         <start-class>org.onap.music.MusicApplication</start-class>
60         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
61         <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
62         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
63         <java.version>1.8</java.version>
64         <jersey1.version>1.19</jersey1.version>
65         <jersey2.version>2.25.1</jersey2.version>
66         <jaxrs.version>2.0.1</jaxrs.version>
67         <cassandra.version>3.6.0</cassandra.version>
68
69         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
70         <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
71         <!--nexus -->
72         <nexusproxy>https://nexus.onap.org</nexusproxy>
73         <onap.nexus.url>https://nexus.onap.org</onap.nexus.url>
74         <snapshotNexusPath>/content/repositories/snapshots/</snapshotNexusPath>
75         <releaseNexusPath>/content/repositories/releases/</releaseNexusPath>
76         <stagingNexusPath>/content/repositories/staging/</stagingNexusPath>
77         <sitePath>/content/sites/site/org/onap/music/${project.version}</sitePath>
78         <!--maven -->
79         <timestamp>${maven.build.timestamp}</timestamp>
80         <maven.build.timestamp.format>yyyy.MM.dd.HH.mm</maven.build.timestamp.format>
81         <!--skip checkstyle -->
82         <maven.check.skip>false</maven.check.skip>
83         <!--docker -->
84         <docker.tag>${project.version}-${timestamp}</docker.tag>
85         <docker.latest.tag>${project.version}-latest</docker.latest.tag>
86         <maven.compiler.source>1.8</maven.compiler.source>
87         <maven.compiler.target>1.8</maven.compiler.target>
88     </properties>
89
90     <repositories>
91         <repository>
92             <id>onap-releases</id>
93             <name>ONAP - Release Repository</name>
94             <url>${nexusproxy}/${releaseNexusPath}</url>
95         </repository>
96         <repository>
97             <id>onap-staging</id>
98             <name>ONAP - Staging Repository</name>
99             <url>${nexusproxy}/${stagingNexusPath}</url>
100         </repository>
101         <repository>
102             <id>onap-snapshots</id>
103             <name>ONAP - Snapshot Repository</name>
104             <url>${nexusproxy}/${snapshotNexusPath}</url>
105         </repository>
106         <repository>
107             <id>onap-public</id>
108             <name>ONAP public Repository</name>
109             <url>${nexusproxy}/content/groups/public</url>
110         </repository>
111     </repositories>
112
113     <build>
114         <finalName>${project.artifactId}</finalName>
115         <sourceDirectory>src/main/java</sourceDirectory>
116         <outputDirectory>src/main/webapp/WEB-INF/classes</outputDirectory>
117         <testSourceDirectory>src/test/java</testSourceDirectory>
118         <testOutputDirectory>target/test-classes</testOutputDirectory>
119         <defaultGoal>validate</defaultGoal>
120         <resources>
121             <resource>
122                 <directory>src/main/resources</directory>
123                 <filtering>true</filtering>
124                 <includes>
125                 <include>**/*.properties</include>
126                 <include>**/*.xml</include>
127                 <include>**/*.ccf</include>
128                 </includes>
129             </resource>
130         </resources>
131         <testResources>
132             <testResource>
133                 <directory>${project.basedir}/src/test/resources</directory>
134             </testResource>
135             <!-- <testResource>
136                 <directory>${project.basedir}/src/main/resources</directory>
137             </testResource> -->
138         </testResources>
139         <plugins>
140             <plugin>
141                 <groupId>org.springframework.boot</groupId>
142                 <artifactId>spring-boot-maven-plugin</artifactId>
143                 <version>2.1.1.RELEASE</version>
144                 <configuration>
145                     <mainClass>org.onap.music.MusicApplication</mainClass>
146                     <outputDirectory>./distribution/music/</outputDirectory>
147                     <addResources>true</addResources>
148                     <finalName>${project.artifactId}-SB</finalName>
149                 </configuration>
150                 <executions>
151                     <execution>
152                         <goals>
153                             <goal>repackage</goal>
154                         </goals>
155                     </execution>
156                 </executions>
157             </plugin>
158 <!--
159             <plugin>
160                 <artifactId>maven-war-plugin</artifactId>
161                 <version>2.4</version>
162                 <configuration>
163                     <warSourceDirectory>WebContent</warSourceDirectory>
164                     <failOnMissingWebXml>false</failOnMissingWebXml>
165                 </configuration>
166             </plugin>
167 -->
168             <plugin>
169                 <groupId>org.apache.maven.plugins</groupId>
170                 <artifactId>maven-checkstyle-plugin</artifactId>
171                 <configuration>
172                     <skip>${maven.check.skip}</skip>
173                 </configuration>
174             </plugin>
175
176             <plugin>
177                 <groupId>org.apache.maven.plugins</groupId>
178                 <artifactId>maven-jar-plugin</artifactId>
179                 <version>2.4</version>
180                 <executions>
181                     <execution>
182                         <id>make-a-jar</id>
183                         <phase>compile</phase>
184                         <goals>
185                             <goal>jar</goal>
186                         </goals>
187                         <configuration>
188                             <excludes>
189                                 <!--<exclude>**/*.xml</exclude>
190                                 <exclude>**/*.properties</exclude>-->
191                                 <exclude>**/Sample*</exclude>
192                             </excludes>
193                         </configuration>
194                     </execution>
195                 </executions>
196             </plugin>
197             <plugin>
198                 <groupId>org.apache.maven.plugins</groupId>
199                 <artifactId>maven-install-plugin</artifactId>
200                 <version>2.4</version>
201                 <executions>
202                     <execution>
203                         <phase>install</phase>
204                         <goals>
205                             <goal>install-file</goal>
206                         </goals>
207                         <configuration>
208                             <packaging>jar</packaging>
209                             <artifactId>${project.artifactId}</artifactId>
210                             <groupId>${project.groupId}</groupId>
211                             <version>${project.version}</version>
212                             <file>${project.build.directory}/${project.artifactId}.jar</file>
213                         </configuration>
214                     </execution>
215                 </executions>
216             </plugin>
217         </plugins>
218     </build>
219
220     <dependencies>
221         <!-- Springboot -->
222         <dependency>
223             <groupId>org.springframework.boot</groupId>
224             <artifactId>spring-boot-starter</artifactId>
225         </dependency>
226         <dependency>
227             <groupId>org.springframework.data</groupId>
228             <artifactId>spring-data-cassandra</artifactId>
229         </dependency>
230         <dependency>
231             <groupId>org.springframework.boot</groupId>
232             <artifactId>spring-boot-starter-jersey</artifactId>
233         </dependency>
234         <dependency>
235             <groupId>org.springframework.boot</groupId>
236             <artifactId>spring-boot-starter-web</artifactId>
237         </dependency>
238         <dependency>
239             <groupId>org.springframework.boot</groupId>
240             <artifactId>spring-boot-starter-tomcat</artifactId>
241         </dependency>
242         <dependency>
243             <groupId>org.springframework.boot</groupId>
244             <artifactId>spring-boot-starter-test</artifactId>
245             <scope>test</scope>
246         </dependency>
247         <dependency>
248             <groupId>org.springframework</groupId>
249             <artifactId>spring-aop</artifactId>
250             <scope>compile</scope>
251         </dependency>
252         <dependency>
253             <groupId>org.springframework.boot</groupId>
254             <artifactId>spring-boot-autoconfigure</artifactId>
255         </dependency>
256         <dependency>
257             <groupId>org.aspectj</groupId>
258             <artifactId>aspectjweaver</artifactId>
259             <scope>compile</scope>
260         </dependency>
261         <!-- Springboot -->
262         <!-- Development -->
263         <dependency>
264             <groupId>javax.servlet</groupId>
265             <artifactId>servlet-api</artifactId>
266             <version>2.4</version>
267             <scope>provided</scope>
268         </dependency>
269         <dependency>
270             <groupId>javax.servlet</groupId>
271             <artifactId>javax.servlet-api</artifactId>
272             <version>3.0.1</version>
273             <scope>provided</scope>
274         </dependency>
275         <!-- /Development -->
276         <!-- Logging -->
277         <dependency>
278             <groupId>ch.qos.logback</groupId>
279             <artifactId>logback-core</artifactId>
280             <version>1.2.3</version>
281             <exclusions>
282                 <exclusion>
283                     <groupId>org.slf4j</groupId>
284                     <artifactId>slf4j-log4j12</artifactId>
285                 </exclusion>
286             </exclusions>
287         </dependency>
288         <dependency>
289             <groupId>ch.qos.logback</groupId>
290             <artifactId>logback-classic</artifactId>
291             <version>1.2.3</version>
292             <exclusions>
293                 <exclusion>
294                     <groupId>org.slf4j</groupId>
295                     <artifactId>slf4j-log4j12</artifactId>
296                 </exclusion>
297             </exclusions>
298         </dependency>
299         <dependency>
300             <groupId>com.att.eelf</groupId>
301             <artifactId>eelf-core</artifactId>
302             <version>1.0.1-oss</version>
303             <exclusions>
304                 <exclusion>
305                     <groupId>org.powermock</groupId>
306                     <artifactId>powermock-api-mockito</artifactId>
307                 </exclusion>
308                 <exclusion>
309                     <groupId>org.powermock</groupId>
310                     <artifactId>powermock-module-junit4</artifactId>
311                 </exclusion>
312             </exclusions>
313         </dependency>
314         <!-- End Logging -->
315         <!-- Cassandra -->
316         <dependency>
317             <groupId>io.dropwizard.metrics</groupId>
318             <artifactId>metrics-core</artifactId>
319             <version>4.1.0-rc3</version>
320         </dependency>
321         <dependency>
322             <groupId>com.datastax.cassandra</groupId>
323             <artifactId>cassandra-driver-core</artifactId>
324             <version>${cassandra.version}</version>
325         </dependency> 
326         <!-- /Cassandra -->
327         <!-- Jersey -->
328         <dependency>
329             <groupId>com.sun.jersey</groupId>
330             <artifactId>jersey-client</artifactId>
331             <version>${jersey1.version}</version>
332         </dependency>
333         <dependency>
334             <groupId>com.sun.jersey</groupId>
335             <artifactId>jersey-server</artifactId>
336             <version>${jersey1.version}</version>
337         </dependency>
338         <dependency>
339             <groupId>com.sun.jersey</groupId>
340             <artifactId>jersey-json</artifactId>
341             <version>${jersey1.version}</version>
342         </dependency>
343         <dependency>
344             <groupId>com.sun.jersey</groupId>
345             <artifactId>jersey-servlet</artifactId>
346             <version>${jersey1.version}</version>
347         </dependency>
348         <!-- /Jersey -->
349
350         <dependency>
351             <groupId>org.apache.commons</groupId>
352             <artifactId>commons-jcs-core</artifactId>
353             <version>2.2</version>
354         </dependency>
355         <dependency>
356             <groupId>commons-codec</groupId>
357             <artifactId>commons-codec</artifactId>
358             <version>1.11</version>
359         </dependency>
360         <dependency>
361             <groupId>org.apache.commons</groupId>
362             <artifactId>commons-lang3</artifactId>
363             <version>3.8</version>
364         </dependency>
365
366         <!-- Testing -->
367         <dependency>
368             <groupId>junit</groupId>
369             <artifactId>junit</artifactId>
370             <version>4.12</version>
371             <scope>test</scope>
372         </dependency>
373         <dependency>
374             <groupId>org.cassandraunit</groupId>
375             <artifactId>cassandra-unit-spring</artifactId>
376             <version>3.5.0.1</version>
377             <scope>test</scope>
378             <exclusions>
379                 <exclusion>
380                     <groupId>org.slf4j</groupId>
381                     <artifactId>slf4j-log4j12</artifactId>
382                 </exclusion>
383                 <exclusion>
384                     <groupId>ch.qos.logback</groupId>
385                     <artifactId>logback-core</artifactId>
386                 </exclusion>
387                 <exclusion>
388                     <groupId>ch.qos.logback</groupId>
389                     <artifactId>logback-classic</artifactId>
390                 </exclusion>
391                 <exclusion>
392                     <groupId>org.cassandraunit</groupId>
393                     <artifactId>cassandra-unit</artifactId>
394                 </exclusion>
395                 <exclusion>
396                     <groupId>io.dropwizard.metrics</groupId>
397                     <artifactId>metrics-core</artifactId>
398                 </exclusion>
399                 <exclusion>
400                     <groupId>com.addthis.metrics</groupId>
401                     <artifactId>reporter-config-base</artifactId>
402                 </exclusion>
403             </exclusions>
404         </dependency>
405         <dependency>
406             <groupId>org.cassandraunit</groupId>
407             <artifactId>cassandra-unit-shaded</artifactId>
408             <version>3.5.0.1</version>
409             <scope>test</scope>
410         </dependency>
411         <dependency>
412             <groupId>org.mockito</groupId>
413             <artifactId>mockito-core</artifactId>
414             <version>2.23.4</version>
415             <scope>test</scope>
416         </dependency>
417         <!--  /Testing -->
418
419         <!-- https://mvnrepository.com/artifact/com.fasterxml.jackson.datatype/jackson-datatype-jsr310 -->
420         <dependency>
421             <groupId>com.fasterxml.jackson.datatype</groupId>
422             <artifactId>jackson-datatype-jsr310</artifactId>
423             <version>2.9.8</version>
424         </dependency>
425         <dependency>
426             <groupId>com.fasterxml.jackson.core</groupId>
427             <artifactId>jackson-databind</artifactId>
428             <version>2.9.8</version>
429         </dependency>
430         <dependency>
431             <groupId>com.fasterxml.jackson.core</groupId>
432             <artifactId>jackson-core</artifactId>
433             <version>2.9.8</version>
434         </dependency>
435         <dependency>
436             <groupId>com.fasterxml.jackson.core</groupId>
437             <artifactId>jackson-annotations</artifactId>
438             <version>2.9.8</version>
439         </dependency>
440         <dependency>
441             <groupId>org.apache.httpcomponents</groupId>
442             <artifactId>httpclient</artifactId>
443         </dependency>
444         <dependency>
445             <groupId>io.swagger</groupId>
446             <artifactId>swagger-jersey-jaxrs</artifactId>
447             <version>1.5.22</version>
448         </dependency>
449         <dependency>
450             <groupId>com.google.guava</groupId>
451             <artifactId>guava</artifactId>
452         </dependency>
453         <dependency>
454             <groupId>de.svenkubiak</groupId>
455             <artifactId>jBCrypt</artifactId>
456             <version>0.4.1</version>
457         </dependency>
458         <dependency>
459             <groupId>io.netty</groupId>
460             <artifactId>netty-handler</artifactId>
461             <version>4.1.33.Final</version>
462         </dependency>
463         <dependency>
464             <groupId>io.netty</groupId>
465             <artifactId>netty-buffer</artifactId>
466             <version>4.1.33.Final</version>
467         </dependency>
468         <dependency>
469             <groupId>io.netty</groupId>
470             <artifactId>netty-codec</artifactId>
471             <version>4.1.33.Final</version>
472         </dependency>
473         <dependency>
474             <groupId>io.netty</groupId>
475             <artifactId>netty-common</artifactId>
476             <version>4.1.33.Final</version>
477         </dependency>
478         <dependency>
479             <groupId>io.netty</groupId>
480             <artifactId>netty-resolver</artifactId>
481             <version>4.1.33.Final</version>
482         </dependency>
483         <dependency>
484             <groupId>io.netty</groupId>
485             <artifactId>netty-transport</artifactId>
486             <version>4.1.33.Final</version>
487         </dependency>
488         <dependency>
489             <groupId>org.onap.aaf.authz</groupId>
490             <artifactId>aaf-cadi-aaf</artifactId>
491             <version>2.1.7</version>
492             <exclusions>
493                 <exclusion>
494                     <groupId>log4j</groupId>
495                     <artifactId>log4j</artifactId>
496                 </exclusion>
497             </exclusions>
498         </dependency>
499         <dependency>
500             <groupId>org.onap.aaf.authz</groupId>
501             <artifactId>aaf-cadi-client</artifactId>
502             <version>2.1.7</version>
503         </dependency>
504         <dependency>
505             <groupId>org.onap.aaf.authz</groupId>
506             <artifactId>aaf-cadi-core</artifactId>
507             <version>2.1.7</version>
508         </dependency>
509         <dependency>
510             <groupId>com.google.code.gson</groupId>
511             <artifactId>gson</artifactId>
512             <version>2.8.5</version>
513         </dependency>
514     </dependencies>
515
516     <reporting>
517         <plugins>
518             <plugin>
519                 <groupId>org.apache.maven.plugins</groupId>
520                 <artifactId>maven-javadoc-plugin</artifactId>
521                 <version>2.10.3</version>
522                 <configuration>
523                     <author>true</author>
524                     <breakiterator>true</breakiterator>
525                     <version>true</version>
526                     <links>
527                         <link>https://docs.oracle.com/javase/7/docs/api/</link>
528                         <link>https://tomcat.apache.org/tomcat-7.0-doc/jspapi/</link>
529                         <link>http://docs.oracle.com/javaee/7/api/</link>
530                     </links>
531                 </configuration>
532             </plugin>
533             <plugin>
534                 <groupId>org.apache.maven.plugins</groupId>
535                 <artifactId>maven-compiler-plugin</artifactId>
536                 <configuration>
537                     <source>1.8</source>
538                     <target>1.8</target>
539                 </configuration>
540             </plugin>
541         </plugins>
542     </reporting>
543
544     <profiles>
545         <profile>
546             <id>docker</id>
547             <build>
548                 <plugins>
549                     <plugin>
550                         <groupId>io.fabric8</groupId>
551                         <artifactId>docker-maven-plugin</artifactId>
552                         <version>0.19.1</version>
553                         <configuration>
554                             <verbose>true</verbose>
555                             <apiVersion>1.23</apiVersion>
556                             <registry>nexus3.onap.org:10003</registry>
557                             <images>
558                                 <!-- MUSIC War -->
559                                 <image>
560                                     <name>onap/music/music_sb</name>
561                                     <alias>docker_music</alias>
562                                     <build>
563                                         <cleanup>true</cleanup>
564                                         <tags>
565                                             <tag>${docker.tag}</tag>
566                                             <tag>${docker.latest.tag}</tag>
567                                         </tags>
568                                         <dockerFileDir>${project.basedir}/distribution/music</dockerFileDir>
569 <!--                                    <assembly>
570                                             <descriptorRef>artifact</descriptorRef>
571                                         </assembly>  -->
572                                     </build>
573                                 </image>
574                                 <!-- Cassandra -->
575                                 <image>
576                                     <name>onap/music/cassandra_3_11</name>
577                                     <alias>docker_cassandra_sec</alias>
578                                     <build>
579                                         <cleanup>true</cleanup>
580                                         <tags>
581                                             <tag>${docker.tag}</tag>
582                                             <tag>${docker.latest.tag}</tag>
583                                         </tags>
584                                         <dockerFileDir>${project.basedir}/distribution/cassandra</dockerFileDir>
585                                     </build>
586                                 </image>
587                                 <!-- Cassandra Job -->
588                                 <image>
589                                     <name>onap/music/cassandra_job</name>
590                                     <alias>docker_cassandra_job</alias>
591                                     <build>
592                                         <cleanup>true</cleanup>
593                                         <tags>
594                                             <tag>${docker.tag}</tag>
595                                             <tag>${docker.latest.tag}</tag>
596                                         </tags>
597                                         <dockerFileDir>${project.basedir}/distribution/cassandra_job</dockerFileDir>
598                                     </build>
599                                 </image>
600                                 <!-- tomcat 8.5 -->
601                                 <!-- <image> <name>onap/music/tomcat_music</name>
602                                     <alias>docker_tomcat</alias> <build> <cleanup>true</cleanup> <tags> <tag>8.5-${timestamp}</tag>
603                                     <tag>8.5-latest</tag> </tags> <dockerFileDir>${project.basedir}/distribution/tomcat</dockerFileDir>
604                                     </build> </image>\ -->
605                             </images>
606                         </configuration>
607                         <executions>
608                             <execution>
609                                 <id>clean-images</id>
610                                 <phase>pre-clean</phase>
611                                 <goals>
612                                     <goal>remove</goal>
613                                 </goals>
614                                 <configuration>
615                                     <removeAll>true</removeAll>
616                                     <image>music</image>
617                                 </configuration>
618                             </execution>
619                             <execution>
620                                 <id>generate-images</id>
621                                 <phase>package</phase>
622                                 <goals>
623                                     <goal>build</goal>
624                                 </goals>
625                             </execution>
626                             <execution>
627                                 <id>push-images</id>
628                                 <phase>deploy</phase>
629                                 <goals>
630                                     <goal>push</goal>
631                                 </goals>
632                                 <configuration>
633                                     <image>onap/music/music</image>
634                                 </configuration>
635                             </execution>
636                         </executions>
637                     </plugin>
638                 </plugins>
639             </build>
640         </profile>
641         <profile> 
642             <id>default</id> 
643         </profile>
644     </profiles>
645     <distributionManagement>
646         <repository>
647             <id>ecomp-releases</id>
648             <name>Release Repository</name>
649             <url>${nexusproxy}/${releaseNexusPath}</url>
650         </repository>
651         <snapshotRepository>
652             <id>ecomp-snapshots</id>
653             <name>Snapshot Repository</name>
654             <url>${nexusproxy}/${snapshotNexusPath}</url>
655         </snapshotRepository>
656         <!-- added for javadoc -->
657         <site>
658             <id>ecomp-site</id>
659             <url>dav:${nexusproxy}${sitePath}</url>
660         </site>
661     </distributionManagement>
662 </project>