Merge "Add Swagger Related Configurations"
[holmes/rule-management.git] / rulemgt / pom.xml
1 <?xml version="1.0" encoding="UTF-8" ?>
2 <!--
3   ~ Copyright 2017 ZTE Corporation.
4   ~
5   ~ Licensed under the Apache License, Version 2.0 (the "License");
6   ~ you may not use this file except in compliance with the License.
7   ~ You may obtain a copy of the License at
8   ~
9   ~     http://www.apache.org/licenses/LICENSE-2.0
10   ~
11   ~ Unless required by applicable law or agreed to in writing, software
12   ~ distributed under the License is distributed on an "AS IS" BASIS,
13   ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14   ~ See the License for the specific language governing permissions and
15   ~ limitations under the License.
16   -->
17 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
18     xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
19
20     <modelVersion>4.0.0</modelVersion>
21     <parent>
22         <groupId>org.onap.holmes.rule-management</groupId>
23         <artifactId>holmes-rulemgt-parent</artifactId>
24         <version>1.0.0-SNAPSHOT</version>
25     </parent>
26
27     <artifactId>holmes-rulemgt</artifactId>
28     <name>holmes-rulemgt-service</name>
29     <packaging>jar</packaging>
30
31     <dependencies>
32         <dependency>
33             <groupId>org.onap.msb.java-sdk</groupId>
34             <artifactId>msb-java-sdk</artifactId>
35         </dependency>
36         <dependency>
37             <groupId>org.reflections</groupId>
38             <artifactId>reflections</artifactId>
39         </dependency>
40         <dependency>
41             <groupId>org.onap.holmes.common</groupId>
42             <artifactId>holmes-actions</artifactId>
43             <version>1.0.0-SNAPSHOT</version>
44             <exclusions>
45                 <exclusion>
46                     <groupId>org.glassfish.jersey.containers</groupId>
47                     <artifactId>jersey-container-servlet-core</artifactId>
48                 </exclusion>
49                 <exclusion>
50                     <groupId>org.apache.activemq</groupId>
51                     <artifactId>activemq-core</artifactId>
52                 </exclusion>
53             </exclusions>
54         </dependency>
55         <dependency>
56             <groupId>org.easymock</groupId>
57             <artifactId>easymock</artifactId>
58         </dependency>
59         <dependency>
60             <groupId>io.dropwizard</groupId>
61             <artifactId>dropwizard-db</artifactId>
62         </dependency>
63         <dependency>
64             <groupId>org.antlr</groupId>
65             <artifactId>stringtemplate</artifactId>
66         </dependency>
67         <dependency>
68             <groupId>io.dropwizard</groupId>
69             <artifactId>dropwizard-core</artifactId>
70             <exclusions>
71                 <exclusion>
72                     <groupId>ch.qos.logback</groupId>
73                     <artifactId>logback</artifactId>
74                 </exclusion>
75                 <exclusion>
76                     <artifactId>log4j-over-slf4j</artifactId>
77                     <groupId>org.slf4j</groupId>
78                 </exclusion>
79             </exclusions>
80         </dependency>
81         <dependency>
82             <groupId>org.projectlombok</groupId>
83             <artifactId>lombok</artifactId>
84         </dependency>
85         <dependency>
86             <groupId>org.postgresql</groupId>
87             <artifactId>postgresql</artifactId>
88         </dependency>
89         <dependency>
90             <groupId>org.quartz-scheduler</groupId>
91             <artifactId>quartz</artifactId>
92         </dependency>
93         <dependency>
94             <groupId>junit</groupId>
95             <artifactId>junit</artifactId>
96         </dependency>
97         <dependency>
98             <groupId>org.hamcrest</groupId>
99             <artifactId>hamcrest-core</artifactId>
100         </dependency>
101         <dependency>
102             <groupId>org.powermock</groupId>
103             <artifactId>powermock-module-junit4</artifactId>
104         </dependency>
105         <dependency>
106             <groupId>org.slf4j</groupId>
107             <artifactId>slf4j-api</artifactId>
108         </dependency>
109         <dependency>
110             <groupId>io.swagger</groupId>
111             <artifactId>swagger-jersey2-jaxrs</artifactId>
112             <scope>provided</scope>
113         </dependency>
114
115         <dependency>
116             <groupId>org.powermock</groupId>
117             <artifactId>powermock-api-easymock</artifactId>
118             <version>1.6.5</version>
119             <scope>test</scope>
120         </dependency>
121         <dependency>
122             <groupId>org.powermock</groupId>
123             <artifactId>powermock-module-junit4-rule</artifactId>
124             <version>1.6.5</version>
125             <scope>test</scope>
126         </dependency>
127         <dependency>
128             <groupId>org.powermock</groupId>
129             <artifactId>powermock-classloading-xstream</artifactId>
130             <version>1.6.5</version>
131             <scope>test</scope>
132         </dependency>
133         <dependency>
134             <groupId>org.hamcrest</groupId>
135             <artifactId>hamcrest-library</artifactId>
136             <version>1.3</version>
137             <scope>test</scope>
138         </dependency>
139         <dependency>
140             <groupId>org.easymock</groupId>
141             <artifactId>easymock</artifactId>
142             <version>3.0</version>
143             <scope>test</scope>
144         </dependency>
145         <dependency>
146             <groupId>org.javassist</groupId>
147             <artifactId>javassist</artifactId>
148             <version>3.15.0-GA</version>
149         </dependency>
150         <dependency>
151             <groupId>org.apache.httpcomponents</groupId>
152             <artifactId>httpclient</artifactId>
153             <version>4.3.6</version>
154         </dependency>
155         <dependency>
156             <groupId>com.googlecode.json-simple</groupId>
157             <artifactId>json-simple</artifactId>
158             <version>1.1.1</version>
159         </dependency>
160         <dependency>
161             <groupId>net.sf.json-lib</groupId>
162             <artifactId>json-lib</artifactId>
163             <version>2.4</version>
164             <classifier>jdk15</classifier>
165         </dependency>
166         <dependency>
167             <groupId>org.glassfish.jersey.core</groupId>
168             <artifactId>jersey-server</artifactId>
169             <version>${jersey.version}</version>
170         </dependency>
171         <dependency>
172             <groupId>org.glassfish.jersey.core</groupId>
173             <artifactId>jersey-client</artifactId>
174             <version>${jersey.version}</version>
175         </dependency>
176         <dependency>
177             <groupId>org.glassfish.jersey.core</groupId>
178             <artifactId>jersey-common</artifactId>
179             <version>${jersey.version}</version>
180         </dependency>
181         <dependency>
182             <groupId>org.glassfish.jersey.containers</groupId>
183             <artifactId>jersey-container-servlet-core</artifactId>
184             <version>${jersey.version}</version>
185         </dependency>
186         <dependency>
187             <groupId>com.google.guava</groupId>
188             <artifactId>guava</artifactId>
189             <version>19.0</version>
190         </dependency>
191     </dependencies>
192     <build>
193         <plugins>
194             <plugin>
195                 <groupId>org.apache.maven.plugins</groupId>
196                 <artifactId>maven-jar-plugin</artifactId>
197                 <configuration>
198                     <archive>
199                         <manifest>
200                             <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
201                         </manifest>
202                     </archive>
203                 </configuration>
204             </plugin>
205             <plugin>
206                 <groupId>org.apache.maven.plugins</groupId>
207                 <artifactId>maven-compiler-plugin</artifactId>
208                 <version>3.3</version>
209                 <configuration>
210                     <source>1.8</source>
211                     <target>1.8</target>
212                 </configuration>
213             </plugin>
214             <plugin>
215                 <groupId>org.apache.maven.plugins</groupId>
216                 <artifactId>maven-shade-plugin</artifactId>
217                 <configuration>
218                     <createDependencyReducedPom>true</createDependencyReducedPom>
219                     <filters>
220                         <filter>
221                             <artifact>*:*</artifact>
222                             <excludes>
223                                 <exclude>META-INF/*.SF</exclude>
224                                 <exclude>META-INF/*.DSA</exclude>
225                                 <exclude>META-INF/*.RSA</exclude>
226                             </excludes>
227                         </filter>
228                     </filters>
229                 </configuration>
230                 <executions>
231                     <execution>
232                         <phase>package</phase>
233                         <goals>
234                             <goal>shade</goal>
235                         </goals>
236                         <configuration>
237                             <transformers>
238                                 <transformer
239                                     implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer"/>
240                                 <transformer
241                                     implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
242                                     <mainClass>org.onap.holmes.rulemgt.RuleActiveApp</mainClass>
243                                 </transformer>
244                             </transformers>
245                         </configuration>
246                     </execution>
247                 </executions>
248             </plugin>
249         </plugins>
250         <resources>
251             <resource>
252                 <directory>src/main/java</directory>
253                 <includes>
254                     <include>**/*.properties</include>
255                 </includes>
256             </resource>
257             <resource>
258                 <directory>src/main/resources</directory>
259             </resource>
260         </resources>
261     </build>
262
263     <profiles>
264         <profile>
265             <id>swagger</id>
266             <dependencies>
267                 <dependency>
268                     <groupId>io.swagger</groupId>
269                     <artifactId>swagger-jersey2-jaxrs</artifactId>
270                     <version>1.5.0</version>
271                 </dependency>
272             </dependencies>
273             <build>
274                 <plugins>
275                     <plugin>
276                         <groupId>com.github.kongchen</groupId>
277                         <artifactId>swagger-maven-plugin</artifactId>
278                         <version>3.1.1</version>
279                         <configuration>
280                             <apiSources>
281                                 <apiSource>
282                                     <springmvc>false</springmvc>
283                                     <locations>org.onap.holmes.rulemgt.resources</locations>
284                                     <basePath>/api/holmes-rule-mgmt/v1/</basePath>
285                                     <info>
286                                         <title>API Descriptions for Holmes Rule Management</title>
287                                         <version>v1</version>
288                                         <description>
289                                             This page shows all the APIs available in the Holmes rule management module.
290                                         </description>
291                                         <termsOfService>
292                                             http://www.github.com/kongchen/swagger-maven-plugin
293                                         </termsOfService>
294                                         <contact>
295                                             <email>fu.guangrong@zte.com.cn</email>
296                                             <name>Guangrong Fu</name>
297                                         </contact>
298                                         <license>
299                                             <url>http://www.apache.org/licenses/LICENSE-2.0.html</url>
300                                             <name>Apache 2.0</name>
301                                         </license>
302                                     </info>
303                                     <securityDefinitions>
304                                     </securityDefinitions>
305                                     <swaggerDirectory>${basedir}/src/main/resources</swaggerDirectory>
306                                 </apiSource>
307                             </apiSources>
308                         </configuration>
309                         <executions>
310                             <execution>
311                                 <phase>compile</phase>
312                                 <goals>
313                                     <goal>generate</goal>
314                                 </goals>
315                             </execution>
316                         </executions>
317                         <dependencies>
318                             <dependency>
319                                 <groupId>io.swagger</groupId>
320                                 <artifactId>swagger-hibernate-validations</artifactId>
321                                 <version>1.5.6</version>
322                             </dependency>
323                         </dependencies>
324                     </plugin>
325                 </plugins>
326             </build>
327         </profile>
328     </profiles>
329 </project>