You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@uima.apache.org by re...@apache.org on 2019/03/20 17:25:58 UTC

[uima-uimafit] branch feature/UIMA-6009-Use-Maven-dependency-plugin-to-check-dependencies-3_0_x created (now e988ee0)

This is an automated email from the ASF dual-hosted git repository.

rec pushed a change to branch feature/UIMA-6009-Use-Maven-dependency-plugin-to-check-dependencies-3_0_x
in repository https://gitbox.apache.org/repos/asf/uima-uimafit.git.


      at e988ee0  [UIMA-6009] Use Maven dependency plugin to check dependencies

This branch includes the following new commits:

     new e988ee0  [UIMA-6009] Use Maven dependency plugin to check dependencies

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[uima-uimafit] 01/01: [UIMA-6009] Use Maven dependency plugin to check dependencies

Posted by re...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rec pushed a commit to branch feature/UIMA-6009-Use-Maven-dependency-plugin-to-check-dependencies-3_0_x
in repository https://gitbox.apache.org/repos/asf/uima-uimafit.git

commit e988ee0f9a3c8b40667aac747a66aa6ba524f997
Author: Richard Eckart de Castilho <re...@apache.org>
AuthorDate: Wed Mar 20 18:25:47 2019 +0100

    [UIMA-6009] Use Maven dependency plugin to check dependencies
    
    - Added Maven dependency plugin check
    - Formatting
    - Cleaned up dependencies
---
 uimafit-benchmark/pom.xml                          |  10 +-
 .../org/apache/uima/fit/benchmark/Benchmark.java   |   2 +-
 uimafit-cpe/pom.xml                                |   4 -
 uimafit-parent/pom.xml                             | 302 ++++++++++++---------
 4 files changed, 175 insertions(+), 143 deletions(-)

diff --git a/uimafit-benchmark/pom.xml b/uimafit-benchmark/pom.xml
index dc23ee7..2331060 100644
--- a/uimafit-benchmark/pom.xml
+++ b/uimafit-benchmark/pom.xml
@@ -42,14 +42,18 @@
       <version>3.0.0-SNAPSHOT</version>
     </dependency>
     <dependency>
+      <groupId>org.apache.uima</groupId>
+      <artifactId>uimaj-core</artifactId>
+    </dependency>
+    <dependency>
       <groupId>org.apache.commons</groupId>
       <artifactId>commons-math3</artifactId>
       <version>3.6.1</version>
     </dependency>
     <dependency>
-      <groupId>org.assertj</groupId>
-      <artifactId>assertj-core</artifactId>
-      <scope>test</scope>
+      <groupId>org.apache.commons</groupId>
+      <artifactId>commons-lang3</artifactId>
+      <version>3.8.1</version>
     </dependency>
     <dependency>
       <groupId>org.slf4j</groupId>
diff --git a/uimafit-benchmark/src/main/java/org/apache/uima/fit/benchmark/Benchmark.java b/uimafit-benchmark/src/main/java/org/apache/uima/fit/benchmark/Benchmark.java
index 1b998e3..b589e92 100644
--- a/uimafit-benchmark/src/main/java/org/apache/uima/fit/benchmark/Benchmark.java
+++ b/uimafit-benchmark/src/main/java/org/apache/uima/fit/benchmark/Benchmark.java
@@ -24,7 +24,7 @@ import java.util.function.IntConsumer;
 import java.util.function.IntFunction;
 import java.util.function.LongSupplier;
 
-import org.apache.commons.lang.StringUtils;
+import org.apache.commons.lang3.StringUtils;
 
 public class Benchmark {
     private IntConsumer initializer = t -> {};
diff --git a/uimafit-cpe/pom.xml b/uimafit-cpe/pom.xml
index d602e47..cc4b7db 100644
--- a/uimafit-cpe/pom.xml
+++ b/uimafit-cpe/pom.xml
@@ -41,10 +41,6 @@
       <groupId>org.apache.uima</groupId>
       <artifactId>uimaj-core</artifactId>
     </dependency>
-    <dependency>
-      <groupId>commons-io</groupId>
-      <artifactId>commons-io</artifactId>
-    </dependency>
     
     <dependency>
       <groupId>org.slf4j</groupId>
diff --git a/uimafit-parent/pom.xml b/uimafit-parent/pom.xml
index 2bbc5dd..fbcfd3f 100644
--- a/uimafit-parent/pom.xml
+++ b/uimafit-parent/pom.xml
@@ -1,4 +1,24 @@
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements. See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership. The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License. You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied. See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+<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">
   <modelVersion>4.0.0</modelVersion>
   <parent>
@@ -24,7 +44,7 @@
   <repositories>
     <!--
       - For UIMA/uimaFIT SNAPSHOTs
-      -->
+    -->
     <repository>
       <id>apache.snapshots</id>
       <name>Apache Snapshot Repository</name>
@@ -37,7 +57,7 @@
   <pluginRepositories>
     <!--
       - For UIMA/uimaFIT SNAPSHOTs
-      -->
+    -->
     <pluginRepository>
       <id>apache.snapshots.plugins</id>
       <name>Apache Snapshot Repository - Maven plugins</name>
@@ -53,7 +73,7 @@
       </snapshots>
     </pluginRepository>
   </pluginRepositories>
-    
+
   <dependencies>
     <dependency>
       <groupId>junit</groupId>
@@ -128,15 +148,15 @@
         <groupId>org.springframework</groupId>
         <artifactId>spring-context</artifactId>
         <version>${spring.version}</version>
-        <!--  
-         - This is excluded in the assembly and not here to avoid unwanted side-effects
-         - on users' projects.
-        <exclusions>
+        <!--
+          - This is excluded in the assembly and not here to avoid unwanted side-effects
+          - on users' projects.
+          <exclusions>
           <exclusion>
-            <groupId>org.springframework</groupId>
-            <artifactId>spring-aop</artifactId>
+          <groupId>org.springframework</groupId>
+          <artifactId>spring-aop</artifactId>
           </exclusion>
-        </exclusions>
+          </exclusions>
         -->
       </dependency>
       <dependency>
@@ -156,15 +176,28 @@
 
   <build>
     <plugins>
-      <!-- This should no longer be required with current versions of the maven-resources-plugin
       <plugin>
         <groupId>org.apache.maven.plugins</groupId>
-        <artifactId>maven-resources-plugin</artifactId>
+        <artifactId>maven-dependency-plugin</artifactId>
+        <executions>
+          <execution>
+            <id>default</id>
+            <phase>verify</phase>
+            <goals>
+              <goal>analyze-only</goal>
+            </goals>
+          </execution>
+        </executions>
         <configuration>
-          <encoding>${project.build.sourceEncoding}</encoding>
+          <failOnWarning>true</failOnWarning>
+          <ignoredDependencies combine.children="append">
+            <!-- 
+              - Logging is used via reflection and cannot be detected by Maven
+            -->
+            <ignoredDependency>org.slf4j:slf4j-simple</ignoredDependency>
+          </ignoredDependencies>
         </configuration>
       </plugin>
-      -->
       <plugin>
         <groupId>org.codehaus.gmaven</groupId>
         <artifactId>gmaven-plugin</artifactId>
@@ -179,10 +212,9 @@
             </goals>
             <configuration>
               <source>
-                def noticeFile = new File(project.basedir.path +
-                "/NOTICE");
+                def noticeFile = new File(project.basedir.path + "/NOTICE");
                 if (noticeFile.exists()) {
-                project.properties.postNoticeText = noticeFile.text;
+                  project.properties.postNoticeText = noticeFile.text;
                 }
               </source>
             </configuration>
@@ -192,70 +224,70 @@
     </plugins>
     <pluginManagement>
       <plugins>
-                <plugin>
-                    <groupId>org.apache.maven.plugins</groupId>
-                    <artifactId>maven-gpg-plugin</artifactId>
-                    <version>1.6</version>
-                </plugin>
-                <plugin>
-                    <groupId>org.apache.rat</groupId>
-                    <artifactId>apache-rat-plugin</artifactId>
-                    <version>0.11</version>
-                    <executions>
-                        <execution>
-                            <id>default-cli</id>
-                            <configuration>
-                                <excludes>
-                                    <!-- Plain documentation -->
-                                    <exclude>README*</exclude>
-                                    <!-- Release files -->
-                                    <exclude>RELEASE_NOTES*</exclude>
-                                    <exclude>issuesFixed/**</exclude>
-                                    <exclude>release.properties</exclude>
-                                    <!-- Build controls -->
-                                    <exclude>.activate-enforce-compatibility</exclude>
-                                </excludes>
-                            </configuration>
-                        </execution>
-                    </executions>
-                    <dependencies>
-                        <!-- https://issues.apache.org/jira/browse/RAT-158 -->
-                        <dependency>
-                            <groupId>org.apache.maven.doxia</groupId>
-                            <artifactId>doxia-core</artifactId>
-                            <version>1.7</version>
-                        </dependency>
-                    </dependencies>
-                </plugin>
-                <plugin>
-                    <groupId>org.apache.maven.plugins</groupId>
-                    <artifactId>maven-compiler-plugin</artifactId>
-                    <version>3.5.1</version>
-                    <configuration>
-                        <source>${maven.compiler.source}</source>
-                        <target>${maven.compiler.target}</target>
-                        <!--encoding>UTF-8</encoding this inherited from apache pom 7 -->
-                    </configuration>
-                </plugin>
-                <plugin>
-                    <groupId>org.apache.maven.plugins</groupId>
-                    <artifactId>maven-javadoc-plugin</artifactId>
-                    <version>2.10.3</version> 
-                    <executions>
-                        <execution>
-                            <id>attach-javadocs</id>
-                            <configuration>
-                                <source>${maven.compiler.source}</source>
-                            </configuration> 
-                        </execution>
-                        <execution>
-                            <id>default-cli</id>  <!-- Jenkins runs this apparently 3/2015 -->
-                            <configuration>
-                                <source>${maven.compiler.source}</source>
-                            </configuration> 
-                        </execution>
-                    </executions>
-                </plugin>
+        <plugin>
+          <groupId>org.apache.maven.plugins</groupId>
+          <artifactId>maven-gpg-plugin</artifactId>
+          <version>1.6</version>
+        </plugin>
+        <plugin>
+          <groupId>org.apache.rat</groupId>
+          <artifactId>apache-rat-plugin</artifactId>
+          <version>0.11</version>
+          <executions>
+            <execution>
+              <id>default-cli</id>
+              <configuration>
+                <excludes>
+                  <!-- Plain documentation -->
+                  <exclude>README*</exclude>
+                  <!-- Release files -->
+                  <exclude>RELEASE_NOTES*</exclude>
+                  <exclude>issuesFixed/**</exclude>
+                  <exclude>release.properties</exclude>
+                  <!-- Build controls -->
+                  <exclude>.activate-enforce-compatibility</exclude>
+                </excludes>
+              </configuration>
+            </execution>
+          </executions>
+          <dependencies>
+            <!-- https://issues.apache.org/jira/browse/RAT-158 -->
+            <dependency>
+              <groupId>org.apache.maven.doxia</groupId>
+              <artifactId>doxia-core</artifactId>
+              <version>1.7</version>
+            </dependency>
+          </dependencies>
+        </plugin>
+        <plugin>
+          <groupId>org.apache.maven.plugins</groupId>
+          <artifactId>maven-compiler-plugin</artifactId>
+          <version>3.5.1</version>
+          <configuration>
+            <source>${maven.compiler.source}</source>
+            <target>${maven.compiler.target}</target>
+            <!--encoding>UTF-8</encoding this inherited from apache pom 7 -->
+          </configuration>
+        </plugin>
+        <plugin>
+          <groupId>org.apache.maven.plugins</groupId>
+          <artifactId>maven-javadoc-plugin</artifactId>
+          <version>2.10.3</version>
+          <executions>
+            <execution>
+              <id>attach-javadocs</id>
+              <configuration>
+                <source>${maven.compiler.source}</source>
+              </configuration>
+            </execution>
+            <execution>
+              <id>default-cli</id>  <!-- Jenkins runs this apparently 3/2015 -->
+              <configuration>
+                <source>${maven.compiler.source}</source>
+              </configuration>
+            </execution>
+          </executions>
+        </plugin>
         <plugin>
           <groupId>org.apache.uima</groupId>
           <artifactId>jcasgen-maven-plugin</artifactId>
@@ -290,46 +322,46 @@
       </plugins>
     </pluginManagement>
   </build>
-    <profiles>
-        <profile>
-            <id>findbugs</id>
-            <build>
-                <pluginManagement>
-                    <plugins>
-                        <plugin>
-                            <groupId>org.codehaus.mojo</groupId>
-                            <artifactId>findbugs-maven-plugin</artifactId>
-                            <version>3.0.3</version>
-                            <executions>
-                                <execution>
-                                    <phase>package</phase>
-                                    <goals>
-                                        <goal>findbugs</goal>
-                                    </goals>
-                                </execution>
-                            </executions>
-                        </plugin>
-                    </plugins>
-                </pluginManagement>
-                <plugins>
-                    <plugin>
-                        <groupId>org.codehaus.mojo</groupId>
-                        <artifactId>findbugs-maven-plugin</artifactId>
-                    </plugin>
-                </plugins>
-            </build>
-        </profile>
-        <profile>
-            <id>enforce-compatibility</id>
-            <activation>
+  <profiles>
+    <profile>
+      <id>findbugs</id>
+      <build>
+        <pluginManagement>
+          <plugins>
+            <plugin>
+              <groupId>org.codehaus.mojo</groupId>
+              <artifactId>findbugs-maven-plugin</artifactId>
+              <version>3.0.3</version>
+              <executions>
+                <execution>
+                  <phase>package</phase>
+                  <goals>
+                    <goal>findbugs</goal>
+                  </goals>
+                </execution>
+              </executions>
+            </plugin>
+          </plugins>
+        </pluginManagement>
+        <plugins>
+          <plugin>
+            <groupId>org.codehaus.mojo</groupId>
+            <artifactId>findbugs-maven-plugin</artifactId>
+          </plugin>
+        </plugins>
+      </build>
+    </profile>
+    <profile>
+      <id>enforce-compatibility</id>
+      <activation>
         <file>
           <exists>.activate-enforce-compatibility</exists>
         </file>
-            </activation>
-            <build>
-                <pluginManagement>
-                    <plugins>
-                        <plugin>
+      </activation>
+      <build>
+        <pluginManagement>
+          <plugins>
+            <plugin>
               <groupId>org.apache.rat</groupId>
               <artifactId>apache-rat-plugin</artifactId>
               <executions>
@@ -354,11 +386,11 @@
             <version>0.9.3</version>
             <configuration>
               <oldVersion>
-                                <dependency>
+                <dependency>
                   <groupId>${project.groupId}</groupId>
                   <artifactId>${project.artifactId}</artifactId>
                   <version>${compat.previous.version}</version>
-                                </dependency>
+                </dependency>
               </oldVersion>
               <parameter>
                 <onlyModified>true</onlyModified>
@@ -366,10 +398,10 @@
                 <postAnalysisScript>${project.basedir}/../uimafit-parent/src/main/groovy/api-report.groovy</postAnalysisScript>
               </parameter>
             </configuration>
-                            <executions>
-                                <execution>
-                                    <phase>verify</phase>
-                                    <goals>
+            <executions>
+              <execution>
+                <phase>verify</phase>
+                <goals>
                   <goal>cmp</goal>
                 </goals>
               </execution>
@@ -385,8 +417,8 @@
                 <phase>install</phase>  <!-- must follow verify -->
                 <goals>
                   <goal>run</goal>
-                                    </goals>
-                                    <configuration>
+                </goals>
+                <configuration>
                   <target>
                     <taskdef name="if" classname="net.sf.antcontrib.logic.IfTask" />
                     <if>
@@ -398,12 +430,12 @@
                       </then>
                     </if>
                   </target>
-                                    </configuration>
-                                </execution>
-                            </executions>
-                        </plugin>
-                    </plugins>
-            </build>
-        </profile>
-    </profiles>
+                </configuration>
+              </execution>
+            </executions>
+          </plugin>
+        </plugins>
+      </build>
+    </profile>
+  </profiles>
 </project>
\ No newline at end of file