7e1ca6a51746ac291b1423db00800d808b4b3bbc
[openflowjava.git] / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <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">
3     <modelVersion>4.0.0</modelVersion>
4     <parent>
5         <groupId>org.opendaylight.odlparent</groupId>
6         <artifactId>odlparent</artifactId>
7         <version>1.5.0-SNAPSHOT</version>
8         <relativePath/>
9     </parent>
10
11     <groupId>org.opendaylight.openflowjava</groupId>
12     <artifactId>openflow-protocol-parent</artifactId>
13     <version>0.6.0-SNAPSHOT</version>
14     <name>openflowjava</name> <!-- Used by Sonar to set project name -->
15     <packaging>pom</packaging>
16
17     <modules>
18         <module>openflowjava-config</module>
19         <module>openflow-protocol-api</module>
20         <module>openflow-protocol-spi</module>
21         <module>util</module>
22         <module>openflow-protocol-impl</module>
23         <module>openflow-protocol-it</module>
24         <module>features</module>
25         <module>simple-client</module>
26     </modules>
27     <scm>
28         <connection>scm:git:ssh://git.opendaylight.org:29418/openflowjava.git</connection>
29         <developerConnection>scm:git:ssh://git.opendaylight.org:29418/openflowjava.git</developerConnection>
30         <url>https://wiki.opendaylight.org/view/Openflow_Protocol_Library:Main</url>
31       <tag>HEAD</tag>
32     </scm>
33
34     <properties>
35         <sitedeploy>dav:http://nexus.opendaylight.org/content/sites/site</sitedeploy>
36         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
37         <jmxGeneratorPath>${project.build.directory}/yang-gen-config</jmxGeneratorPath>
38         <karaf.distro.empty.version>1.5.0-SNAPSHOT</karaf.distro.empty.version>
39         <salGeneratorPath>${project.build.directory}/yang-gen-sal</salGeneratorPath>
40         <sonar.skippedModules>org.openflow.openflowj,net.sf.jung2</sonar.skippedModules>
41         <yang.prototype.version>1.2.0-SNAPSHOT</yang.prototype.version>
42         <ietf.model.version>2010.09.24.7-SNAPSHOT</ietf.model.version>
43         <yang.ext.version>2013.09.07.7-SNAPSHOT</yang.ext.version>
44         <yangtools.version>0.7.0-SNAPSHOT</yangtools.version>
45         <yangtools.generator.version>0.7.0-SNAPSHOT</yangtools.generator.version>
46         <mdsal.version>1.2.0-SNAPSHOT</mdsal.version>
47         <config.version>0.3.0-SNAPSHOT</config.version>
48
49         <!-- Sonar config -->
50         <sonar-jacoco-listeners.version>2.4</sonar-jacoco-listeners.version>
51         <sonar.core.codeCoveragePlugin>jacoco</sonar.core.codeCoveragePlugin>
52         <sonar.jacoco.reportPath>target/code-coverage/jacoco.exec</sonar.jacoco.reportPath>
53         <sonar.jacoco.itReportPath>target/code-coverage/jacoco-it.exec</sonar.jacoco.itReportPath>
54     </properties>
55
56     <dependencyManagement>
57         <dependencies>
58             <!-- feature dependencies -->
59             <dependency>
60               <groupId>org.opendaylight.yangtools</groupId>
61               <artifactId>features-yangtools</artifactId>
62               <version>${yangtools.version}</version>
63               <classifier>features</classifier>
64               <type>xml</type>
65             </dependency>
66             <dependency>
67               <groupId>org.opendaylight.controller</groupId>
68               <artifactId>features-config</artifactId>
69               <version>${config.version}</version>
70               <classifier>features</classifier>
71               <type>xml</type>
72             </dependency>
73             <dependency>
74                 <groupId>org.opendaylight.yangtools.model</groupId>
75                 <artifactId>ietf-inet-types</artifactId>
76                 <version>${ietf.model.version}</version>
77             </dependency>
78             <dependency>
79                 <groupId>org.opendaylight.yangtools.model</groupId>
80                 <artifactId>ietf-yang-types</artifactId>
81                 <version>${ietf.model.version}</version>
82             </dependency>
83             <dependency>
84                 <groupId>org.opendaylight.yangtools.model</groupId>
85                 <artifactId>yang-ext</artifactId>
86                 <version>${yang.ext.version}</version>
87             </dependency>
88             <dependency>
89                 <groupId>org.opendaylight.controller</groupId>
90                 <artifactId>config-api</artifactId>
91                 <version>0.3.0-SNAPSHOT</version>
92             </dependency>
93             <dependency>
94               <groupId>org.opendaylight.yangtools</groupId>
95               <artifactId>features-test</artifactId>
96               <version>${yangtools.version}</version>
97             </dependency>
98         </dependencies>
99     </dependencyManagement>
100
101     <dependencies>
102         <!-- Sonar -->
103         <dependency>
104             <groupId>org.codehaus.sonar-plugins.java</groupId>
105             <artifactId>sonar-jacoco-listeners</artifactId>
106             <version>${sonar-jacoco-listeners.version}</version>
107             <scope>test</scope>
108         </dependency>
109     </dependencies>
110
111     <build>
112         <plugins>
113             <plugin>
114                 <groupId>org.apache.maven.plugins</groupId>
115                 <artifactId>maven-compiler-plugin</artifactId>
116                 <inherited>true</inherited>
117                 <configuration>
118                     <source>1.7</source>
119                     <target>1.7</target>
120                 </configuration>
121             </plugin>
122             <plugin>
123                 <artifactId>maven-source-plugin</artifactId>
124                 <executions>
125                     <execution>
126                         <id>attach-sources</id>
127                         <phase>deploy</phase>
128                         <goals>
129                             <goal>jar-no-fork</goal>
130                         </goals>
131                     </execution>
132                 </executions>
133             </plugin>
134             <plugin>
135               <groupId>org.apache.felix</groupId>
136               <artifactId>maven-bundle-plugin</artifactId>
137               <extensions>true</extensions>
138               <configuration>
139                 <instructions>
140                   <Bundle-Name>${project.groupId}.${project.artifactId}</Bundle-Name>
141                 </instructions>
142                 <manifestLocation>${project.build.directory}/META-INF</manifestLocation>
143               </configuration>
144             </plugin>
145             <plugin>
146               <groupId>org.apache.maven.plugins</groupId>
147               <artifactId>maven-checkstyle-plugin</artifactId>
148               <version>2.12</version>
149               <configuration>
150                 <failOnViolation>false</failOnViolation>
151                 <configLocation>checkstyle-logging.xml</configLocation>
152                 <consoleOutput>true</consoleOutput>
153                 <includeTestSourceDirectory>true</includeTestSourceDirectory>
154                 <sourceDirectory>${project.basedir}</sourceDirectory>
155                 <includes>**\/*.java,**\/*.xml,**\/*.ini,**\/*.sh,**\/*.bat,**\/*.yang</includes>
156                 <excludes>**\/target\/,**\/bin\/,**\/target-ide\/,**\/src/main/yang-gen-config\/,**\/src/main/yang-gen-sal\/</excludes>
157               </configuration>
158               <dependencies>
159                 <dependency>
160                 <groupId>org.opendaylight.yangtools</groupId>
161                 <artifactId>checkstyle-logging</artifactId>
162                 <version>${yangtools.version}</version>
163                 </dependency>
164               </dependencies>
165               <executions>
166                 <execution>
167                 <goals>
168                   <goal>check</goal>
169                 </goals>
170                 </execution>
171               </executions>
172             </plugin>
173             <plugin>
174                 <groupId>org.codehaus.mojo</groupId>
175                 <artifactId>build-helper-maven-plugin</artifactId>
176             </plugin>
177             <plugin>
178                 <groupId>org.jacoco</groupId>
179                 <artifactId>jacoco-maven-plugin</artifactId>
180                 <executions>
181                     <execution>
182                         <id>prepare-ut-agent</id>
183                         <phase>process-test-classes</phase>
184                         <goals>
185                             <goal>prepare-agent</goal>
186                         </goals>
187                         <configuration>
188                             <destFile>${sonar.jacoco.reportPath}</destFile>
189                             <propertyName>jacoco.agent.ut.arg</propertyName>
190                         </configuration>
191                     </execution>
192                     <execution>
193                         <id>prepare-it-agent</id>
194                         <phase>pre-integration-test</phase>
195                         <goals>
196                             <goal>prepare-agent</goal>
197                         </goals>
198                         <configuration>
199                             <destFile>${sonar.jacoco.itReportPath}</destFile>
200                             <propertyName>jacoco.agent.it.arg</propertyName>
201                         </configuration>
202                     </execution>
203                 </executions>
204             </plugin>
205         </plugins>
206         <pluginManagement>
207             <plugins>
208                 <plugin>
209                     <groupId>org.opendaylight.yangtools</groupId>
210                     <artifactId>yang-maven-plugin</artifactId>
211                     <version>${yangtools.version}</version>
212                 </plugin>
213                 <plugin>
214                     <groupId>org.codehaus.mojo</groupId>
215                     <artifactId>build-helper-maven-plugin</artifactId>
216                     <version>1.8</version>
217                     <executions>
218                         <execution>
219                             <id>add-source</id>
220                             <goals>
221                                 <goal>add-source</goal>
222                             </goals>
223                             <phase>generate-sources</phase>
224                             <configuration>
225                                 <sources>
226                                     <source>src/main/yang</source>
227                                 </sources>
228                             </configuration>
229                         </execution>
230                     </executions>
231                 </plugin>
232                 <plugin>
233                     <groupId>org.apache.maven.plugins</groupId>
234                     <artifactId>maven-failsafe-plugin</artifactId>
235                     <configuration>
236                         <!-- Specific to generate mapping between tests and covered code -->
237                         <argLine>${jacoco.agent.it.arg}</argLine>
238                         <properties>
239                             <property>
240                                 <name>listener</name>
241                                 <value>org.sonar.java.jacoco.JUnitListener</value>
242                             </property>
243                         </properties>
244                         <!-- Let's put failsafe reports with surefire to have access to tests failures/success reports in sonar -->
245                         <reportsDirectory>${project.build.directory}/surefire-reports</reportsDirectory>
246                     </configuration>
247                 </plugin>
248                 <plugin>
249                     <groupId>org.apache.maven.plugins</groupId>
250                     <artifactId>maven-surefire-plugin</artifactId>
251                     <configuration>
252                         <!-- Specific to generate mapping between tests and covered code -->
253                         <argLine>${jacoco.agent.ut.arg}</argLine>
254                         <properties>
255                             <property>
256                                 <name>listener</name>
257                                 <value>org.sonar.java.jacoco.JUnitListener</value>
258                             </property>
259                         </properties>
260                     </configuration>
261                 </plugin>
262                 <!-- Ignore/Execute plugin execution -->
263                 <plugin>
264                   <groupId>org.eclipse.m2e</groupId>
265                   <artifactId>lifecycle-mapping</artifactId>
266                   <version>1.0.0</version>
267                   <configuration>
268                     <lifecycleMappingMetadata>
269                       <pluginExecutions>
270                         <pluginExecution>
271                           <pluginExecutionFilter>
272                             <groupId>org.codehaus.mojo</groupId>
273                             <artifactId>properties-maven-plugin</artifactId>
274                             <versionRange>[0.0,)</versionRange>
275                             <goals>
276                               <goal>set-system-properties</goal>
277                             </goals>
278                           </pluginExecutionFilter>
279                           <action>
280                             <ignore/>
281                           </action>
282                         </pluginExecution>
283                         <pluginExecution>
284                           <pluginExecutionFilter>
285                             <groupId>org.codehaus.enunciate</groupId>
286                             <artifactId>maven-enunciate-plugin</artifactId>
287                             <versionRange>[0.0,)</versionRange>
288                             <goals>
289                               <goal>docs</goal>
290                             </goals>
291                           </pluginExecutionFilter>
292                           <action>
293                             <ignore/>
294                           </action>
295                         </pluginExecution>
296                         <pluginExecution>
297                           <pluginExecutionFilter>
298                             <groupId>org.jacoco</groupId>
299                             <artifactId>jacoco-maven-plugin</artifactId>
300                             <versionRange>[0.0,)</versionRange>
301                             <goals>
302                               <goal>prepare-agent</goal>
303                               <goal>pre-test</goal>
304                               <goal>post-test</goal>
305                             </goals>
306                           </pluginExecutionFilter>
307                           <action>
308                             <ignore/>
309                           </action>
310                         </pluginExecution>
311                         <pluginExecution>
312                           <pluginExecutionFilter>
313                             <groupId>org.ops4j.pax.exam</groupId>
314                             <artifactId>maven-paxexam-plugin</artifactId>
315                             <versionRange>[1.2.4,)</versionRange>
316                             <goals>
317                               <goal>generate-depends-file</goal>
318                             </goals>
319                           </pluginExecutionFilter>
320                           <action>
321                             <execute>
322                               <runOnIncremental>false</runOnIncremental>
323                             </execute>
324                           </action>
325                         </pluginExecution>
326                         <pluginExecution>
327                           <pluginExecutionFilter>
328                             <groupId>org.apache.maven.plugins</groupId>
329                             <artifactId>maven-checkstyle-plugin</artifactId>
330                             <versionRange>[2.0,)</versionRange>
331                             <goals>
332                               <goal>check</goal>
333                             </goals>
334                           </pluginExecutionFilter>
335                           <action>
336                             <ignore/>
337                           </action>
338                         </pluginExecution>
339                         <pluginExecution>
340                           <pluginExecutionFilter>
341                             <groupId>org.opendaylight.yangtools</groupId>
342                             <artifactId>yang-maven-plugin</artifactId>
343                             <versionRange>[0.5,)</versionRange>
344                             <goals>
345                               <goal>generate-sources</goal>
346                             </goals>
347                           </pluginExecutionFilter>
348                           <action>
349                             <execute/>
350                           </action>
351                         </pluginExecution>
352                         <pluginExecution>
353                           <pluginExecutionFilter>
354                             <groupId>org.codehaus.groovy.maven</groupId>
355                             <artifactId>gmaven-plugin</artifactId>
356                             <versionRange>1.0</versionRange>
357                             <goals>
358                               <goal>execute</goal>
359                             </goals>
360                           </pluginExecutionFilter>
361                           <action>
362                             <ignore/>
363                           </action>
364                         </pluginExecution>
365                         <pluginExecution>
366                           <pluginExecutionFilter>
367                             <groupId>org.apache.maven.plugins</groupId>
368                             <artifactId>maven-enforcer-plugin</artifactId>
369                             <versionRange>${enforcer.version}</versionRange>
370                             <goals>
371                               <goal>enforce</goal>
372                             </goals>
373                           </pluginExecutionFilter>
374                           <action>
375                             <ignore/>
376                           </action>
377                         </pluginExecution>
378                       </pluginExecutions>
379                     </lifecycleMappingMetadata>
380                   </configuration>
381                 </plugin>
382             </plugins>
383         </pluginManagement>
384     </build>
385     <reporting>
386         <plugins>
387             <plugin>
388                 <groupId>org.codehaus.mojo</groupId>
389                 <artifactId>findbugs-maven-plugin</artifactId>
390                 <version>2.5.2</version>
391                 <configuration>
392                     <effort>Max</effort>
393                     <threshold>Low</threshold>
394                     <goal>site</goal>
395                 </configuration>
396             </plugin>
397             <plugin>
398               <artifactId>maven-jxr-plugin</artifactId>
399               <version>2.3</version>
400               <configuration>
401                 <aggregate>true</aggregate>
402                 <linkJavadoc>true</linkJavadoc>
403               </configuration>
404             </plugin>
405
406             <plugin>
407                 <groupId>org.codehaus.mojo</groupId>
408                 <artifactId>jdepend-maven-plugin</artifactId>
409                 <version>2.0-beta-2</version>
410             </plugin>
411         </plugins>
412     </reporting>
413     <profiles>
414         <profile>
415             <id>viewbuild</id>
416             <activation>
417                 <activeByDefault>true</activeByDefault>
418             </activation>
419             <properties>
420                 <build.suffix>${project.version}</build.suffix>
421             </properties>
422         </profile>
423         <profile>
424             <id>jenkins</id>
425             <activation>
426                 <property>
427                     <name>BUILDSUFFIX</name>
428                 </property>
429             </activation>
430             <properties>
431                 <build.suffix>${BUILDSUFFIX}</build.suffix>
432             </properties>
433         </profile>
434         <profile>
435             <id>repoBuild</id>
436             <build>
437                 <plugins>
438                     <plugin>
439                         <groupId>org.apache.maven.plugins</groupId>
440                         <artifactId>maven-javadoc-plugin</artifactId>
441                         <version>2.8.1</version>
442                         <executions>
443                             <execution>
444                                 <goals>
445                                     <goal>aggregate</goal>
446                                 </goals>
447                                 <phase>site</phase>
448                             </execution>
449                             <execution>
450                                 <id>attach-javadocs</id>
451                                 <goals>
452                                     <goal>jar</goal>
453                                 </goals>
454                             </execution>
455                         </executions>
456                     </plugin>
457                     <plugin>
458                         <groupId>org.apache.maven.plugins</groupId>
459                         <artifactId>maven-source-plugin</artifactId>
460                         <executions>
461                             <execution>
462                                 <id>attach-sources</id>
463                                 <phase>package</phase>
464                                 <goals>
465                                     <goal>jar-no-fork</goal>
466                                 </goals>
467                             </execution>
468                         </executions>
469                     </plugin>
470                 </plugins>
471             </build>
472         </profile>
473     </profiles>
474 </project>