Merge "Update schema-service dep to 1.6.0"
[aai/gizmo.git] / pom.xml
1 <!--
2 ============LICENSE_START=======================================================
3 org.onap.aai
4 ================================================================================
5 Copyright © 2017-2018 AT&T Intellectual Property. All rights reserved.
6 Copyright © 2017-2018 Amdocs
7 ================================================================================
8 Licensed under the Apache License, Version 2.0 (the "License");
9 you may not use this file except in compliance with the License.
10 You may obtain a copy of the License at
11
12       http://www.apache.org/licenses/LICENSE-2.0
13
14 Unless required by applicable law or agreed to in writing, software
15 distributed under the License is distributed on an "AS IS" BASIS,
16 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 See the License for the specific language governing permissions and
18 limitations under the License.
19 ============LICENSE_END=========================================================
20 -->
21 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
22          xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
23     <modelVersion>4.0.0</modelVersion>
24
25     <parent>
26         <groupId>org.onap.oparent</groupId>
27         <artifactId>oparent</artifactId>
28         <version>2.0.0</version>
29         <relativePath/>
30     </parent>
31
32     <groupId>org.onap.aai.gizmo</groupId>
33     <artifactId>gizmo</artifactId>
34     <version>1.6.0-SNAPSHOT</version>
35     <name>aai-gizmo</name>
36
37     <properties>
38         <docker.location>${basedir}/target</docker.location>
39         <version.org.onap.aai.aai-schema-ingest>1.4.1</version.org.onap.aai.aai-schema-ingest>
40         <version.org.onap.aai.aai-schema>1.6.0</version.org.onap.aai.aai-schema>
41         <version.org.onap.aai.aai-utils>1.5.3</version.org.onap.aai.aai-utils>
42         <version.org.onap.aai.aai-auth>1.5.3</version.org.onap.aai.aai-auth>
43         <event.client.version>1.5.0</event.client.version>
44         <!-- Minimum code coverage percentage. Please update this figure as coverage increases to prevent any drops in
45          coverage caused by new changes. Note that this figure cannot be lower than the ONAP requirement of 0.55 -->
46         <jacoco.line.coverage.limit>0.60</jacoco.line.coverage.limit>
47         <jacoco.report.directory>${project.build.directory}/code-coverage</jacoco.report.directory>
48         <!-- docker related properties -->
49         <docker.fabric.version>0.28.0</docker.fabric.version>
50         <aai.docker.version>1.0.0</aai.docker.version>
51         <aai.build.directory>${project.build.directory}/${project.artifactId}-build/
52         </aai.build.directory>
53         <aai.docker.namespace>onap</aai.docker.namespace>
54         <aai.base.image>alpine</aai.base.image>
55         <aai.base.image.version>1.6.0</aai.base.image.version>
56         <!-- This will be used for the docker images as the default format of maven build has issues -->
57         <maven.build.timestamp.format>yyyyMMdd'T'HHmmss'Z'</maven.build.timestamp.format>
58     </properties>
59
60     <dependencyManagement>
61         <dependencies>
62             <dependency>
63                 <!-- Import dependency management from Spring Boot -->
64                 <groupId>org.springframework.boot</groupId>
65                 <artifactId>spring-boot-dependencies</artifactId>
66                 <version>1.5.21.RELEASE</version>
67                 <type>pom</type>
68                 <scope>import</scope>
69             </dependency>
70         </dependencies>
71     </dependencyManagement>
72
73     <dependencies>
74         <dependency>
75             <groupId>org.springframework.boot</groupId>
76             <artifactId>spring-boot-starter-web</artifactId>
77             <exclusions>
78                 <exclusion>
79                     <groupId>org.springframework.boot</groupId>
80                     <artifactId>spring-boot-starter-tomcat</artifactId>
81                 </exclusion>
82             </exclusions>
83         </dependency>
84         <dependency>
85             <groupId>org.springframework.boot</groupId>
86             <artifactId>spring-boot-starter-jetty</artifactId>
87         </dependency>
88         <dependency>
89             <groupId>org.springframework.boot</groupId>
90             <artifactId>spring-boot-starter</artifactId>
91             <exclusions>
92                 <exclusion>
93                     <groupId>ch.qos.logback</groupId>
94                     <artifactId>logback-classic</artifactId>
95                 </exclusion>
96             </exclusions>
97         </dependency>
98         <dependency>
99             <groupId>org.springframework.boot</groupId>
100             <artifactId>spring-boot-starter-jersey</artifactId>
101             <exclusions>
102                 <exclusion>
103                     <groupId>org.springframework.boot</groupId>
104                     <artifactId>spring-boot-starter-tomcat</artifactId>
105                 </exclusion>
106             </exclusions>
107         </dependency>
108         <dependency>
109             <groupId>org.springframework.boot</groupId>
110             <artifactId>spring-boot-starter-actuator</artifactId>
111         </dependency>
112         <dependency>
113             <groupId>org.springframework.boot</groupId>
114             <artifactId>spring-boot-configuration-processor</artifactId>
115             <optional>true</optional>
116         </dependency>
117         <dependency>
118             <groupId>org.springframework.boot</groupId>
119             <artifactId>spring-boot-starter-test</artifactId>
120             <scope>test</scope>
121         </dependency>
122         <dependency>
123             <groupId>org.apache.cxf</groupId>
124             <artifactId>cxf-rt-frontend-jaxrs</artifactId>
125             <version>3.2.5</version>
126         </dependency>
127
128
129         <dependency>
130             <groupId>io.swagger</groupId>
131             <artifactId>swagger-jersey2-jaxrs</artifactId>
132             <version>1.5.8</version>
133         </dependency>
134         <dependency>
135             <groupId>io.springfox</groupId>
136             <artifactId>springfox-swagger2</artifactId>
137             <version>2.9.2</version>
138         </dependency>
139         <dependency>
140             <groupId>io.springfox</groupId>
141             <artifactId>springfox-swagger-ui</artifactId>
142             <version>2.9.2</version>
143         </dependency>
144
145
146         <!-- ONAP AAI-COMMON (incl. model) -->
147         <dependency>
148             <groupId>org.onap.aai.schema-service</groupId>
149             <artifactId>aai-schema</artifactId>
150             <version>${version.org.onap.aai.aai-schema}</version>
151         </dependency>
152         <dependency>
153             <groupId>org.onap.aai.aai-common</groupId>
154             <artifactId>aai-schema-ingest</artifactId>
155             <version>${version.org.onap.aai.aai-schema-ingest}</version>
156             <exclusions>
157                 <exclusion>
158                     <groupId>org.powermock</groupId>
159                     <artifactId>*</artifactId>
160                 </exclusion>
161             </exclusions>
162         </dependency>
163         <dependency>
164             <groupId>org.onap.aai.aai-common</groupId>
165             <artifactId>aai-utils</artifactId>
166             <version>${version.org.onap.aai.aai-utils}</version>
167         </dependency>
168         <dependency>
169             <groupId>org.onap.aai.aai-common</groupId>
170             <artifactId>aai-auth</artifactId>
171             <version>${version.org.onap.aai.aai-auth}</version>
172         </dependency>
173
174         <!-- ONAP EVENT CLIENT -->
175         <dependency>
176             <groupId>org.onap.aai.event-client</groupId>
177             <artifactId>event-client-dmaap</artifactId>
178             <version>${event.client.version}</version>
179             <exclusions>
180                 <exclusion>
181                     <groupId>org.slf4j</groupId>
182                     <artifactId>slf4j-api</artifactId>
183                 </exclusion>
184             </exclusions>
185         </dependency>
186         <dependency>
187             <groupId>org.onap.aai.event-client</groupId>
188             <artifactId>event-client-kafka</artifactId>
189             <version>${event.client.version}</version>
190             <exclusions>
191                 <exclusion>
192                     <groupId>org.slf4j</groupId>
193                     <artifactId>slf4j-api</artifactId>
194                 </exclusion>
195             </exclusions>
196         </dependency>
197
198         <dependency>
199             <groupId>org.onap.aai.event-client</groupId>
200             <artifactId>event-client-rabbitmq</artifactId>
201             <version>${event.client.version}</version>
202             <exclusions>
203                 <exclusion>
204                     <groupId>org.slf4j</groupId>
205                     <artifactId>slf4j-api</artifactId>
206                 </exclusion>
207             </exclusions>
208         </dependency>
209
210         <!-- ONAP COMMON LOGGING -->
211         <dependency>
212             <groupId>org.onap.aai.logging-service</groupId>
213             <artifactId>common-logging</artifactId>
214             <version>1.2.2</version>
215             <exclusions>
216                 <exclusion>
217                     <groupId>ch.qos.logback</groupId>
218                     <artifactId>logback-classic</artifactId>
219                 </exclusion>
220                 <exclusion>
221                     <groupId>ch.qos.logback</groupId>
222                     <artifactId>logback-core</artifactId>
223                 </exclusion>
224                 <exclusion>
225                     <groupId>org.slf4j</groupId>
226                     <artifactId>slf4j-api</artifactId>
227                 </exclusion>
228             </exclusions>
229         </dependency>
230
231         <!-- ONAP REST CLIENT -->
232         <dependency>
233             <groupId>org.onap.aai</groupId>
234             <artifactId>rest-client</artifactId>
235             <version>1.5.0</version>
236         </dependency>
237
238         <dependency>
239             <groupId>ch.qos.logback</groupId>
240             <artifactId>logback-classic</artifactId>
241             <version>1.2.3</version>
242         </dependency>
243         <dependency>
244             <groupId>ch.qos.logback</groupId>
245             <artifactId>logback-core</artifactId>
246             <version>1.2.3</version>
247             <exclusions>
248                 <exclusion>
249                     <groupId>ch.qos.logback</groupId>
250                     <artifactId>logback-classic</artifactId>
251                 </exclusion>
252             </exclusions>
253         </dependency>
254         <dependency>
255             <groupId>ch.qos.logback</groupId>
256             <artifactId>logback-access</artifactId>
257             <version>1.2.3</version>
258         </dependency>
259         <dependency>
260             <groupId>com.google.guava</groupId>
261             <artifactId>guava</artifactId>
262         </dependency>
263         <dependency>
264             <groupId>radeox</groupId>
265             <artifactId>radeox</artifactId>
266             <version>1.0-b2</version>
267         </dependency>
268         <dependency>
269             <groupId>org.codehaus.jackson</groupId>
270             <artifactId>jackson-mapper-asl</artifactId>
271             <version>1.4.5</version>
272         </dependency>
273         <dependency>
274             <groupId>commons-io</groupId>
275             <artifactId>commons-io</artifactId>
276             <version>2.4</version>
277         </dependency>
278         <dependency>
279             <groupId>org.apache.commons</groupId>
280             <artifactId>commons-lang3</artifactId>
281             <version>3.3.1</version>
282         </dependency>
283         <dependency>
284             <groupId>com.google.code.gson</groupId>
285             <artifactId>gson</artifactId>
286             <version>2.6.2</version>
287         </dependency>
288         <dependency>
289             <groupId>org.eclipse.persistence</groupId>
290             <artifactId>eclipselink</artifactId>
291             <version>2.6.2</version>
292         </dependency>
293         <dependency>
294             <groupId>net.dongliu</groupId>
295             <artifactId>gson-java8-datatype</artifactId>
296             <version>1.0.3</version>
297         </dependency>
298         <dependency>
299             <groupId>com.jayway.jsonpath</groupId>
300             <artifactId>json-path</artifactId>
301             <version>2.2.0</version>
302             <exclusions>
303                 <exclusion>
304                     <groupId>org.slf4j</groupId>
305                     <artifactId>slf4j-api</artifactId>
306                 </exclusion>
307             </exclusions>
308         </dependency>
309         <dependency>
310             <groupId>org.apache.tinkerpop</groupId>
311             <artifactId>gremlin-core</artifactId>
312             <version>3.2.3</version>
313             <scope>provided</scope>
314             <exclusions>
315                 <exclusion>
316                     <groupId>org.slf4j</groupId>
317                     <artifactId>slf4j-log4j12</artifactId>
318                 </exclusion>
319                 <exclusion>
320                     <groupId>org.slf4j</groupId>
321                     <artifactId>jcl-over-slf4j</artifactId>
322                 </exclusion>
323                 <exclusion>
324                     <groupId>org.slf4j</groupId>
325                     <artifactId>slf4j-api</artifactId>
326                 </exclusion>
327             </exclusions>
328         </dependency>
329         <dependency>
330             <groupId>org.apache.tinkerpop</groupId>
331             <artifactId>tinkergraph-gremlin</artifactId>
332             <version>3.2.3</version>
333             <scope>provided</scope>
334         </dependency>
335         <dependency>
336             <groupId>org.json</groupId>
337             <artifactId>json</artifactId>
338             <version>20160212</version>
339         </dependency>
340         <dependency>
341             <groupId>org.apache.httpcomponents</groupId>
342             <artifactId>httpclient</artifactId>
343             <version>4.5.3</version>
344         </dependency>
345         <dependency>
346             <groupId>org.apache.httpcomponents</groupId>
347             <artifactId>httpcore</artifactId>
348             <version>4.4.1</version>
349         </dependency>
350
351         <!-- TEST DEPENDENCIES -->
352         <dependency>
353             <groupId>junit</groupId>
354             <artifactId>junit</artifactId>
355         </dependency>
356         <dependency>
357             <groupId>org.skyscreamer</groupId>
358             <artifactId>jsonassert</artifactId>
359             <version>1.5.0</version>
360             <scope>test</scope>
361         </dependency>
362         <dependency>
363             <groupId>org.mockito</groupId>
364             <artifactId>mockito-core</artifactId>
365             <version>2.15.0</version>
366             <scope>test</scope>
367             <exclusions>
368                 <exclusion>
369                     <groupId>org.hamcrest</groupId>
370                     <artifactId>hamcrest-library</artifactId>
371                 </exclusion>
372             </exclusions>
373         </dependency>
374     </dependencies>
375
376     <profiles>
377         <!-- Docker profile to be used for building docker image and pushing to nexus -->
378         <profile>
379             <id>docker</id>
380             <build>
381                 <plugins>
382                   <plugin>
383                     <groupId>org.codehaus.mojo</groupId>
384                     <artifactId>build-helper-maven-plugin</artifactId>
385                     <version>3.0.0</version>
386                     <executions>
387                       <execution>
388                         <phase>pre-clean</phase>
389                         <id>parse-version</id>
390                         <goals>
391                           <goal>parse-version</goal>
392                         </goals>
393                       </execution>
394                     </executions>
395                   </plugin>
396                   <plugin>
397                     <groupId>org.codehaus.groovy.maven</groupId>
398                     <artifactId>gmaven-plugin</artifactId>
399                     <version>1.0</version>
400                     <executions>
401                       <execution>
402                         <phase>pre-clean</phase>
403                         <goals>
404                           <goal>execute</goal>
405                         </goals>
406                         <configuration>
407                           <source>
408                             def userAaiBaseImage = session.userProperties['aai.base.image']
409                             def userAaiCommonVersion = session.userProperties['aai.base.image.version']
410                             if (userAaiCommonVersion != null) {
411                                project.properties['aai.base.image.version'] = userAaiCommonVersion
412                             }
413                             if (userAaiBaseImage != null) {
414                                project.properties['aai.base.image'] = userAaiBaseImage
415                             }
416                             log.info 'Base image flavour: ' + project.properties['aai.base.image']
417                             log.info 'Base image version: ' + project.properties['aai.base.image.version']
418                   </source>
419                 </configuration>
420               </execution>
421             </executions>
422             </plugin>
423             <plugin>
424               <groupId>io.fabric8</groupId>
425               <artifactId>docker-maven-plugin</artifactId>
426               <version>${docker.fabric.version}</version>
427               <configuration>
428                 <verbose>true</verbose>
429                 <apiVersion>1.23</apiVersion>
430                 <images>
431                   <image>
432                     <name>${docker.push.registry}/${aai.docker.namespace}/${project.artifactId}:%l
433                     </name>
434                     <build>
435                       <filter>@</filter>
436                       <tags>
437                         <tag>latest</tag>
438                         <tag>${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest</tag>
439                         <tag>${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-${maven.build.timestamp}</tag>
440                       </tags>
441                       <cleanup>try</cleanup>
442                       <dockerFileDir>${project.basedir}/src/main/docker</dockerFileDir>
443                       <assembly>
444                         <inline>
445                           <fileSets>
446                             <fileSet>
447                               <directory>${aai.build.directory}</directory>
448                               <outputDirectory>/${project.artifactId}</outputDirectory>
449                             </fileSet>
450                           </fileSets>
451                         </inline>
452                       </assembly>
453                     </build>
454                   </image>
455                 </images>
456               </configuration>
457               <executions>
458                 <execution>
459                   <id>clean-images</id>
460                   <phase>pre-clean</phase>
461                   <goals>
462                     <goal>remove</goal>
463                   </goals>
464                   <configuration>
465                     <removeAll>true</removeAll>
466                   </configuration>
467                 </execution>
468                 <execution>
469                   <id>generate-images</id>
470                   <phase>package</phase>
471                   <goals>
472                     <goal>build</goal>
473                   </goals>
474                 </execution>
475                 <execution>
476                   <id>push-images</id>
477                   <phase>deploy</phase>
478                   <goals>
479                     <goal>push</goal>
480                   </goals>
481                 </execution>
482               </executions>
483             </plugin>
484           </plugins>
485         </build>
486       </profile>
487     </profiles>
488
489     <build>
490         <finalName>${project.artifactId}</finalName>
491         <!--
492             Using https://code.revelc.net/formatter-maven-plugin/ for Eclipse formatter
493             Using https://github.com/diffplug/spotless/tree/master/plugin-maven for import order
494             Use in combination to rewrite code and imports, then checkstyle
495
496             mvn formatter:format spotless:apply process-sources
497         -->
498         <plugins>
499           <plugin>
500                 <groupId>net.revelc.code.formatter</groupId>
501                 <artifactId>formatter-maven-plugin</artifactId>
502                 <version>2.8.1</version>
503                 <configuration>
504                     <configFile>${project.basedir}/onap-java-formatter.xml</configFile>
505                 </configuration>
506                 <!-- https://code.revelc.net/formatter-maven-plugin/
507                      use mvn formatter:format to rewrite source files
508                      use mvn formatter:validate to validate source files -->
509             </plugin>
510             <plugin>
511               <groupId>org.codehaus.groovy.maven</groupId>
512               <artifactId>gmaven-plugin</artifactId>
513             </plugin>
514             <plugin>
515                 <groupId>com.diffplug.spotless</groupId>
516                 <artifactId>spotless-maven-plugin</artifactId>
517                 <version>1.18.0</version>
518                 <configuration>
519                     <java>
520                         <importOrder>
521                             <order>com,java,javax,org</order>
522                         </importOrder>
523                     </java>
524                 </configuration>
525                 <!-- https://github.com/diffplug/spotless/tree/master/plugin-maven
526                      use mvn spotless:apply to rewrite source files
527                      use mvn spotless:check to validate source files -->
528             </plugin>
529             <!-- license plugin -->
530             <!-- Uncomment this to add a license header to every source file -->
531             <plugin>
532                 <groupId>com.mycila</groupId>
533                 <artifactId>license-maven-plugin</artifactId>
534                 <version>3.0</version>
535                 <configuration>
536                     <header>License.txt</header>
537                     <includes>
538                         <include>src/main/java/**</include>
539                         <include>src/test/java/**</include>
540                         <include>pom.xml</include>
541                     </includes>
542                     <skipExistingHeaders>true</skipExistingHeaders>
543                 </configuration>
544                 <executions>
545                     <execution>
546                         <goals>
547                             <!-- Set goal from "check" to "format" to auto update license headers -->
548                             <goal>check</goal>
549                         </goals>
550                         <phase>process-sources</phase>
551                     </execution>
552                 </executions>
553             </plugin>
554
555             <plugin>
556                 <groupId>org.apache.maven.plugins</groupId>
557                 <artifactId>maven-site-plugin</artifactId>
558                 <version>3.3</version>
559                 <configuration>
560                     <reportPlugins>
561                         <plugin>
562                             <groupId>org.apache.maven.plugins</groupId>
563                             <artifactId>maven-checkstyle-plugin</artifactId>
564                             <version>2.17</version>
565                             <reportSets>
566                                 <reportSet>
567                                     <reports>
568                                         <report>checkstyle</report>
569                                     </reports>
570                                 </reportSet>
571                             </reportSets>
572                         </plugin>
573                     </reportPlugins>
574                 </configuration>
575             </plugin>
576             <plugin>
577                 <groupId>org.apache.maven.plugins</groupId>
578                 <artifactId>maven-deploy-plugin</artifactId>
579             </plugin>
580             <plugin>
581                 <groupId>org.springframework.boot</groupId>
582                 <artifactId>spring-boot-maven-plugin</artifactId>
583                 <version>2.0.1.RELEASE</version>
584                 <executions>
585                     <execution>
586                         <goals>
587                             <goal>repackage</goal>
588                         </goals>
589                     </execution>
590                 </executions>
591             </plugin>
592             <plugin>
593                 <artifactId>maven-assembly-plugin</artifactId>
594                 <configuration>
595                     <descriptors>
596                         <descriptor>src/main/assembly/descriptor.xml</descriptor>
597                     </descriptors>
598                 </configuration>
599                 <executions>
600                     <execution>
601                         <id>make-assembly</id>
602                         <phase>package</phase>
603                         <goals>
604                             <goal>single</goal>
605                         </goals>
606                     </execution>
607                 </executions>
608             </plugin>
609             <plugin>
610                 <groupId>org.apache.maven.plugins</groupId>
611                 <artifactId>maven-dependency-plugin</artifactId>
612                 <executions>
613                     <execution>
614                         <id>unpack</id>
615                         <phase>prepare-package</phase>
616                         <goals>
617                             <goal>unpack</goal>
618                         </goals>
619                         <configuration>
620                             <artifactItems>
621                                 <artifactItem>
622                                     <groupId>org.onap.aai.schema-service</groupId>
623                                     <artifactId>aai-schema</artifactId>
624                                     <version>${version.org.onap.aai.aai-schema}</version>
625                                     <type>jar</type>
626                                     <includes>onap/**/</includes>
627                                     <excludes>onap/*swagger**/</excludes>
628                                     <outputDirectory>${aai.build.directory}/bundleconfig/etc</outputDirectory>
629                                 </artifactItem>
630                             </artifactItems>
631                         </configuration>
632                     </execution>
633                 </executions>
634             </plugin>
635             <plugin>
636                 <groupId>org.jacoco</groupId>
637                 <artifactId>jacoco-maven-plugin</artifactId>
638                 <executions>
639                     <execution>
640                         <id>default-check</id>
641                         <goals>
642                             <goal>check</goal>
643                         </goals>
644                         <configuration>
645                             <dataFile>${jacoco.report.directory}/jacoco-ut.exec</dataFile>
646                             <rules>
647                                 <!--  implementation is needed only for Maven 2  -->
648                                 <rule implementation="org.jacoco.maven.RuleConfiguration">
649                                     <element>BUNDLE</element>
650                                     <limits>
651                                         <limit implementation="org.jacoco.report.check.Limit">
652                                             <counter>LINE</counter>
653                                             <value>COVEREDRATIO</value>
654                                             <minimum>${jacoco.line.coverage.limit}</minimum>
655                                         </limit>
656                                     </limits>
657                                 </rule>
658                             </rules>
659                         </configuration>
660                     </execution>
661                 </executions>
662             </plugin>
663
664         </plugins>
665     </build>
666
667     <distributionManagement>
668         <site>
669             <id>ecomp-javadoc</id>
670             <url>dav:https://ecomp-nexus:8443/repository/aai/gizmo-javadoc/${project.version}</url>
671         </site>
672     </distributionManagement>
673 </project>