Bump builder-helper-maven-plugin to 3.1.0
[odlparent.git] / odlparent-lite / pom.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!-- vi: set et smarttab sw=2 tabstop=2: -->
3 <!--
4  Copyright (c) 2015 The Linux Foundation and others.  All rights reserved.
5
6  This program and the accompanying materials are made available under the
7  terms of the Eclipse Public License v1.0 which accompanies this distribution,
8  and is available at http://www.eclipse.org/legal/epl-v10.html
9 -->
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   <modelVersion>4.0.0</modelVersion>
13
14   <!--
15       Note: This parent is not meant to be used by code artifacts. Please use
16             odlparent instead.
17   -->
18
19   <groupId>org.opendaylight.odlparent</groupId>
20   <artifactId>odlparent-lite</artifactId>
21   <version>7.0.2-SNAPSHOT</version>
22   <packaging>pom</packaging>
23   <name>ODL :: odlparent :: ${project.artifactId}</name>
24
25   <!-- Sufficient Metadata for Maven Central Repository deployment
26        These are default, some of which project inheriting from this POM may override (but don't have to, typically)
27        see http://central.sonatype.org/pages/requirements.html
28    -->
29   <url>${odl.site.url}/${project.groupId}/${stream}/${project.artifactId}/</url>
30   <description>OpenDaylight is leading the transformation to Open Software Defined Networking (SDN). For more information, please see https://www.opendaylight.org</description>
31
32   <licenses>
33     <license>
34       <name>Eclipse Public License v1.0</name>
35       <url>https://www.eclipse.org/legal/epl-v10.html</url>
36     </license>
37   </licenses>
38
39   <organization>
40     <name>OpenDaylight</name>
41     <url>https://www.opendaylight.org</url>
42   </organization>
43
44   <issueManagement>
45     <system>JIRA</system>
46     <url>https://jira.opendaylight.org/</url>
47   </issueManagement>
48
49   <ciManagement>
50     <system>Jenkins</system>
51     <url>https://jenkins.opendaylight.org/releng/</url>
52   </ciManagement>
53
54   <scm>
55     <url>https://git.opendaylight.org/gerrit/</url>
56   </scm>
57
58   <developers>
59     <developer>
60       <id>*</id>
61       <name>Please consult the PROJECT_INFO.yaml, README* and/or CONTRIBUTORS which should be included with this JAR</name>
62       <url>https://www.opendaylight.org</url>
63       <email>helpdesk@opendaylight.org</email>
64     </developer>
65   </developers>
66
67   <properties>
68     <nexusproxy>https://nexus.opendaylight.org/content</nexusproxy>
69
70     <!-- Variables required for Maven Site generation -->
71     <nexus.site.url>file:${user.dir}/target/staged-site</nexus.site.url>
72     <odl.site.url>https://nexus.opendaylight.org/content/sites/site/</odl.site.url>
73     <stream>latest</stream><!-- CI should pass in -Dstream={stream} -->
74
75     <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
76     <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
77
78     <!-- This version property instead of just direct version in pluginManagement is the exception that confirms the rule
79          and is required so that downstream users of the archetype-packaging extension can use this (and get the same version
80          as the maven-archetype-plugin), because there is no "extensionManagement" in Maven -->
81     <maven.archetype.plugin.version>3.1.2</maven.archetype.plugin.version>
82
83     <!-- This property allows deployments to be skipped in child modules -->
84     <maven.deploy.skip>false</maven.deploy.skip>
85
86     <!-- This property allows installations to be skipped in child modules -->
87     <maven.install.skip>false</maven.install.skip>
88
89     <!-- Opt-out from running maven-checkstyle-plugin at all. Defaults to false,
90          set to 'true' in pom.xml of project which desires to completely skip
91          execution. -->
92     <odlparent.checkstyle.skip>false</odlparent.checkstyle.skip>
93
94     <!-- Opt-out from running modernizer-maven-plugin at all. Defaults to false,
95          set to 'true' in pom.xml of project which desires to completely skip
96          execution. -->
97     <odlparent.modernizer.skip>false</odlparent.modernizer.skip>
98
99     <!-- Opt-out from running spotbugs-maven-plugin at all. Defaults to false,
100          set to 'true' in pom.xml of project which desires to completely skip
101          execution. -->
102     <odlparent.spotbugs.skip>false</odlparent.spotbugs.skip>
103
104     <!-- Used in neutron, ovsdb -->
105     <jacoco.version>0.8.5</jacoco.version>
106   </properties>
107
108   <build>
109     <pluginManagement>
110       <plugins>
111         <plugin>
112           <artifactId>maven-antrun-plugin</artifactId>
113           <version>1.8</version>
114         </plugin>
115         <plugin>
116           <artifactId>maven-archetype-plugin</artifactId>
117           <version>${maven.archetype.plugin.version}</version>
118         </plugin>
119         <plugin>
120           <artifactId>maven-assembly-plugin</artifactId>
121           <version>3.2.0</version>
122         </plugin>
123         <plugin>
124           <artifactId>maven-clean-plugin</artifactId>
125           <version>3.1.0</version>
126         </plugin>
127         <plugin>
128           <artifactId>maven-dependency-plugin</artifactId>
129           <version>3.1.2</version>
130         </plugin>
131         <plugin>
132           <artifactId>maven-deploy-plugin</artifactId>
133           <version>2.8.2</version>
134           <configuration>
135             <skip>${maven.deploy.skip}</skip>
136           </configuration>
137         </plugin>
138         <plugin>
139           <artifactId>maven-enforcer-plugin</artifactId>
140           <version>3.0.0-M3</version>
141         </plugin>
142         <plugin>
143           <artifactId>maven-help-plugin</artifactId>
144           <version>3.2.0</version>
145         </plugin>
146         <plugin>
147           <artifactId>maven-install-plugin</artifactId>
148           <version>2.5.2</version>
149           <configuration>
150             <skip>${maven.install.skip}</skip>
151           </configuration>
152         </plugin>
153         <plugin>
154           <artifactId>maven-javadoc-plugin</artifactId>
155           <version>3.1.1</version>
156           <configuration combine.children="append">
157             <!-- Keep things quiet except for warnings/errors -->
158             <quiet>true</quiet>
159             <tags>
160               <!-- support for HelpMojo generated by the maven-plugin-plugin -->
161               <tag>
162                 <name>goal</name>
163                 <placement>t</placement>
164                 <head>Goal:</head>
165               </tag>
166               <tag>
167                 <name>requiresProject</name>
168                 <placement>t</placement>
169                 <head>Requires project:</head>
170               </tag>
171               <tag>
172                 <name>threadSafe</name>
173                 <placement>t</placement>
174                 <head>Threadsafe</head>
175               </tag>
176               <tag>
177                 <name>phase</name>
178                 <placement>t</placement>
179                 <head>Phase:</head>
180               </tag>
181               <!-- end HelpMojo support -->
182             </tags>
183           </configuration>
184           <executions>
185             <execution>
186               <id>attach-javadocs</id>
187               <goals>
188                 <goal>jar</goal>
189               </goals>
190             </execution>
191           </executions>
192         </plugin>
193         <plugin>
194           <artifactId>maven-jar-plugin</artifactId>
195           <version>3.2.0</version>
196         </plugin>
197         <plugin>
198           <artifactId>maven-project-info-reports-plugin</artifactId>
199           <version>3.0.0</version>
200         </plugin>
201         <plugin>
202           <artifactId>maven-release-plugin</artifactId>
203           <version>2.5.3</version>
204         </plugin>
205         <plugin>
206           <artifactId>maven-resources-plugin</artifactId>
207           <version>3.1.0</version>
208         </plugin>
209         <plugin>
210           <artifactId>maven-site-plugin</artifactId>
211           <version>3.9.0</version>
212           <configuration>
213             <asciidoc>
214               <attributes>
215                 <imagesdir>./images</imagesdir>
216                 <imagesoutdir>${project.build.directory}/site/images</imagesoutdir>
217                 <icons>font</icons>
218                 <source-highlighter>coderay</source-highlighter>
219                 <coderay-css>style</coderay-css>
220               </attributes>
221               <requires>
222                 <require>asciidoctor-diagram</require>
223               </requires>
224             </asciidoc>
225           </configuration>
226           <dependencies>
227             <dependency>
228               <groupId>org.asciidoctor</groupId>
229               <artifactId>asciidoctor-maven-plugin</artifactId>
230               <version>1.5.8</version>
231             </dependency>
232             <dependency>
233               <groupId>org.asciidoctor</groupId>
234               <artifactId>asciidoctorj-diagram</artifactId>
235               <version>1.5.18</version>
236             </dependency>
237           </dependencies>
238         </plugin>
239         <plugin>
240           <groupId>org.codehaus.mojo</groupId>
241           <artifactId>build-helper-maven-plugin</artifactId>
242           <version>3.1.0</version>
243         </plugin>
244         <plugin>
245           <groupId>org.codehaus.mojo</groupId>
246           <artifactId>exec-maven-plugin</artifactId>
247           <version>1.6.0</version>
248         </plugin>
249         <plugin>
250           <groupId>org.codehaus.mojo</groupId>
251           <artifactId>jdepend-maven-plugin</artifactId>
252           <version>2.0</version>
253           <executions>
254             <execution>
255               <phase>site</phase>
256               <goals>
257                 <goal>generate-no-fork</goal>
258               </goals>
259             </execution>
260           </executions>
261         </plugin>
262         <plugin>
263           <groupId>org.codehaus.mojo</groupId>
264           <artifactId>versions-maven-plugin</artifactId>
265           <version>2.7</version>
266         </plugin>
267         <!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself.-->
268         <plugin>
269           <groupId>org.eclipse.m2e</groupId>
270           <artifactId>lifecycle-mapping</artifactId>
271           <version>1.0.0</version>
272           <configuration>
273             <lifecycleMappingMetadata>
274               <pluginExecutions>
275                 <pluginExecution>
276                   <pluginExecutionFilter>
277                     <groupId>pl.project13.maven</groupId>
278                     <artifactId>git-commit-id-plugin</artifactId>
279                     <versionRange>[1,)</versionRange>
280                     <goals>
281                       <goal>revision</goal>
282                     </goals>
283                   </pluginExecutionFilter>
284                   <action>
285                     <ignore></ignore>
286                   </action>
287                 </pluginExecution>
288                 <pluginExecution>
289                   <pluginExecutionFilter>
290                     <groupId>org.apache.maven.plugins</groupId>
291                     <artifactId>maven-dependency-plugin</artifactId>
292                     <versionRange>[2.10,)</versionRange>
293                     <goals>
294                       <goal>unpack</goal>
295                     </goals>
296                   </pluginExecutionFilter>
297                   <action>
298                     <ignore></ignore>
299                   </action>
300                 </pluginExecution>
301                 <pluginExecution>
302                   <pluginExecutionFilter>
303                     <groupId>org.apache.maven.plugins</groupId>
304                     <artifactId>maven-enforcer-plugin</artifactId>
305                     <versionRange>[1.0.0,)</versionRange>
306                     <goals>
307                       <goal>enforce</goal>
308                     </goals>
309                   </pluginExecutionFilter>
310                   <action>
311                     <ignore />
312                   </action>
313                 </pluginExecution>
314               </pluginExecutions>
315             </lifecycleMappingMetadata>
316           </configuration>
317         </plugin>
318         <plugin>
319           <groupId>org.jacoco</groupId>
320           <artifactId>jacoco-maven-plugin</artifactId>
321           <version>${jacoco.version}</version>
322         </plugin>
323       </plugins>
324     </pluginManagement>
325
326     <plugins>
327       <plugin>
328         <artifactId>maven-enforcer-plugin</artifactId>
329         <executions>
330           <execution>
331             <id>enforce-maven</id>
332             <configuration>
333               <rules>
334                 <requireJavaVersion>
335                   <version>11</version>
336                 </requireJavaVersion>
337                 <requireMavenVersion>
338                   <version>[3.5.0,)</version>
339                 </requireMavenVersion>
340               </rules>
341             </configuration>
342             <goals>
343               <goal>enforce</goal>
344             </goals>
345           </execution>
346         </executions>
347       </plugin>
348       <plugin>
349         <groupId>pl.project13.maven</groupId>
350         <artifactId>git-commit-id-plugin</artifactId>
351         <version>3.0.1</version>
352         <executions>
353           <execution>
354             <id>get-git-infos</id>
355             <goals>
356               <goal>revision</goal>
357             </goals>
358           </execution>
359         </executions>
360         <configuration>
361           <failOnNoGitDirectory>false</failOnNoGitDirectory>
362           <generateGitPropertiesFile>true</generateGitPropertiesFile>
363           <generateGitPropertiesFilename>${project.build.outputDirectory}/META-INF/git.properties</generateGitPropertiesFilename>
364           <gitDescribe>
365             <skip>false</skip>
366             <always>true</always>
367             <tags>true</tags>
368           </gitDescribe>
369           <!-- trust the working directory -->
370           <offline>true</offline>
371         </configuration>
372       </plugin>
373     </plugins>
374   </build>
375
376   <profiles>
377     <profile>
378       <id>ide</id>
379       <activation>
380         <property>
381           <name>m2e.version</name>
382         </property>
383       </activation>
384       <build>
385         <!-- Put the IDE's build output in a folder other than target, so that IDE builds don't interact with Maven builds -->
386         <directory>target-ide</directory>
387       </build>
388     </profile>
389     <profile>
390         <!-- http://blog2.vorburger.ch/2016/06/improve-maven-build-speed-with-q.html
391              q = http://memory-alpha.wikia.com/wiki/Q ;)
392
393              The Quick profile is used during incremental local development, when you want to "just get that JAR built",
394              which is very handy e.g. for fast hot reloading cycles in Karaf with bundle watch.  It (intentionally!) skips
395              tests, quality checks etc. which are great and useful to run before finally submitting changes to Gerrit, and
396              which all must run on Gerrit, but which are overhead during ongoing fast iterative local development.
397
398              Note that the idea here is that your IDE will already have run quality checks such as e.g. Checkstyle
399              while you typed the code anyway.  Similarly, if you wrote a test, you'll probably already have compiled and run it
400              from your IDE, so when you want the OSGi bundle JAR for Karaf, ASAP, you typically don't want all that to run again.
401           -->
402       <id>q</id>
403       <properties>
404         <skipTests>true</skipTests>
405             <!-- But NOT <maven.test.skip>true, as that's for compiling, not running, tests;
406                  and that's usually quick.  Skipping test compilation with -Pq with maven.test.skip would be
407                  particularly confusing when used in a project with maven-jar-plugin <goal>test-jar, so don't.)  -->
408         <skipIT>true</skipIT>
409         <skipITs>true</skipITs>
410         <skip.karaf.featureTest>true</skip.karaf.featureTest>
411         <jacoco.skip>true</jacoco.skip>
412         <maven.javadoc.skip>true</maven.javadoc.skip>
413         <maven.source.skip>true</maven.source.skip>
414         <odlparent.checkstyle.skip>true</odlparent.checkstyle.skip>
415         <odlparent.modernizer.skip>true</odlparent.modernizer.skip>
416         <odlparent.spotbugs.skip>true</odlparent.spotbugs.skip>
417         <pmd.skip>true</pmd.skip>
418         <cpd.skip>true</cpd.skip>
419         <maven.site.skip>true</maven.site.skip>
420         <invoker.skip>true</invoker.skip>
421         <enforcer.skip>true</enforcer.skip>
422         <duplicate-finder.skip>true</duplicate-finder.skip>
423         <mdsal.skip.verbose>true</mdsal.skip.verbose> <!-- Bug 6236 -->
424         <maven.gitcommitid.skip>true</maven.gitcommitid.skip>
425       </properties>
426     </profile>
427     <profile>
428       <!-- http://blog2.vorburger.ch/2016/06/maven-install-into-additional.html
429            mvn [-o -Pq] install -DaddInstallRepositoryPath=.../karaf/system is used in development to directly
430            install artifacts such as bundles and KARs not just into the global shared ~/.m2/repository
431            but also into the isolated Maven repo of a Karaf distribution.
432        -->
433       <activation>
434         <property>
435           <name>addInstallRepositoryPath</name>
436         </property>
437       </activation>
438       <build>
439         <plugins>
440           <plugin>
441             <artifactId>maven-install-plugin</artifactId>
442             <executions>
443               <execution>
444                 <id>additional-install</id>
445                 <phase>install</phase>
446                 <goals>
447                   <goal>install-file</goal>
448                 </goals>
449                 <configuration>
450                   <file>${project.build.directory}/${project.build.finalName}.jar</file>
451                   <localRepositoryPath>${addInstallRepositoryPath}</localRepositoryPath>
452                 </configuration>
453               </execution>
454             </executions>
455           </plugin>
456         </plugins>
457       </build>
458     </profile>
459     <profile>
460       <!--
461           This profile is to ensure we only build javadocs reports
462           when we plan to deploy Maven site for our project.
463
464           It activates by checking for the existance of deploy-site.xml in the
465           user's current working directory. (Intent is that this is run from
466           the Project root directory)
467       -->
468       <id>maven-site</id>
469       <activation>
470         <file>
471           <exists>${user.dir}/deploy-site.xml</exists>
472         </file>
473       </activation>
474
475       <build>
476         <plugins>
477           <plugin>
478             <artifactId>maven-site-plugin</artifactId>
479
480             <executions>
481               <execution>
482                 <id>generate-site</id>
483                 <phase>install</phase>
484                 <goals>
485                   <goal>site</goal>
486                   <goal>attach-descriptor</goal>
487                 </goals>
488               </execution>
489             </executions>
490           </plugin>
491         </plugins>
492       </build>
493
494       <reporting>
495         <plugins>
496           <plugin>
497             <artifactId>maven-project-info-reports-plugin</artifactId>
498             <configuration>
499               <dependencyLocationsEnabled>false</dependencyLocationsEnabled>
500             </configuration>
501             <reportSets>
502               <reportSet>
503                 <reports>
504                   <report>index</report>
505                 </reports>
506               </reportSet>
507             </reportSets>
508           </plugin>
509           <plugin>
510             <artifactId>maven-javadoc-plugin</artifactId>
511             <reportSets>
512               <reportSet>
513                 <reports>
514                   <report>javadoc-no-fork</report>
515                   <report>test-javadoc-no-fork</report>
516                 </reports>
517               </reportSet>
518             </reportSets>
519           </plugin>
520         </plugins>
521       </reporting>
522     </profile>
523     <profile>
524       <!-- Javadocs with links -->
525       <id>javadoc-links</id>
526         <activation>
527           <file>
528             <exists>odl-javadoc-links-optin</exists>
529           </file>
530         </activation>
531       <build>
532         <plugins>
533           <plugin>
534             <artifactId>maven-javadoc-plugin</artifactId>
535             <configuration combine.children="append">
536               <links>
537                 <link>https://junit.org/junit4/javadoc/4.13/</link>
538                 <link>http://hamcrest.org/JavaHamcrest/javadoc/2.2/</link>
539                 <link>http://google.github.io/truth/api/1.0.1/</link>
540                 <link>http://www.slf4j.org/apidocs/</link>
541                 <link>https://xerces.apache.org/xerces2-j/javadocs/api/</link>
542                 <link>https://google.github.io/guava/releases/28.2-jre/api/docs/</link>
543                 <link>http://doc.akka.io/japi/akka/2.5.31/</link>
544                 <link>http://netty.io/4.1/api/</link>
545                 <link>https://commons.apache.org/proper/commons-lang/javadocs/api-2.6/</link>
546                 <link>https://commons.apache.org/proper/commons-lang/javadocs/api-3.10/</link>
547                 <link>https://commons.apache.org/proper/commons-codec/apidocs/</link>
548               </links>
549             </configuration>
550           </plugin>
551         </plugins>
552       </build>
553     </profile>
554
555     <profile>
556       <!-- On JDK9-and-later specify html4 javadoc, if requested-->
557       <id>jdk9-javadoc</id>
558       <activation>
559         <jdk>[9,)</jdk>
560         <file>
561           <exists>odl-javadoc-html5-optout</exists>
562         </file>
563       </activation>
564       <build>
565         <plugins>
566           <plugin>
567             <artifactId>maven-javadoc-plugin</artifactId>
568             <configuration combine.children="append">
569               <additionalOptions>
570                 <additionalOption>-html4</additionalOption>
571               </additionalOptions>
572             </configuration>
573           </plugin>
574         </plugins>
575       </build>
576     </profile>
577
578     <profile>
579       <!-- Disable plugins which are not useful for sonar -->
580       <id>sonar-only</id>
581       <activation>
582         <property>
583           <name>sonar</name>
584         </property>
585       </activation>
586       <properties>
587         <checkstyle.skip>true</checkstyle.skip>
588         <duplicate-finder.skip>true</duplicate-finder.skip>
589         <skip.karaf.featureTest>true</skip.karaf.featureTest>
590         <maven.javadoc.skip>true</maven.javadoc.skip>
591         <maven.source.skip>true</maven.source.skip>
592       </properties>
593     </profile>
594   </profiles>
595
596   <distributionManagement>
597     <repository>
598       <id>opendaylight-release</id>
599       <url>${nexusproxy}/repositories/opendaylight.release/</url>
600     </repository>
601     <snapshotRepository>
602       <id>opendaylight-snapshot</id>
603       <url>${nexusproxy}/repositories/opendaylight.snapshot/</url>
604     </snapshotRepository>
605     <site>
606       <id>opendaylight-site</id>
607       <url>${nexus.site.url}/${project.artifactId}/</url>
608     </site>
609   </distributionManagement>
610 </project>