Add complex API definition.
[aai/esr-server.git] / esr-mgr / pom.xml
1 <?xml version="1.0"?>
2 <!--
3
4     Copyright 2016-2018 ZTE Corporation.
5
6     Licensed under the Apache License, Version 2.0 (the "License");
7     you may not use this file except in compliance with the License.
8     You may obtain a copy of the License at
9
10         http://www.apache.org/licenses/LICENSE-2.0
11
12     Unless required by applicable law or agreed to in writing, software
13     distributed under the License is distributed on an "AS IS" BASIS,
14     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15     See the License for the specific language governing permissions and
16     limitations under the License.
17
18 -->
19 <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">
20
21         <parent>
22                 <groupId>org.onap.aai.esr-server</groupId>
23                 <artifactId>aai-esr-server</artifactId>
24                 <version>1.1.0-SNAPSHOT</version>
25         </parent>
26         
27         <modelVersion>4.0.0</modelVersion>
28         <artifactId>esr-mgr</artifactId>
29         <name>esr-server/esr-mgr</name>
30         <version>1.1.0-SNAPSHOT</version>
31         <packaging>jar</packaging>
32
33     <build>
34         <plugins>
35             <plugin>
36                 <groupId>org.eclipse.m2e</groupId>
37                 <artifactId>lifecycle-mapping</artifactId>
38                 <configuration>
39                     <lifecycleMappingMetadata>
40                         <pluginExecutions>
41                             <pluginExecution>
42                                 <pluginExecutionFilter>
43                                     <groupId>org.apache.maven.plugins</groupId>
44                                     <artifactId>maven-dependency-plugin</artifactId>
45                                     <versionRange>[2.0,)</versionRange>
46                                     <goals>
47                                         <goal>copy-dependencies</goal>
48                                     </goals>
49                                 </pluginExecutionFilter>
50                                 <action>
51                                     <ignore/>
52                                 </action>
53                             </pluginExecution>
54                         </pluginExecutions>
55                     </lifecycleMappingMetadata>
56                 </configuration>
57             </plugin>
58             <plugin>
59                 <groupId>org.apache.maven.plugins</groupId>
60                 <artifactId>maven-jar-plugin</artifactId>
61                 <configuration>
62                     <archive>
63                         <manifest>
64                             <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
65                         </manifest>
66                     </archive>
67                 </configuration>
68             </plugin>
69             <plugin>
70                 <groupId>org.apache.maven.plugins</groupId>
71                 <artifactId>maven-shade-plugin</artifactId>
72                 <configuration>
73                     <createDependencyReducedPom>true</createDependencyReducedPom>
74                     <filters>
75                         <filter>
76                             <artifact>*:*</artifact>
77                             <excludes>
78                                 <exclude>META-INF/*.SF</exclude>
79                                 <exclude>META-INF/*.DSA</exclude>
80                                 <exclude>META-INF/*.RSA</exclude>
81                             </excludes>
82                         </filter>
83                     </filters>
84                 </configuration>
85                 <executions>
86                     <execution>
87                         <phase>package</phase>
88                         <goals>
89                             <goal>shade</goal>
90                         </goals>
91                         <configuration>
92                             <transformers>
93                                 <transformer implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer"/>
94                                 <transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
95                                     <mainClass>org.onap.aai.esr.extsysApp</mainClass>
96                                 </transformer>
97                             </transformers>
98                         </configuration>
99                     </execution>
100                 </executions>
101             </plugin>
102             <plugin>
103                 <groupId>org.apache.maven.plugins</groupId>
104                 <artifactId>maven-dependency-plugin</artifactId>
105                 <executions>
106                     <execution>
107                         <id>copy-dependencies</id>
108                         <phase>package</phase>
109                         <goals>
110                             <goal>copy-dependencies</goal>
111                         </goals>
112                         <configuration>
113                             <artifactItems>
114                                 <artifactItem>
115                                     <groupId>io.dropwizard</groupId>
116                                     <artifactId>dropwizard-core</artifactId>
117                                     <version>${dropwizard.version}</version>
118                                     <overWrite>true</overWrite>
119                                 </artifactItem>
120                             </artifactItems>
121                         </configuration>
122                     </execution>
123                 </executions>
124             </plugin>
125         </plugins>
126     </build>
127
128     <dependencies>
129         <dependency>
130             <groupId>io.dropwizard</groupId>
131             <artifactId>dropwizard-core</artifactId>
132                         <exclusions>
133                 <exclusion>
134                     <groupId>com.fasterxml.jackson.core</groupId>
135                                         <artifactId>jackson-databind</artifactId>
136                 </exclusion>
137             </exclusions>
138         </dependency>
139         <dependency>
140             <groupId>io.dropwizard</groupId>
141             <artifactId>dropwizard-assets</artifactId>
142         </dependency>
143         <dependency>
144             <groupId>io.dropwizard</groupId>
145             <artifactId>dropwizard-hibernate</artifactId>
146         </dependency>
147         <dependency>
148             <groupId>io.swagger</groupId>
149             <artifactId>swagger-jersey2-jaxrs</artifactId>
150                         <exclusions>
151                 <exclusion>
152                     <groupId>com.fasterxml.jackson.dataformat</groupId>
153                                         <artifactId>jackson-dataformat-xml</artifactId>
154                 </exclusion>
155             </exclusions>
156         </dependency>
157         <!-- jersey -->
158         <dependency>
159             <groupId>org.glassfish.jersey.core</groupId>
160             <artifactId>jersey-server</artifactId>
161         </dependency>
162         <dependency>
163             <groupId>org.glassfish.jersey.media</groupId>
164             <artifactId>jersey-media-multipart</artifactId>
165         </dependency>
166         <dependency>
167             <groupId>org.glassfish.jersey.containers</groupId>
168             <artifactId>jersey-container-servlet-core</artifactId>
169         </dependency>
170         <!-- consumer -->
171         <dependency>
172             <groupId>com.eclipsesource.jaxrs</groupId>
173             <artifactId>consumer</artifactId>
174             <exclusions>
175                 <exclusion>
176                     <groupId>com.eclipsesource.jaxrs</groupId>
177                     <artifactId>jersey-all</artifactId>
178                 </exclusion>
179             </exclusions>
180         </dependency>
181         <!-- gson -->
182         <dependency>
183             <groupId>com.google.code.gson</groupId>
184             <artifactId>gson</artifactId>
185         </dependency>
186         <!-- UT -->
187         <dependency>
188             <groupId>junit</groupId>
189             <artifactId>junit</artifactId>
190             <scope>test</scope>
191         </dependency>
192         <dependency>
193             <groupId>org.apache.ant</groupId>
194             <artifactId>ant</artifactId>
195             <scope>test</scope>
196         </dependency>
197         <dependency>
198             <groupId>org.powermock</groupId>
199             <artifactId>powermock-api-easymock</artifactId>
200             <version>1.6.5</version>
201             <scope>test</scope>
202         </dependency>
203         <!-- <dependency>
204             <groupId>org.powermock</groupId>
205             <artifactId>powermock-api-mockito</artifactId>
206             <version>1.7.1</version>
207             <scope>test</scope>
208         </dependency>
209         <dependency>
210             <groupId>org.powermock</groupId>
211             <artifactId>powermock-module-junit4-rule</artifactId>
212             <version>1.6.5</version>
213             <scope>test</scope>
214         </dependency> -->
215         <dependency>
216                 <groupId>org.powermock</groupId>
217                 <artifactId>powermock-module-junit4</artifactId>
218                 <version>1.5.5</version>
219                 <scope>test</scope>
220         </dependency>
221         <dependency>
222             <groupId>org.powermock</groupId>
223             <artifactId>powermock-api-mockito</artifactId>
224             <version>1.5.5</version>
225             <scope>test</scope>
226         </dependency>
227         <dependency>
228             <groupId>org.hamcrest</groupId>
229             <artifactId>hamcrest-library</artifactId>
230             <version>1.3</version>
231             <scope>test</scope>
232         </dependency>
233         <dependency>
234             <groupId>org.easymock</groupId>
235             <artifactId>easymock</artifactId>
236             <version>3.0</version>
237             <scope>test</scope>
238         </dependency>
239         <!-- MSB java-sdk -->
240         <dependency>
241             <groupId>org.onap.msb.java-sdk</groupId>
242             <artifactId>msb-java-sdk</artifactId>
243             <version>1.1.0-SNAPSHOT</version>
244         </dependency>    
245     </dependencies>
246         
247         <profiles>
248         <profile>
249             <id>swagger</id>
250             <dependencies>
251                 <dependency>
252                     <groupId>io.swagger</groupId>
253                     <artifactId>swagger-jersey2-jaxrs</artifactId>
254                     <version>1.5.0</version>
255                 </dependency>
256             </dependencies>
257             <build>
258                 <plugins>
259                     <plugin>
260                         <groupId>com.github.kongchen</groupId>
261                         <artifactId>swagger-maven-plugin</artifactId>
262                         <version>3.1.1</version>
263                         <configuration>
264                             <apiSources>
265                                 <apiSource>
266                                     <springmvc>false</springmvc>
267                                     <locations>org.onap.aai.esr.resource</locations>
268                                     <basePath>/api/aai-esr-server/v1/</basePath>
269                                     <info>
270                                         <title>API Descriptions for External System Management</title>
271                                         <version>v1</version>
272                                         <description>
273                                             This page shows all the APIs available in the ESR server module.
274                                         </description>
275                                         <termsOfService>
276                                             http://www.github.com/kongchen/swagger-maven-plugin
277                                         </termsOfService>
278                                         <contact>
279                                             <email>li.zi30@zte.com.cn</email>
280                                             <name>Zi Li</name>
281                                         </contact>
282                                         <license>
283                                             <url>http://www.apache.org/licenses/LICENSE-2.0.html</url>
284                                             <name>Apache 2.0</name>
285                                         </license>
286                                     </info>
287                                     <securityDefinitions>
288                                     </securityDefinitions>
289                                     <swaggerDirectory>${basedir}/src/main/resources</swaggerDirectory>
290                                 </apiSource>
291                             </apiSources>
292                         </configuration>
293                         <executions>
294                             <execution>
295                                 <phase>compile</phase>
296                                 <goals>
297                                     <goal>generate</goal>
298                                 </goals>
299                             </execution>
300                         </executions>
301                         <dependencies>
302                             <dependency>
303                                 <groupId>io.swagger</groupId>
304                                 <artifactId>swagger-hibernate-validations</artifactId>
305                                 <version>1.5.6</version>
306                             </dependency>
307                         </dependencies>
308                     </plugin>
309                 </plugins>
310             </build>
311         </profile>
312     </profiles>
313 </project>