Solve nexus-iq security issue: remove spring-core dependency
[msb/apigateway.git] / apiroute / apiroute-service / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!-- Copyright (C) 2016 ZTE, Inc. and others. All rights reserved. (ZTE) 
3         Licensed under the Apache License, Version 2.0 (the "License"); you may not 
4         use this file except in compliance with the License. You may obtain a copy 
5         of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required 
6         by applicable law or agreed to in writing, software distributed under the 
7         License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS 
8         OF ANY KIND, either express or implied. See the License for the specific 
9         language governing permissions and limitations under the License. -->
10 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
11         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
12         <parent>
13                 <groupId>org.onap.msb.apigateway.apiroute</groupId>
14                 <artifactId>apiroute-parent</artifactId>
15                 <version>1.2.4-SNAPSHOT</version>
16         </parent>
17         <modelVersion>4.0.0</modelVersion>
18         <groupId>org.onap.msb.apigateway.apiroute</groupId>
19         <artifactId>apiroute-service</artifactId>
20         <name>onap/msb/apigateway/apiroute/apiroute-service</name>
21         <packaging>jar</packaging>
22         <version>1.2.4-SNAPSHOT</version>
23
24
25         <dependencies>
26                 <dependency>
27                         <groupId>io.dropwizard</groupId>
28                         <artifactId>dropwizard-core</artifactId>
29                 </dependency>
30                 <dependency>
31                         <groupId>io.dropwizard</groupId>
32                         <artifactId>dropwizard-assets</artifactId>
33                 </dependency>
34                 <dependency>
35                         <groupId>io.dropwizard</groupId>
36                         <artifactId>dropwizard-client</artifactId>
37                 </dependency>
38                 <!-- add by wangyg:增加redis的java客户端jedis依赖 -->
39                 <dependency>
40                         <groupId>redis.clients</groupId>
41                         <artifactId>jedis</artifactId>
42                 </dependency>
43                 <dependency>
44                         <groupId>org.projectlombok</groupId>
45                         <artifactId>lombok</artifactId>
46                 </dependency>
47
48                 <dependency>
49                         <groupId>junit</groupId>
50                         <artifactId>junit</artifactId>
51                         <scope>test</scope>
52                 </dependency>
53                 <dependency>
54                         <groupId>org.powermock</groupId>
55                         <artifactId>powermock-module-junit4</artifactId>
56                         <scope>test</scope>
57                 </dependency>
58
59                 <dependency>
60                         <groupId>org.powermock</groupId>
61                         <artifactId>powermock-api-mockito</artifactId>
62                         <scope>test</scope>
63                 </dependency>
64                 <dependency>
65                         <groupId>com.orbitz.consul</groupId>
66                         <artifactId>consul-client</artifactId>
67                 </dependency>
68
69                 <dependency>
70                         <groupId>com.fasterxml.jackson.core</groupId>
71                         <artifactId>jackson-databind</artifactId>
72                 </dependency>
73
74                 <dependency>
75                         <groupId>com.fasterxml.jackson.core</groupId>
76                         <artifactId>jackson-core</artifactId>
77                 </dependency>
78
79                 <dependency>
80                         <groupId>com.fasterxml.jackson.core</groupId>
81                         <artifactId>jackson-annotations</artifactId>
82                 </dependency>
83
84                 <dependency>
85                         <groupId>org.apache.httpcomponents</groupId>
86                         <artifactId>httpasyncclient</artifactId>
87                 </dependency>
88
89                 <dependency>
90                         <groupId>org.immutables</groupId>
91                         <artifactId>value</artifactId>
92                         <scope>compile</scope>
93                 </dependency>
94
95                 <dependency>
96                         <groupId>com.fiftyonred</groupId>
97                         <artifactId>mock-jedis</artifactId>
98                 </dependency>
99
100                 <dependency>
101                         <groupId>commons-io</groupId>
102                         <artifactId>commons-io</artifactId>
103                 </dependency>
104
105                 <dependency>
106                         <groupId>org.onap.msb.swagger-sdk</groupId>
107                         <artifactId>swagger-sdk</artifactId>
108                         <version>1.1.0</version>
109                         <exclusions>
110                                 <exclusion>
111                                         <groupId>org.slf4j</groupId>
112                                         <artifactId>slf4j-log4j12</artifactId>
113                                 </exclusion>
114                                 <exclusion>
115                                         <groupId>commons-beanutils</groupId>
116                                         <artifactId>commons-beanutils</artifactId>
117                                 </exclusion>
118                                 <exclusion>
119                                         <groupId>commons-collections</groupId>
120                                         <artifactId>commons-collections</artifactId>
121                                 </exclusion>
122                                 <exclusion>
123                                         <groupId>org.springframework</groupId>
124                                         <artifactId>spring-core</artifactId>
125                                 </exclusion>
126                         </exclusions>
127                 </dependency>
128
129         </dependencies>
130         <build>
131                 <plugins>
132                         <plugin>
133                                 <groupId>org.apache.maven.plugins</groupId>
134                                 <artifactId>maven-jar-plugin</artifactId>
135                                 <version>2.4</version>
136                                 <configuration>
137                                         <archive>
138                                                 <manifest>
139                                                         <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
140                                                 </manifest>
141                                         </archive>
142                                 </configuration>
143                         </plugin>
144                         <plugin>
145                                 <groupId>org.apache.maven.plugins</groupId>
146                                 <artifactId>maven-shade-plugin</artifactId>
147                                 <version>2.3</version>
148                                 <configuration>
149                                         <createDependencyReducedPom>true</createDependencyReducedPom>
150                                         <filters>
151                                                 <filter>
152                                                         <artifact>*:*</artifact>
153                                                         <excludes>
154                                                                 <exclude>META-INF/*.SF</exclude>
155                                                                 <exclude>META-INF/*.DSA</exclude>
156                                                                 <exclude>META-INF/*.RSA</exclude>
157                                                         </excludes>
158                                                 </filter>
159                                         </filters>
160                                 </configuration>
161                                 <executions>
162                                         <execution>
163                                                 <phase>package</phase>
164                                                 <goals>
165                                                         <goal>shade</goal>
166                                                 </goals>
167                                                 <configuration>
168                                                         <transformers>
169                                                                 <transformer
170                                                                         implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer" />
171                                                                 <transformer
172                                                                         implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
173                                                                         <mainClass>org.onap.msb.apiroute.ApiRouteApp</mainClass>
174                                                                 </transformer>
175                                                         </transformers>
176                                                 </configuration>
177                                         </execution>
178                                 </executions>
179                         </plugin>
180
181                         <!-- JSON -->
182                         <plugin>
183                                 <groupId>org.codehaus.mojo</groupId>
184                                 <artifactId>properties-maven-plugin</artifactId>
185                                 <version>1.0.0</version>
186                                 <executions>
187                                         <execution>
188                                                 <phase>initialize</phase>
189                                                 <goals>
190                                                         <goal>read-project-properties</goal>
191                                                 </goals>
192                                                 <configuration>
193                                                         <files>
194                                                                 <file>${basedir}/src/main/resources/swagger.properties</file>
195                                                         </files>
196                                                 </configuration>
197                                         </execution>
198                                 </executions>
199                         </plugin>
200                         <plugin>
201                                 <groupId>com.github.kongchen</groupId>
202                                 <artifactId>swagger-maven-plugin</artifactId>
203                                 <version>3.1.4</version>
204                                 <configuration>
205                                         <apiSources>
206                                                 <apiSource>
207                                                         <locations>${api-rest-package}</locations>
208                                                         <schemes>
209                                                                 <scheme>http</scheme>
210                                                                 <scheme>https</scheme>
211                                                         </schemes>
212                                                         <host>${api-host-ip}:${api-host-port}</host>
213                                                         <basePath>${api-base-path}</basePath>
214                                                         <info>
215                                                                 <title>${api-title}</title>
216                                                                 <version>${api-version}</version>
217                                                                 <description>${api-description}</description>
218                                                                 <license>
219                                                                         <name>${api-license}</name>
220                                                                 </license>
221                                                         </info>
222                                                         <swaggerDirectory>${basedir}/src/main/resources</swaggerDirectory>
223                                                 </apiSource>
224                                         </apiSources>
225                                 </configuration>
226                                 <executions>
227                                         <execution>
228                                                 <phase>compile</phase>
229                                                 <goals>
230                                                         <goal>generate</goal>
231                                                 </goals>
232                                         </execution>
233                                 </executions>
234                         </plugin>
235                         <plugin>
236                                 <groupId>org.apache.maven.plugins</groupId>
237                                 <artifactId>maven-install-plugin</artifactId>
238                                 <version>2.3.1</version>
239                                 <executions>
240                                         <execution>
241                                                 <id>install-file-id</id>
242                                                 <phase>install</phase>
243                                                 <goals>
244                                                         <goal>install-file</goal>
245                                                 </goals>
246                                                 <configuration>
247                                                         <file>${basedir}/src/main/resources/swagger.json</file>
248                                                         <groupId>${project.groupId}</groupId>
249                                                         <artifactId>${project.artifactId}-swagger-schema</artifactId>
250                                                         <version>${project.version}</version>
251                                                         <packaging>json</packaging>
252                                                 </configuration>
253                                         </execution>
254                                 </executions>
255                         </plugin>
256
257                         <!-- SDK -->
258                         <plugin>
259                                 <groupId>org.apache.maven.plugins</groupId>
260                                 <artifactId>maven-antrun-plugin</artifactId>
261                                 <version>1.8</version>
262                                 <executions>
263                                         <execution>
264                                                 <phase>initialize</phase>
265                                                 <id>ant-create-script</id>
266                                                 <configuration>
267                                                         <exportAntProperties>true</exportAntProperties>
268                                                         <tasks>
269                                                                 <taskdef resource="net/sf/antcontrib/antlib.xml"
270                                                                         classpathref="maven.plugin.classpath" />
271                                                                 <condition property="is_windows" value="true">
272                                                                         <os family="windows" />
273                                                                 </condition>
274                                                                 <condition property="isLinux" value="true">
275                                                                         <os family="unix" />
276                                                                 </condition>
277                                                                 <if>
278                                                                         <equals arg1="${is_windows}" arg2="true" />
279                                                                         <then>
280                                                                                 <property name="swagger.sdk.script.file" value="generated-source-script.bat" />
281                                                                                 <echo
282                                                                                         file="${project.build.directory}${file.separator}generated-source-script.bat"
283                                                                                         append="true"
284                                                                                         message="cd ${project.build.directory}${file.separator}generated-sources${line.separator}" />
285                                                                                 <echo
286                                                                                         file="${project.build.directory}${file.separator}generated-source-script.bat"
287                                                                                         append="true"
288                                                                                         message="mvn clean install -Dmaven.test.skip=true${line.separator}" />
289                                                                         </then>
290                                                                         <else>
291                                                                                 <property name="swagger.sdk.script.file" value="generated-source-script.sh" />
292                                                                                 <echo
293                                                                                         file="${project.build.directory}${file.separator}generated-source-script.sh"
294                                                                                         append="true"
295                                                                                         message="cd ${project.build.directory}${file.separator}generated-sources${line.separator}" />
296                                                                                 <echo
297                                                                                         file="${project.build.directory}${file.separator}generated-source-script.sh"
298                                                                                         append="true"
299                                                                                         message="mvn clean install -Dmaven.test.skip=true${line.separator}" />
300                                                                                 <chmod
301                                                                                         file="${project.build.directory}${file.separator}generated-source-script.sh"
302                                                                                         perm="755" />
303                                                                         </else>
304                                                                 </if>
305                                                         </tasks>
306                                                 </configuration>
307                                                 <goals>
308                                                         <goal>run</goal>
309                                                 </goals>
310                                         </execution>
311                                 </executions>
312                                 <dependencies>
313                                         <dependency>
314                                                 <groupId>ant-contrib</groupId>
315                                                 <artifactId>ant-contrib</artifactId>
316                                                 <version>1.0b3</version>
317                                                 <exclusions>
318                                                         <exclusion>
319                                                                 <artifactId>ant</artifactId>
320                                                                 <groupId>ant</groupId>
321                                                         </exclusion>
322                                                 </exclusions>
323                                         </dependency>
324                                 </dependencies>
325                         </plugin>
326                         <plugin>
327                                 <groupId>io.swagger</groupId>
328                                 <artifactId>swagger-codegen-maven-plugin</artifactId>
329                                 <version>2.2.1</version>
330                                 <executions>
331                                         <execution>
332                                                 <goals>
333                                                         <goal>generate</goal>
334                                                 </goals>
335                                                 <configuration>
336                                                         <inputSpec>${basedir}/src/main/resources/swagger.json</inputSpec>
337                                                         <output>${project.build.directory}/generated-sources</output>
338                                                         <language>java</language>
339                                                         <configOptions>
340                                                                 <dateLibrary>joda</dateLibrary>
341                                                         </configOptions>
342                                                         <library>jersey2</library>
343                                                         <groupId>${project.groupId}</groupId>
344                                                         <artifactId>${project.artifactId}</artifactId>
345                                                         <artifactVersion>${project.version}</artifactVersion>
346                                                         <modelPackage>${project.groupId}.${project.artifactId}.client.model</modelPackage>
347                                                         <apiPackage>${project.groupId}.${project.artifactId}.client.api</apiPackage>
348                                                         <invokerPackage>${project.groupId}.${project.artifactId}.client.invoker</invokerPackage>
349                                                 </configuration>
350                                         </execution>
351                                 </executions>
352                         </plugin>
353                         <plugin>
354                                 <artifactId>exec-maven-plugin</artifactId>
355                                 <groupId>org.codehaus.mojo</groupId>
356                                 <version>1.5.0</version>
357                                 <executions>
358                                         <execution>
359                                                 <id>swagger-generate-sources</id>
360                                                 <phase>generate-sources</phase>
361                                                 <goals>
362                                                         <goal>exec</goal>
363                                                 </goals>
364                                                 <configuration>
365                                                         <executable>${project.build.directory}${file.separator}${swagger.sdk.script.file}</executable>
366                                                 </configuration>
367                                         </execution>
368                                 </executions>
369                         </plugin>
370                         <plugin>
371                                 <groupId>org.apache.maven.plugins</groupId>
372                                 <artifactId>maven-clean-plugin</artifactId>
373                                 <version>3.0.0</version>
374                                 <executions>
375                                         <execution>
376                                                 <id>clean-generated-files</id>
377                                                 <phase>generate-sources</phase>
378                                                 <goals>
379                                                         <goal>clean</goal>
380                                                 </goals>
381                                                 <configuration>
382                                                         <filesets>
383                                                                 <fileset>
384                                                                         <directory>${project.build.directory}/generated-sources</directory>
385                                                                 </fileset>
386                                                         </filesets>
387                                                 </configuration>
388                                         </execution>
389                                 </executions>
390                         </plugin>
391                 </plugins>
392                 <resources>
393                         <resource>
394                                 <directory>src/main/java</directory>
395                                 <includes>
396                                         <include>**/*.properties</include>
397                                 </includes>
398                         </resource>
399                         <resource>
400                                 <directory>src/main/resources</directory>
401                         </resource>
402                 </resources>
403         </build>
404 </project>