Roll to next snapshot
[ccsdk/parent.git] / odlparent / karaf4-parent / pom.xml
index b0aaa8f..c30342c 100644 (file)
@@ -14,7 +14,7 @@
 
     <groupId>org.onap.ccsdk.parent</groupId>
     <artifactId>karaf4-parent</artifactId>
-    <version>1.5.1-SNAPSHOT</version>
+    <version>1.5.2-SNAPSHOT</version>
     <packaging>pom</packaging>
 
     <name>ONAP :: ${project.groupId} :: ${project.artifactId}</name>
 
     <properties>
 
+        <!-- Sonar properties -->
+        <sonar.scanner.version>3.7.0.1746</sonar.scanner.version>
+        <sonar-jacoco-listeners.version>3.2</sonar-jacoco-listeners.version>
+        <sonar.core.codeCoveragePlugin>jacoco</sonar.core.codeCoveragePlugin>
+        <!-- Default Sonar configuration -->
+        <sonar.coverage.jacoco.xmlReportPaths>${project.reporting.outputDirectory}/jacoco-ut/jacoco.xml,${project.reporting.outputDirectory}/jacoco-it/jacoco.xml</sonar.coverage.jacoco.xmlReportPaths>
+        <!-- Note: This list should match jacoco-maven-plugin's exclusion list below -->
+        <sonar.exclusions>**/gen/**,**/generated-sources/**,**/yang-gen**,**/pax/**</sonar.exclusions>
+
+        <!-- Jacoco properties -->
+        <jacoco.version>0.8.5</jacoco.version>
+
         <!-- properties from oparent -->
         <maven.compiler.source>1.8</maven.compiler.source>
         <maven.compiler.target>1.8</maven.compiler.target>
         <onap.nexus.url>https://nexus.onap.org</onap.nexus.url>
         <!-- sitePath may be overridden in the inheriting POM if desired -->
         <sitePath>/content/sites/site/${project.groupId}/${project.artifactId}/${project.version}</sitePath>
-        <jacoco.version>0.7.7.201606060606</jacoco.version>
-        <sonar-jacoco-listeners.version>3.2</sonar-jacoco-listeners.version>
-        <sonar.core.codeCoveragePlugin>jacoco</sonar.core.codeCoveragePlugin>
-        <!-- Default Sonar configuration -->
-        <sonar.jacoco.reportPaths>target/code-coverage/jacoco-ut.exec,target/code-coverage/jacoco-it.exec</sonar.jacoco.reportPaths>
-        <!-- Note: This list should match jacoco-maven-plugin's exclusion list
-            below -->
-        <sonar.exclusions>**/gen/**,**/generated-sources/**,**/yang-gen**,**/pax/**</sonar.exclusions>
+
+
+
         <!-- If following file exist, auto-generation of swagger.json will be done -->
         <swagger-properties>${basedir}/src/main/resources/swagger.properties</swagger-properties>
         <!-- If following file exist, auto-generation of sdk will be done -->
         <salGeneratorPath>src/main/yang-gen-sal</salGeneratorPath>
         <checkstyle.skip>true</checkstyle.skip>
 
-        <sonar.language>java</sonar.language>
-        <sonar.java.coveragePlugin>jacoco</sonar.java.coveragePlugin>
-        <sonar.surefire.reportsPath>${project.build.directory}/surefire-reports</sonar.surefire.reportsPath>
-        <sonar.jacoco.reportMissing.force.zero>true</sonar.jacoco.reportMissing.force.zero>
-        <sonar.projectVersion>${project.version}</sonar.projectVersion>
+
 
         <!-- CCSDK component versions -->
+        <ccsdk.cds.version>0.7.0-SNAPSHOT</ccsdk.cds.version>
         <ccsdk.sli.core.version>0.7.0-SNAPSHOT</ccsdk.sli.core.version>
         <ccsdk.sli.adaptors.version>0.7.0-SNAPSHOT</ccsdk.sli.adaptors.version>
         <ccsdk.sli.northbound.version>0.7.0-SNAPSHOT</ccsdk.sli.northbound.version>
         <eelf.maven.plugin.version>1.0.0</eelf.maven.plugin.version>
 
         <!-- Managed dependency versions -->
-        <apache.httpcomponents.core.version>4.4.10</apache.httpcomponents.core.version>
-        <apache.httpcomponents.client.version>4.5.6</apache.httpcomponents.client.version>
+        <apache.httpcomponents.core.version>4.4.12</apache.httpcomponents.core.version>
+        <apache.httpcomponents.client.version>4.5.10</apache.httpcomponents.client.version>
         <derby.version>10.14.2.0</derby.version>
         <eelf.version>1.0.0</eelf.version>
-        <grpc.version>1.17.1</grpc.version>
-        <mariadb.connector.version>2.1.1</mariadb.connector.version>
-        <mariadb4j.version>2.2.3</mariadb4j.version>
-        <testng.version>6.11</testng.version>
+        <grpc.version>1.21.1</grpc.version>
+        <mariadb.connector.version>2.4.4</mariadb.connector.version>
+        <mariadb4j.version>2.4.0</mariadb4j.version>
+        <testng.version>6.14.3</testng.version>
         <tomcat-jdbc.version>9.0.27</tomcat-jdbc.version>
         <jetty.version>9.4.12.v20180830</jetty.version>
         <skip.karaf.featureTest>true</skip.karaf.featureTest>
+
+        <dependency-list.file>direct-dependencies.txt</dependency-list.file>
     </properties>
 
     <dependencyManagement>
             <dependency>
                 <groupId>org.onap.ccsdk.parent</groupId>
                 <artifactId>dependencies-odl-bom</artifactId>
-                <version>1.5.1-SNAPSHOT</version>
+                <version>1.5.2-SNAPSHOT</version>
                 <type>pom</type>
                 <scope>import</scope>
             </dependency>
                 <plugin>
                     <groupId>org.sonarsource.scanner.maven</groupId>
                     <artifactId>sonar-maven-plugin</artifactId>
-                    <version>3.6.0.1398</version>
+                    <version>${sonar.scanner.version}</version>
                 </plugin>
                 <!-- end of plugins from ONAP version (parent of oparent) -->
 
                 <!-- Plugins from ONAP oparent -->
 
-                <plugin>
-                    <groupId>org.jacoco</groupId>
-                    <artifactId>jacoco-maven-plugin</artifactId>
-                    <version>${jacoco.version}</version>
-                    <configuration>
-                        <!-- Note: This exclusion list should match <sonar.exclusions> property
-                            above -->
-                        <excludes>
-                            <exclude>**/gen/**</exclude>
-                            <exclude>**/generated-sources/**</exclude>
-                            <exclude>**/yang-gen/**</exclude>
-                            <exclude>**/pax/**</exclude>
-                        </excludes>
-                    </configuration>
-                    <executions>
-                        <!-- Prepares the property pointing to the JaCoCo runtime agent which
-                            is passed as VM argument when Maven the Surefire plugin is executed. -->
-                        <execution>
-                            <id>pre-unit-test</id>
-                            <goals>
-                                <goal>prepare-agent</goal>
-                            </goals>
-                            <configuration>
-                                <!-- Sets the path to the file which contains the execution data. -->
-                                <destFile>${project.build.directory}/code-coverage/jacoco-ut.exec</destFile>
-                                <!-- Sets the name of the property containing the settings for JaCoCo
-                                    runtime agent. -->
-                                <propertyName>surefireArgLine</propertyName>
-                            </configuration>
-                        </execution>
-                        <!-- Ensures that the code coverage report for unit tests is created
-                            after unit tests have been run. -->
-                        <execution>
-                            <id>post-unit-test</id>
-                            <phase>test</phase>
-                            <goals>
-                                <goal>report</goal>
-                            </goals>
-                            <configuration>
-                                <!-- Sets the path to the file which contains the execution data. -->
-                                <dataFile>${project.build.directory}/code-coverage/jacoco-ut.exec</dataFile>
-                                <!-- Sets the output directory for the code coverage report. -->
-                                <outputDirectory>${project.reporting.outputDirectory}/jacoco-ut</outputDirectory>
-                            </configuration>
-                        </execution>
-                        <execution>
-                            <id>pre-integration-test</id>
-                            <phase>pre-integration-test</phase>
-                            <goals>
-                                <goal>prepare-agent</goal>
-                            </goals>
-                            <configuration>
-                                <!-- Sets the path to the file which contains the execution data. -->
-                                <destFile>${project.build.directory}/code-coverage/jacoco-it.exec</destFile>
-                                <!-- Sets the name of the property containing the settings for JaCoCo
-                                    runtime agent. -->
-                                <propertyName>failsafeArgLine</propertyName>
-                            </configuration>
-                        </execution>
-                        <!-- Ensures that the code coverage report for integration tests after
-                            integration tests have been run. -->
-                        <execution>
-                            <id>post-integration-test</id>
-                            <phase>post-integration-test</phase>
-                            <goals>
-                                <goal>report</goal>
-                            </goals>
-                            <configuration>
-                                <!-- Sets the path to the file which contains the execution data. -->
-                                <dataFile>${project.build.directory}/code-coverage/jacoco-it.exec</dataFile>
-                                <!-- Sets the output directory for the code coverage report. -->
-                                <outputDirectory>${project.reporting.outputDirectory}/jacoco-it</outputDirectory>
-                            </configuration>
-                        </execution>
-                    </executions>
-                </plugin>
+
                 <plugin>
                     <groupId>org.apache.maven.plugins</groupId>
                     <artifactId>maven-surefire-plugin</artifactId>
                         <tag>${project.artifactId}-${project.version}</tag>
                     </configuration>
                 </plugin>
+                <plugin>
+                    <groupId>com.github.ferstl</groupId>
+                    <artifactId>depgraph-maven-plugin</artifactId>
+                    <version>3.3.0</version>
+                    <configuration>
+                        <graphFormat>text</graphFormat>
+                        <outputFileName>${dependency-list.file}</outputFileName>
+                        <outputDirectory>${project.basedir}</outputDirectory>
+                        <transitiveExcludes>*</transitiveExcludes>
+                        <showVersions>true</showVersions>
+                        <showGroupIds>true</showGroupIds>
+                    </configuration>
+                </plugin>
             </plugins>
         </pluginManagement>
         <plugins>
             <plugin>
                 <groupId>org.jacoco</groupId>
                 <artifactId>jacoco-maven-plugin</artifactId>
+                <version>${jacoco.version}</version>
+                <executions>
+                    <execution>
+                        <id>pre-unit-test</id>
+                        <goals>
+                            <goal>prepare-agent</goal>
+                        </goals>
+                        <configuration>
+                            <!-- Sets the path to the file which contains the execution data. -->
+                            <destFile>${project.build.directory}/code-coverage/jacoco-ut.exec</destFile>
+                            <!-- Sets the name of the property containing the settings for JaCoCo
+                                                                 runtime agent. -->
+                            <propertyName>surefireArgLine</propertyName>
+                        </configuration>
+                    </execution>
+                    <!-- Ensures that the code coverage report for unit tests is created
+                                                 after unit tests have been run. -->
+                    <execution>
+                        <id>post-unit-test</id>
+                        <phase>test</phase>
+                        <goals>
+                            <goal>report</goal>
+                        </goals>
+                        <configuration>
+                            <!-- Sets the path to the file which contains the execution data. -->
+                            <dataFile>${project.build.directory}/code-coverage/jacoco-ut.exec</dataFile>
+                            <!-- Sets the output directory for the code coverage report. -->
+                            <outputDirectory>${project.reporting.outputDirectory}/jacoco-ut</outputDirectory>
+                        </configuration>
+                    </execution>
+                    <execution>
+                        <id>pre-integration-test</id>
+                        <phase>pre-integration-test</phase>
+                        <goals>
+                            <goal>prepare-agent</goal>
+                        </goals>
+                        <configuration>
+                            <!-- Sets the path to the file which contains the execution data. -->
+                            <destFile>${project.build.directory}/code-coverage/jacoco-it.exec</destFile>
+                            <!-- Sets the name of the property containing the settings for JaCoCo
+                                                                 runtime agent. -->
+                            <propertyName>failsafeArgLine</propertyName>
+                        </configuration>
+                    </execution>
+                    <!-- Ensures that the code coverage report for integration tests after
+                                                 integration tests have been run. -->
+                    <execution>
+                        <id>post-integration-test</id>
+                        <phase>post-integration-test</phase>
+                        <goals>
+                            <goal>report</goal>
+                        </goals>
+                        <configuration>
+                            <!-- Sets the path to the file which contains the execution data. -->
+                            <dataFile>${project.build.directory}/code-coverage/jacoco-it.exec</dataFile>
+                            <!-- Sets the output directory for the code coverage report. -->
+                            <outputDirectory>${project.reporting.outputDirectory}/jacoco-it</outputDirectory>
+                        </configuration>
+                    </execution>
+                    <execution>
+                        <id>default-prepare-agent</id>
+                        <goals>
+                            <goal>prepare-agent</goal>
+                        </goals>
+                    </execution>
+                    <execution>
+                        <id>default-report</id>
+                        <phase>prepare-package</phase>
+                        <goals>
+                            <goal>report</goal>
+                        </goals>
+                    </execution>
+                    <execution>
+                        <id>default-check</id>
+                        <goals>
+                            <goal>check</goal>
+                        </goals>
+                        <configuration>
+                            <rules>
+                                <rule>
+                                    <element>PACKAGE</element>
+                                    <limits>
+                                        <limit>
+                                            <counter>COMPLEXITY</counter>
+                                            <value>COVEREDRATIO</value>
+                                            <minimum>0.0</minimum>
+                                        </limit>
+                                    </limits>
+                                </rule>
+                            </rules>
+                        </configuration>
+                    </execution>
+                </executions>
             </plugin>
             <plugin>
                 <groupId>org.apache.maven.plugins</groupId>
                     <additionalparam>-Xdoclint:none</additionalparam>
                 </configuration>
             </plugin>
+            <plugin>
+                <groupId>org.jacoco</groupId>
+                <artifactId>jacoco-maven-plugin</artifactId>
+                <version>${jacoco.version}</version>
+                <reportSets>
+                    <reportSet>
+                        <reports>
+                            <!-- select non-aggregate reports -->
+                            <report>report</report>
+                        </reports>
+                    </reportSet>
+                </reportSets>
+            </plugin>
         </plugins>
     </reporting>
 
                 </dependency>
             </dependencies>
         </profile>
-
+        <profile>
+            <id>sonar-jacoco-aggregate</id>
+            <activation>
+                <property>
+                    <name>onap.jacoco.aggregateFile</name>
+                </property>
+            </activation>
+            <build>
+                <plugins>
+                    <plugin>
+                        <groupId>org.jacoco</groupId>
+                        <artifactId>jacoco-maven-plugin</artifactId>
+                        <executions>
+                            <execution>
+                                <id>merge</id>
+                                <goals>
+                                    <goal>merge</goal>
+                                </goals>
+                                <phase>generate-resources</phase>
+                                <configuration>
+                                    <destFile>${onap.jacoco.aggregateFile}</destFile>
+                                    <fileSets>
+                                        <fileSet>
+                                            <directory>${project.basedir}</directory>
+                                            <includes>
+                                                <include>**/target/code-coverage/*.exec</include>
+                                            </includes>
+                                        </fileSet>
+                                    </fileSets>
+                                </configuration>
+                            </execution>
+                        </executions>
+                    </plugin>
+                </plugins>
+            </build>
+        </profile>
         <!-- End of profiles from ONAP oparent -->
 
         <profile>
                         </dependencies>
                         <executions>
                             <execution>
+                                <id>binding</id>
                                 <goals>
                                     <goal>generate-sources</goal>
                                 </goals>