blob: 25081560965752d6ccdf5112497c5b1c652a09ce [file] [log] [blame]
Yuta HIGUCHI5a016cf2016-12-20 15:19:22 -08001<?xml version="1.0" encoding="UTF-8"?>
2<!--
Brian O'Connor6547c0e2017-08-03 18:48:25 -07003 ~ Copyright 2016 Open Networking Foundation
Yuta HIGUCHI5a016cf2016-12-20 15:19:22 -08004 ~
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" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
18 <modelVersion>4.0.0</modelVersion>
19
20 <parent>
21 <groupId>org.onosproject</groupId>
22 <artifactId>onos-dependencies</artifactId>
23 <version>1.8.0</version>
24 <relativePath/> <!-- parent is remote -->
25 </parent>
26
27 <groupId>org.onosproject</groupId>
28 <artifactId>mef-nrp-api</artifactId>
29 <version>1.0-SNAPSHOT</version>
30 <packaging>bundle</packaging>
31
32 <description>ONOS MEF NRP API application for Carrier Ethernet app</description>
33 <url>http://onosproject.org</url>
34
35 <properties>
36 <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
37 <onos.version>1.8.0</onos.version>
38 <carrierethernet.version>1.8.0-SNAPSHOT</carrierethernet.version>
39 <onos.app.requires>org.onosproject.ecord.carrierethernet</onos.app.requires>
40 <api.version>1.0.0</api.version>
41 <onos.app.name>org.onosproject.mefnrpapi</onos.app.name>
42 <onos.app.title>MEF NRP REST API</onos.app.title>
43 <onos.app.category>default</onos.app.category>
44 <api.description>MEF NRP REST API for Carrier Ethernet app</api.description>
45 <web.context>/onos/mef-nrp-api</web.context>
46 <api.title>MEF NRP REST API</api.title>
47 <onos.app.url>http://onosproject.org</onos.app.url>
48 <api.package>org.onosproject.mefnrpapi</api.package>
49 <onos.app.readme>MEF NRP REST API for Carrier Ethernet app.</onos.app.readme>
50 <!-- Extra properties due to MEF NRP API -->
51 <swagger-core-version>1.5.10</swagger-core-version>
52 <servlet-api-version>2.5</servlet-api-version>
53 <jersey2-version>2.22.2</jersey2-version>
54 <!-- End of extra properties due to MEF NRP API -->
55 </properties>
56
Yuta HIGUCHI511b97c2017-11-20 11:02:18 -080057 <!-- Workaround for incompatible Carrier Ethernet app change-->
58 <repositories>
59 <repository>
60 <id>snapshots</id>
61 <url>https://oss.sonatype.org/content/repositories/snapshots</url>
62 <snapshots>
63 <enabled>true</enabled>
64 </snapshots>
65 </repository>
66 </repositories>
67
Yuta HIGUCHI5a016cf2016-12-20 15:19:22 -080068 <dependencies>
69 <dependency>
70 <groupId>org.onosproject</groupId>
71 <artifactId>onos-api</artifactId>
72 <version>${onos.version}</version>
73 </dependency>
74
75 <dependency>
76 <groupId>org.onosproject</groupId>
77 <artifactId>onlab-osgi</artifactId>
78 <version>${onos.version}</version>
79 </dependency>
80
81 <dependency>
82 <groupId>junit</groupId>
83 <artifactId>junit</artifactId>
84 <scope>test</scope>
85 </dependency>
86
87 <dependency>
88 <groupId>org.onosproject</groupId>
89 <artifactId>onos-api</artifactId>
90 <version>${onos.version}</version>
91 <scope>test</scope>
92 <classifier>tests</classifier>
93 </dependency>
94
95 <dependency>
96 <groupId>org.apache.felix</groupId>
97 <artifactId>org.apache.felix.scr.annotations</artifactId>
98 <scope>provided</scope>
99 </dependency>
100
101 <dependency>
102 <groupId>javax.ws.rs</groupId>
103 <artifactId>javax.ws.rs-api</artifactId>
104 <version>2.0.1</version>
105 <scope>provided</scope>
106 </dependency>
107
108 <dependency>
109 <groupId>com.fasterxml.jackson.core</groupId>
110 <artifactId>jackson-databind</artifactId>
111 <scope>provided</scope>
112 </dependency>
113
114 <dependency>
115 <groupId>org.onosproject</groupId>
116 <artifactId>onos-rest</artifactId>
117 <version>${onos.version}</version>
118 <scope>provided</scope>
119 </dependency>
120
121 <dependency>
122 <groupId>org.apache.karaf.shell</groupId>
123 <artifactId>org.apache.karaf.shell.console</artifactId>
124 <scope>provided</scope>
125 </dependency>
126
127 <dependency>
128 <groupId>com.fasterxml.jackson.core</groupId>
129 <artifactId>jackson-annotations</artifactId>
130 <scope>provided</scope>
131 </dependency>
132
133 <dependency>
134 <groupId>org.onosproject</groupId>
135 <artifactId>onos-cli</artifactId>
136 <version>${onos.version}</version>
137 <scope>provided</scope>
138 </dependency>
139
140 <dependency>
141 <groupId>org.glassfish.jersey.containers</groupId>
142 <artifactId>jersey-container-servlet</artifactId>
143 <scope>provided</scope>
144 </dependency>
145
146 <dependency>
147 <groupId>org.osgi</groupId>
148 <artifactId>org.osgi.core</artifactId>
149 <scope>provided</scope>
150 </dependency>
151
152 <dependency>
153 <groupId>org.onosproject</groupId>
154 <artifactId>onlab-rest</artifactId>
155 <version>${onos.version}</version>
156 <scope>provided</scope>
157 </dependency>
158
159 <dependency>
160 <groupId>org.onosproject</groupId>
161 <artifactId>onos-app-carrierethernet</artifactId>
162 <version>${carrierethernet.version}</version>
163 <scope>provided</scope>
164 </dependency>
165
166 <!-- Extra dependencies due to MEF NRP API code -->
167 <dependency>
168 <groupId>io.swagger</groupId>
169 <artifactId>swagger-jersey2-jaxrs</artifactId>
170 <scope>compile</scope>
171 <version>${swagger-core-version}</version>
172 </dependency>
173 <dependency>
174 <groupId>javax.servlet</groupId>
175 <artifactId>servlet-api</artifactId>
176 <version>${servlet-api-version}</version>
177 </dependency>
178 <dependency>
179 <groupId>org.glassfish.jersey.containers</groupId>
180 <artifactId>jersey-container-servlet-core</artifactId>
181 </dependency>
182 <dependency>
183 <groupId>org.glassfish.jersey.media</groupId>
184 <artifactId>jersey-media-multipart</artifactId>
185 </dependency>
186
187 <!-- End of extra dependencies due to MEF NRP API code -->
188
189 </dependencies>
190
191 <build>
192 <plugins>
193 <plugin>
194 <groupId>org.apache.maven.plugins</groupId>
195 <artifactId>maven-checkstyle-plugin</artifactId>
196 <configuration>
197 <excludes>org/onosproject/mefnrpapi/api/factories/**.java</excludes>
198 </configuration>
199 </plugin>
200 <plugin>
201 <groupId>org.apache.felix</groupId>
202 <artifactId>maven-bundle-plugin</artifactId>
203 <extensions>true</extensions>
204 <configuration>
205 <niceManifest>true</niceManifest>
206 <instructions>
207 <_wab>src/main/webapp/</_wab>
208 <Include-Resource>WEB-INF/classes/apidoc/swagger.json=src/main/resources/nrp.json,
209 {maven-resources}</Include-Resource>
210 <Bundle-SymbolicName>${project.groupId}.${project.artifactId}</Bundle-SymbolicName>
211 <Import-Package>
212 *,
213 org.glassfish.jersey.servlet
214 </Import-Package>
215 <Web-ContextPath>${web.context}</Web-ContextPath>
216 </instructions>
217 </configuration>
218 </plugin>
219
220 <plugin>
221 <groupId>org.apache.maven.plugins</groupId>
222 <artifactId>maven-compiler-plugin</artifactId>
223 <configuration>
224 <source>1.8</source>
225 <target>1.8</target>
226 <excludes>
227 <exclude>**/exclude/*.java</exclude>
228 </excludes>
229 </configuration>
230 </plugin>
231
232 <plugin>
233 <groupId>org.apache.felix</groupId>
234 <artifactId>maven-scr-plugin</artifactId>
235 <executions>
236 <execution>
237 <id>generate-scr-srcdescriptor</id>
238 <goals>
239 <goal>scr</goal>
240 </goals>
241 </execution>
242 </executions>
243 <configuration>
244 <scanClasses>true</scanClasses>
245 <supportedProjectTypes>
246 <supportedProjectType>bundle</supportedProjectType>
247 <supportedProjectType>war</supportedProjectType>
248 </supportedProjectTypes>
249 </configuration>
250 </plugin>
251
252 <plugin>
253 <groupId>org.onosproject</groupId>
254 <artifactId>onos-maven-plugin</artifactId>
255 </plugin>
256
257 <plugin>
258 <groupId>io.swagger</groupId>
259 <artifactId>swagger-codegen-maven-plugin</artifactId>
260 <version>2.2.1</version>
261 <executions>
262 <execution>
263 <goals>
264 <goal>generate</goal>
265 </goals>
266 <configuration>
267 <inputSpec>${basedir}/src/main/resources/nrp.json</inputSpec>
268 <language>jaxrs</language>
269 <library>jersey2</library>
270 <!-- will selectively add sourceFolder by build-helper-maven-plugin -->
271 <addCompileSourceRoot>false</addCompileSourceRoot>
272 <output>${project.build.directory}/swagger/</output>
273 <configOptions>
274 <title>MEF NRP REST Application</title>
275 <!-- Don't use java8 date. This adds dependency to jersey1 classes -->
276 <!-- <dateLibrary>java8</dateLibrary> -->
277 <apiPackage>org.onosproject.mefnrpapi.api</apiPackage>
278 <modelPackage>org.onosproject.mefnrpapi.api.model</modelPackage>
279 <!-- workaround for StringUtil package location -->
280 <invokerPackage>org.onosproject.mefnrpapi.api</invokerPackage>
281 <sourceFolder>src/main/java</sourceFolder>
282 <hideGenerationTimestamp>true</hideGenerationTimestamp>
283 <implFolder>impl/main/java/exclude</implFolder>
284 <library>jersey2</library>
285 <!-- Workaround until swagger-code-gen 2.2.2 is released.
286 https://github.com/swagger-api/swagger-codegen/issues/3509
287 -->
288 <additional-properties>jackson=true</additional-properties>
289 </configOptions>
290 <!-- Workaround until swagger-code-gen 2.2.2 is released.
291 https://github.com/swagger-api/swagger-codegen/issues/3509
292 -->
293 <templateDirectory>${basedir}/swaggergen/template</templateDirectory>
294 </configuration>
295 </execution>
296 </executions>
297 </plugin>
298
299 <plugin>
300 <groupId>org.codehaus.mojo</groupId>
301 <artifactId>build-helper-maven-plugin</artifactId>
302 <version>1.11</version>
303 <executions>
304 <execution>
305 <id>add-source</id>
306 <phase>generate-sources</phase>
307 <goals>
308 <goal>add-source</goal>
309 </goals>
310 <configuration>
311 <sources>
312 <!-- only import generated sourceFolder -->
313 <source>${project.build.directory}/swagger/src/main/java</source>
314 </sources>
315 </configuration>
316 </execution>
317 </executions>
318 </plugin>
319
320 </plugins>
321 </build>
322
323</project>