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 2020/04/23 21:44:14 UTC

[uima-uimaj] 01/01: Merge branch 'master-v2' into sync-master-v2-to-master

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

rec pushed a commit to branch sync-master-v2-to-master
in repository https://gitbox.apache.org/repos/asf/uima-uimaj.git

commit 86cb158abefd4711fd21599c8ac2e511921e0d2c
Merge: 332769e a63872a
Author: Richard Eckart de Castilho <re...@apache.org>
AuthorDate: Thu Apr 23 23:43:55 2020 +0200

    Merge branch 'master-v2' into sync-master-v2-to-master
    
    * master-v2:
      [UIMA-6200] Constructing aggregate engines is slow
      [UIMA-6200] Constructing aggregate engines is slow
      [UIMA-6200] Constructing aggregate engines is slow
      [UIMA-6200] Constructing aggregate engines is slow
      [UIMA-6187] add eol=lf for .sh files
      [UIMA-6128] hook up xcas-1-1 to save
    
    # Conflicts:
    #	uimaj-core/pom.xml
    #	uimaj-core/src/main/java/org/apache/uima/util/CasIOUtils.java
    #	uimaj-core/src/test/java/org/apache/uima/flow/impl/FixedFlowControllerTest.java
    #	uimaj-parent/pom.xml

 uimaj-core/pom.xml                                 |    8 +-
 .../impl/CapabilityLanguageFlowController.java     |   35 +-
 .../apache/uima/flow/impl/FixedFlowController.java |  119 ++-
 .../main/java/org/apache/uima/util/CasIOUtils.java |    6 +-
 .../uima/flow/CapabilityLanguageFlowController.xml |   56 +-
 .../org/apache/uima/flow/FixedFlowController.xml   |   10 +-
 .../impl/CapabilityLanguageFlowControllerTest.java |   62 ++
 .../uima/flow/impl/FixedFlowControllerTest.java    |   56 +-
 .../CapabilityLanguageFlowController.xml           |    0
 .../FixedFlowController.xml                        |    0
 uimaj-parent/pom.xml                               | 1007 ++++++++++----------
 11 files changed, 782 insertions(+), 577 deletions(-)

diff --cc uimaj-core/pom.xml
index eb12807,7d9bc63..efa4498
--- a/uimaj-core/pom.xml
+++ b/uimaj-core/pom.xml
@@@ -139,7 -73,13 +139,13 @@@
  			<version>${project.parent.version}</version>
  			<scope>test</scope>
  		</dependency>
- 				<!--  Uncomment one of these to add Saxon8 or 9 to the classpath for JUnit tests. 
+ 		<dependency>
+ 			<groupId>org.assertj</groupId>
+ 			<artifactId>assertj-core</artifactId>
+ 			<scope>test</scope>
+ 		</dependency>
+ 
 -		<!--  Uncomment one of these to add Saxon8 or 9 to the classpath for JUnit tests. 
++		<!--  Uncomment one of these to add Saxon8 or 9 to the classpath for JUnit tests.
  		      1 fails due to different formatting and a dropped xmlns attribute, 
  		      5 work when run separately or by mvn, but fail when running all tests from Eclipse:
  		          Caused by: org.xml.sax.SAXParseException: cvc-elt.1: Cannot find the declaration of element '....'
diff --cc uimaj-core/src/main/java/org/apache/uima/flow/impl/FixedFlowController.java
index 42d0cf8,0e33b26..dc3d5ad
--- a/uimaj-core/src/main/java/org/apache/uima/flow/impl/FixedFlowController.java
+++ b/uimaj-core/src/main/java/org/apache/uima/flow/impl/FixedFlowController.java
@@@ -85,10 -87,10 +87,10 @@@ public class FixedFlowController extend
    //   on different threads. However, users will not re-initialize this with a different 
    //   flowControllerContext while this object is controlling CASes from the previous Object.
    // When this was a synchronized list, some contention observed between the "reads", which can be eliminated by
-   //   swtiching this to a copy-on-write kind of final list.
+   //   switching this to a copy-on-write kind of final list.
    //      -- this has the added "benefit" (maybe eventually) of having better semantics for letting existing
    //         Flow objects continue to use the "old" settings, and only the new ones picking up the new ones.
 -  final private List<String> mSequence = new CopyOnWriteArrayList<String>();  //UIMA-4013
 +  final private List<String> mSequence = new CopyOnWriteArrayList<>();  //UIMA-4013
  
    private int mActionAfterCasMultiplier;
  
@@@ -101,10 -104,10 +104,10 @@@ public synchronized void initialize(Flo
      FlowConstraints flowConstraints = aContext.getAggregateMetadata().getFlowConstraints();
      if (flowConstraints instanceof FixedFlow) {
        String[] sequence = ((FixedFlow) flowConstraints).getFixedFlow();
 -      ArrayList<String> keysToAdd = new ArrayList<String>(sequence.length);
 +      ArrayList<String> keysToAdd = new ArrayList<>(sequence.length);
        for( String key : sequence ) {
      	  if( !aContext.getAnalysisEngineMetaDataMap().containsKey(key) )
-     		  throw new ResourceInitializationException(ResourceInitializationException.FLOW_CONTROLLER_MISSING_DELEGATE,
+             throw new ResourceInitializationException(ResourceInitializationException.FLOW_CONTROLLER_MISSING_DELEGATE,
                    new Object[]{this.getClass().getName(), key, aContext.getAggregateMetadata().getSourceUrlString()});
          keysToAdd.add(key);
        }
diff --cc uimaj-core/src/test/java/org/apache/uima/flow/impl/FixedFlowControllerTest.java
index a183c14,e8f4115..6ee9939
--- a/uimaj-core/src/test/java/org/apache/uima/flow/impl/FixedFlowControllerTest.java
+++ b/uimaj-core/src/test/java/org/apache/uima/flow/impl/FixedFlowControllerTest.java
@@@ -18,6 -18,15 +18,12 @@@
   */
  package org.apache.uima.flow.impl;
  
 -import static java.lang.System.currentTimeMillis;
+ import static org.apache.uima.UIMAFramework.getXMLParser;
+ import static org.assertj.core.api.Assertions.assertThat;
+ import static org.junit.Assert.assertEquals;
+ import static org.junit.Assert.assertTrue;
+ 
 -import java.io.IOException;
+ import java.io.StringWriter;
 -import java.net.URL;
  import java.util.ArrayList;
  import java.util.Collections;
  import java.util.HashMap;
@@@ -40,21 -51,19 +47,18 @@@ import org.apache.uima.resource.metadat
  import org.apache.uima.resource.metadata.impl.OperationalProperties_impl;
  import org.apache.uima.resource.metadata.impl.TypeSystemDescription_impl;
  import org.apache.uima.util.CasCreationUtils;
 -import org.apache.uima.util.InvalidXMLException;
+ import org.apache.uima.util.XMLInputSource;
+ import org.junit.Before;
+ import org.junit.Test;
  
- import junit.framework.TestCase;
- 
- 
- public class FixedFlowControllerTest extends TestCase {
+ public class FixedFlowControllerTest {
  
    private Map<String, AnalysisEngineMetaData> analysisEngineMetaDataMap;
    private FixedFlowController fixedFlowController;
    
-   /* (non-Javadoc)
-    * @see junit.framework.TestCase#setUp()
-    */
-   protected void setUp() throws Exception {
-     super.setUp();
+   @Before
+   public void setUp() throws Exception {
 -    analysisEngineMetaDataMap = new HashMap<String, AnalysisEngineMetaData>();
 +    analysisEngineMetaDataMap = new HashMap<>();
      AnalysisEngineMetaData delegateMd = new AnalysisEngineMetaData_impl();
      delegateMd.setOperationalProperties(new OperationalProperties_impl());
      analysisEngineMetaDataMap.put("key1", delegateMd);
diff --cc uimaj-parent/pom.xml
index c842ea2,b1b1892..e357ccb
--- a/uimaj-parent/pom.xml
+++ b/uimaj-parent/pom.xml
@@@ -1,501 -1,167 +1,506 @@@
- <?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.
- -->
- 
- <!-- This pom serves as the the UIMA Java SDK (uimaj) common parent pom,
-      and may include overrides to the project-wide parent-pom.
-      Over time, things in this pom which apply to
-      other projects within UIMA are migrated to the
-      project-wide parent pom.
-  -->
- 
- <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/maven-v4_0_0.xsd">
-   <modelVersion>4.0.0</modelVersion>
- 
-   <parent>
-     <groupId>org.apache.uima</groupId>
-     <artifactId>parent-pom</artifactId>
-     <relativePath />
-     <version>13</version>
-   </parent>
- 
-   <groupId>org.apache.uima</groupId>
-   <artifactId>uimaj-parent</artifactId>
-   <packaging>pom</packaging>
-   <version>3.1.1-SNAPSHOT</version>
-   <name>Apache UIMA Java SDK: ${project.artifactId}</name>
-   <description>The common parent pom for the uimaj SDK</description>
-   <url>${uimaWebsiteUrl}</url>
- 
-   <!-- Special inheritance note
-        even though the <scm> element that follows is exactly the
-        same as those in super poms, it cannot be inherited because
-        there is some special code that computes the connection elements
-        from the chain of parent poms, if this is omitted.
- 
-        Keeping this a bit factored allows cutting/pasting the <scm>
-        element, and just changing the following two properties -->
-   <scm>
-     <connection>
-       scm:git:https://github.com/apache/uima-uimaj/uimaj-parent
-     </connection>
-     <developerConnection>
-       scm:git:https://github.com/apache/uima-uimaj/uimaj-parent
-     </developerConnection>
-     <url>
-       https://github.com/apache/uima-uimaj/tree/master/uimaj-parent
-     </url>
-     <tag>HEAD</tag>
-   </scm>
- 
-   <!-- The repositories and pluginRepositories section is duplicated from
-        the parent pom one, and adds the Apache Snapshot Nexus repository
-        where UIMA snapshots are deployed.  This is needed if for instance,
-        a project depends on some new SNAPSHOT level of a build tool, 
-        where the users hasn't checked out the build tooling.
-        
-        This allows maven to find the snapshots when looking for the parent of
-        this pom -->
-   <repositories>
-     <repository>
-       <id>eclipsePlugins</id>
-       <name>Eclipse components</name>
-       <layout>default</layout>
-       <url>https://repo1.maven.org/eclipse</url>
-       
-       <releases>
-         <updatePolicy>never</updatePolicy>
-         <checksumPolicy>fail</checksumPolicy>
-       </releases>
-       
-       <snapshots>
-         <enabled>false</enabled>
-       </snapshots>
-     </repository>
- 
-     <!-- modify central repository access:
-          Turn on checksum checking-->
-     <repository>
-       <id>central</id>
-       <name>Maven Repository Switchboard</name>
-       <layout>default</layout>
-       <url>https://repo1.maven.org/maven2</url>
- 
-       <releases>
-         <enabled>true</enabled>
-         <checksumPolicy>fail</checksumPolicy>
-         <updatePolicy>never</updatePolicy>
-       </releases>
- 
-       <snapshots>
-         <enabled>false</enabled>
-       </snapshots>
- 
-     </repository>
-     
-     <repository>
-       <id>apache.snapshots</id>
-       <name>Apache Snapshot Repository</name>
-       <url>https://repository.apache.org/snapshots</url>
-       <releases>
-         <enabled>false</enabled>
-       </releases>
-     </repository>    
-     
-   </repositories>
-   
-   <pluginRepositories>
-     <pluginRepository>
-       <id>apache.snapshots.plugins</id>
-       <name>Apache Snapshot Repository - Maven plugins</name>
-       <url>https://repository.apache.org/snapshots</url>
-       <layout>default</layout>
-       <releases>
-         <enabled>false</enabled>
-       </releases>
-       <snapshots>
-         <enabled>true</enabled>
-         <checksumPolicy>fail</checksumPolicy>
-         <updatePolicy>never</updatePolicy>        
-       </snapshots>
-     </pluginRepository>
-   </pluginRepositories>
-   
-   <properties>
-     <uimaScmRoot>uimaj</uimaScmRoot>
-     <uimaScmProject>${project.artifactId}</uimaScmProject>
- 
-     <!-- 
-      Configuring settings is best done through default properties that multiple plugins.
-      Local configurations within plugins should be avoided. Where plugins do not pick up default
-      properties already, they should be injected manually into the plugins. 
-     --> 
-     <slf4j.version>1.7.25</slf4j.version>
-     <log4j.version>2.10.0</log4j.version>
-     <jackson.version>2.9.2</jackson.version>
-     
-     <maven.compiler.target>1.8</maven.compiler.target>
-     <maven.compiler.source>1.8</maven.compiler.source>
-     <maven.surefire.heap>512m</maven.surefire.heap>
-     <maven.surefire.argLine />
-     <maven.surefire.java9 />
-     
-     <jacoco.argLine />
-     <api_check_oldVersion>3.1.1</api_check_oldVersion>
-   </properties>
-   
-   <dependencyManagement>
-     <dependencies>
-       <dependency>
-         <groupId>junit</groupId>
-         <artifactId>junit</artifactId>
-         <version>4.12</version>
-         <scope>test</scope>
-       </dependency>
-       <dependency>
-         <groupId>org.assertj</groupId>
-         <artifactId>assertj-core</artifactId>
-         <version>3.14.0</version>
-         <scope>test</scope>
-       </dependency>
-       <!-- set dependency versions for logger parts -->
-       <dependency>
-         <groupId>org.slf4j</groupId>
-         <artifactId>slf4j-jdk14</artifactId>
-         <version>${slf4j.version}</version>
-       </dependency>
-       <dependency>
-         <groupId>org.slf4j</groupId>
-         <artifactId>slf4j-api</artifactId>
-         <version>${slf4j.version}</version>
-       </dependency>
-     </dependencies>
-   </dependencyManagement>
-   
-   <dependencies>
-     <!-- Used to enable findbug rule suppression annotations -->
-     <!-- This is the Apache v2 license version -->      
-     <dependency>
-       <groupId>com.github.stephenc.findbugs</groupId>
-       <artifactId>findbugs-annotations</artifactId>
-       <version>1.3.9-1</version>
-       <scope>provided</scope>
-     </dependency>
-   </dependencies>
-   
-   <build>
-     <pluginManagement>
-       <plugins>
-         
-         <plugin>
-           <groupId>org.apache.maven.plugins</groupId>
-           <artifactId>maven-surefire-plugin</artifactId>
-           <configuration>
-             <argLine>@{jacoco.argLine} -Xmx@{maven.surefire.heap} -Xms@{maven.surefire.heap} @{maven.surefire.argLine} @{maven.surefire.java9}</argLine>
-           </configuration>
-         </plugin>
-                 
-         <plugin>
-           <groupId>org.apache.rat</groupId>
-           <artifactId>apache-rat-plugin</artifactId>
-           <executions>
-             <execution>
-               <id>default-cli</id>
-               <configuration>
-                 <excludes combine.children="append">
-                   <exclude>src/main/run_configuration/*.launch</exclude>
-                 </excludes>    
-               </configuration>
-             </execution>
-           </executions>
-         </plugin>   
-         
-         <!-- https://issues.apache.org/jira/browse/UIMA-5367 -->
-         <plugin> 
-           <groupId>org.apache.maven.plugins</groupId> 
-           <artifactId>maven-deploy-plugin</artifactId>
-           <configuration> 
-             <retryFailedDeploymentCount>10</retryFailedDeploymentCount> 
-           </configuration> 
-         </plugin>
-          
-       </plugins>
-     </pluginManagement>
-     
-   </build>
-   <profiles>
-     
-     <profile>
-       <id>pmd</id>
-       <build>
-         <plugins>
-           <plugin>
-             <groupId>org.apache.maven.plugins</groupId>
-             <artifactId>maven-pmd-plugin</artifactId>
-             <executions>
-               <execution>
-                 <phase>package</phase>
-                 <goals>
-                   <goal>cpd</goal>
-                   <goal>pmd</goal>
-                 </goals>
-                 <configuration>
-                   <sourceEncoding>${project.build.sourceEncoding}</sourceEncoding>
-                   <targetJdk>${maven.compiler.target}</targetJdk>
-                   <linkXRef>false</linkXRef>
-                 </configuration>
-               </execution>
-             </executions>
-           </plugin>
-         </plugins>
-       </build>
-     </profile>
-     
-     <profile>
-       <id>findbugs</id>
-       <build>
-         <plugins>
-           <plugin>
-             <groupId>org.codehaus.mojo</groupId>
-             <artifactId>findbugs-maven-plugin</artifactId>
-             <executions>
-               <execution>
-                 <phase>package</phase>
-                 <goals>
-                   <goal>findbugs</goal>
-                 </goals>
-                 <configuration>
-                   <findbugsXmlOutput>true</findbugsXmlOutput>
-                   <xmlOutput>true</xmlOutput>
-                 </configuration>
-               </execution>
-             </executions>
-           </plugin>
-         </plugins>
-       </build>
-     </profile>
-     <profile>
-       <id>cobertura</id>
-       <build>
-         <plugins>
-           <plugin>
-             <groupId>org.codehaus.mojo</groupId>
-             <artifactId>cobertura-maven-plugin</artifactId>
-             <executions>
-               <execution>
-                 <phase>package</phase>
-                 <goals>
-                   <goal>cobertura</goal>
-                 </goals>
-                 <configuration>
-                   <formats>
-                     <format>xml</format>
-                   </formats>
-                 </configuration>
-               </execution>
-             </executions>
-           </plugin>
-         </plugins>
-       </build>
-     </profile>
-     <profile>
-       <id>jacoco</id>
-       <build>
-         <plugins>
-           <plugin>
-             <groupId>org.jacoco</groupId>
-             <artifactId>jacoco-maven-plugin</artifactId>
-             <configuration>
-               <excludes combine.children="append">
-                 <!-- Duplicates on classpath cause an exception in JaCoCo report -->
-                 <exclude>**/org/apache/uima/examples/SourceDocumentInformation*</exclude>
-                 <exclude>**/org/apache/uima/examples/SourceDocumentInformation_Type*</exclude>
-               </excludes>
-             </configuration>
-             <executions>
-               <execution>
-                 <id>default-prepare-agent</id>
-                 <goals>
-                   <goal>prepare-agent</goal>
-                 </goals>
-                 <configuration>
-                   <propertyName>jacoco.argLine</propertyName>
-                 </configuration>
-               </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 />
-                 </configuration>
-               </execution>
-             </executions>
-           </plugin>
-         </plugins>
-       </build>
-     </profile>
-     
-     <!-- **********  Backwards compatibility report generation profile ************** -->
-     <profile>
-       <id>enforce-compatibility</id>
-       <activation>
-         <file>
-           <exists>marker-file-identifying-api-compatibility-check</exists>
-         </file>
-       </activation>
-       <build>
- 
-         <pluginManagement>
-           <plugins>
-             <plugin>
- 	            <groupId>org.apache.rat</groupId>
- 		          <artifactId>apache-rat-plugin</artifactId>
- 		          <executions>
- 		            <execution>
- 		              <id>default-cli</id>
- 		              <configuration>
- 		                <excludes combine.children="append">
- 	                    <exclude>**/api-change-report/**/*.*</exclude>
- 		                </excludes>
- 		              </configuration>
- 		            </execution>
- 	          </executions>
- 	          </plugin>
-           </plugins>
-         </pluginManagement>
-          
-         <plugins>
-           <!-- https://siom79.github.io/japicmp/MavenPlugin.html -->
-           <plugin>              
-             <groupId>com.github.siom79.japicmp</groupId>
-             <artifactId>japicmp-maven-plugin</artifactId>
-             <version>0.13.0</version>
-             <configuration>
-               <oldVersion>
-                 <dependency>
-                   <groupId>${project.groupId}</groupId>
-                   <artifactId>${project.artifactId}</artifactId>
-                   <version>${api_check_oldVersion}</version>
-                 </dependency>
-               </oldVersion> 
-               <parameter>
-                 <onlyModified>true</onlyModified>
-                 <!-- filter out classes with impl in their package or class name -->
-                 <postAnalysisScript>${project.basedir}/../uimaj-parent/src/main/groovy/api-report.groovy</postAnalysisScript>                  
-               </parameter>
-             </configuration>
-             <executions>
-               <execution>
-                 <phase>verify</phase>
-                 <goals>
-                   <goal>cmp</goal>
-                 </goals>
-               </execution>
-             </executions>
-           </plugin>
-           
-           <!-- This copy is to have the api change report included in the source distribution -->
-           <plugin>
-             <artifactId>maven-antrun-plugin</artifactId>
-             <executions>
-               <execution>
-                 <id>copy-API-change-report</id>
-                 <phase>install</phase>  <!-- must follow verify -->
-                 <goals><goal>run</goal></goals>
-                 <configuration>
-                   <target>
-                     <taskdef name="if" classname="net.sf.antcontrib.logic.IfTask" />
-                     <if>
-                       <available file="${project.build.directory}/japicmp/" />
-                       <then>
-                         <copy toDir="${basedir}/api-change-report">
-                           <fileset dir="${project.build.directory}/japicmp" />
-                         </copy>
-                       </then>
-                     </if>
-                   </target>
-                 </configuration>
-               </execution>
-             </executions>
-             
-           </plugin>
-         </plugins>
-       </build>
-     </profile>
-     
-     <!-- ************** m2e  profile ************* -->
-     <profile>
-       <id>m2e</id>
-       <activation>
-         <property>
-           <name>m2e.version</name>
-         </property>
-       </activation>
-       <build>
-         <pluginManagement>
-           <plugins>         
-             <!-- This plugin's configuration is used to store Eclipse m2e settings 
-                 only. It has no influence on the Maven build itself. -->
-             <plugin>
-               <groupId>org.eclipse.m2e</groupId>
-               <artifactId>lifecycle-mapping</artifactId>
-               <version>1.0.0</version>
-               <configuration>
-                 <lifecycleMappingMetadata>
-                   <pluginExecutions>
-                   
-                     <!-- ***************************** -->
-                     <!-- IGNORE maven-bundle-plugin    -->
-                     <!-- ***************************** -->
-                     <pluginExecution>
-                       <pluginExecutionFilter>
-                         <groupId>org.apache.felix</groupId>
-                         <artifactId>
-                           maven-bundle-plugin
-                         </artifactId>
-                         <versionRange>[3,)</versionRange>
-                         <goals>
-                           <goal>process</goal>
-                           <goal>bundle</goal>
-                           <goal>manifest</goal>
-                         </goals>
-                       </pluginExecutionFilter>
-                       <action>
-                         <ignore />
-                       </action>
-                     </pluginExecution>
-                   </pluginExecutions>
-                 </lifecycleMappingMetadata>
-               </configuration>
-             </plugin>
-           </plugins>
-         </pluginManagement>
-       </build>
-     </profile>  
-   </profiles>
- </project>
+ <?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.
+ -->
+ 
+ <!-- This pom serves as the the UIMA Java SDK (uimaj) common parent pom,
+      and may include overrides to the project-wide parent-pom.
+      Over time, things in this pom which apply to
+      other projects within UIMA are migrated to the
+      project-wide parent pom.
+  -->
+ 
+ <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/maven-v4_0_0.xsd">
+   <modelVersion>4.0.0</modelVersion>
+ 
+   <parent>
+     <groupId>org.apache.uima</groupId>
+     <artifactId>parent-pom</artifactId>
+     <relativePath />
 -    <version>14-SNAPSHOT</version>
++    <version>13</version>
+   </parent>
+ 
+   <groupId>org.apache.uima</groupId>
+   <artifactId>uimaj-parent</artifactId>
+   <packaging>pom</packaging>
 -  <version>2.10.5-SNAPSHOT</version>
++  <version>3.1.1-SNAPSHOT</version>
+   <name>Apache UIMA Java SDK: ${project.artifactId}</name>
+   <description>The common parent pom for the uimaj SDK</description>
+   <url>${uimaWebsiteUrl}</url>
+ 
+   <!-- Special inheritance note
+        even though the <scm> element that follows is exactly the
+        same as those in super poms, it cannot be inherited because
+        there is some special code that computes the connection elements
+        from the chain of parent poms, if this is omitted.
+ 
+        Keeping this a bit factored allows cutting/pasting the <scm>
+        element, and just changing the following two properties -->
+   <scm>
+     <connection>
 -      scm:git:https://github.com/apache/uima-uimaj/tree/master-v2/uimaj-parent
++      scm:git:https://github.com/apache/uima-uimaj/uimaj-parent
+     </connection>
+     <developerConnection>
 -      scm:git:https://github.com/apache/uima-uimaj/tree/master-v2/uimaj-parent
++      scm:git:https://github.com/apache/uima-uimaj/uimaj-parent
+     </developerConnection>
+     <url>
 -      https://github.com/apache/uima-uimaj/tree/master-v2/uimaj-parent
++      https://github.com/apache/uima-uimaj/tree/master/uimaj-parent
+     </url>
++    <tag>HEAD</tag>
+   </scm>
+ 
+   <!-- The repositories and pluginRepositories section is duplicated from
+        the parent pom one, and adds the Apache Snapshot Nexus repository
+        where UIMA snapshots are deployed.  This is needed if for instance,
+        a project depends on some new SNAPSHOT level of a build tool, 
+        where the users hasn't checked out the build tooling.
+        
+        This allows maven to find the snapshots when looking for the parent of
+        this pom -->
+   <repositories>
++    <repository>
++      <id>eclipsePlugins</id>
++      <name>Eclipse components</name>
++      <layout>default</layout>
++      <url>https://repo1.maven.org/eclipse</url>
++      
++      <releases>
++        <updatePolicy>never</updatePolicy>
++        <checksumPolicy>fail</checksumPolicy>
++      </releases>
++      
++      <snapshots>
++        <enabled>false</enabled>
++      </snapshots>
++    </repository>
+ 
+     <!-- modify central repository access:
+          Turn on checksum checking-->
+     <repository>
+       <id>central</id>
+       <name>Maven Repository Switchboard</name>
+       <layout>default</layout>
+       <url>https://repo1.maven.org/maven2</url>
+ 
+       <releases>
+         <enabled>true</enabled>
+         <checksumPolicy>fail</checksumPolicy>
+         <updatePolicy>never</updatePolicy>
+       </releases>
+ 
+       <snapshots>
+         <enabled>false</enabled>
+       </snapshots>
++
+     </repository>
+     
+     <repository>
+       <id>apache.snapshots</id>
+       <name>Apache Snapshot Repository</name>
+       <url>https://repository.apache.org/snapshots</url>
+       <releases>
+         <enabled>false</enabled>
+       </releases>
+     </repository>    
+     
+   </repositories>
+   
+   <pluginRepositories>
+     <pluginRepository>
+       <id>apache.snapshots.plugins</id>
+       <name>Apache Snapshot Repository - Maven plugins</name>
+       <url>https://repository.apache.org/snapshots</url>
+       <layout>default</layout>
+       <releases>
+         <enabled>false</enabled>
+       </releases>
+       <snapshots>
+         <enabled>true</enabled>
+         <checksumPolicy>fail</checksumPolicy>
+         <updatePolicy>never</updatePolicy>        
+       </snapshots>
+     </pluginRepository>
+   </pluginRepositories>
+   
+   <properties>
+     <uimaScmRoot>uimaj</uimaScmRoot>
+     <uimaScmProject>${project.artifactId}</uimaScmProject>
 -    <!-- 
 -     BACKWARD_COMPATIBLE_IMPLEMENTER - patch version (=.=.+)
 -     BACKWARD_COMPATIBLE_USER        - minor version (=.+.0)
 -     NON_BACKWARD_COMPATIBLE         - major version (+.0.0)
 -     -->
 -    <compat.level>BACKWARD_COMPATIBLE_USER</compat.level>
 -    <compat.previous.version>2.10.3</compat.previous.version>
 -    <api_check_oldVersion>2.10.3</api_check_oldVersion>
+ 
+     <!-- 
+      Configuring settings is best done through default properties that multiple plugins.
+      Local configurations within plugins should be avoided. Where plugins do not pick up default
+      properties already, they should be injected manually into the plugins. 
 -    -->    
 -    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
++    --> 
++    <slf4j.version>1.7.25</slf4j.version>
++    <log4j.version>2.10.0</log4j.version>
++    <jackson.version>2.9.2</jackson.version>
++    
+     <maven.compiler.target>1.8</maven.compiler.target>
+     <maven.compiler.source>1.8</maven.compiler.source>
++    <maven.surefire.heap>512m</maven.surefire.heap>
++    <maven.surefire.argLine />
++    <maven.surefire.java9 />
+     
 -    <japicmp.postAnalysisScript>${project.basedir}/../uimaj-parent/src/main/groovy/api-report.groovy</japicmp.postAnalysisScript>
++    <jacoco.argLine />
++    <api_check_oldVersion>3.1.1</api_check_oldVersion>
+   </properties>
 -
++  
+   <dependencyManagement>
+     <dependencies>
+       <dependency>
+         <groupId>junit</groupId>
+         <artifactId>junit</artifactId>
+         <version>4.12</version>
+         <scope>test</scope>
+       </dependency>
+       <dependency>
+         <groupId>org.assertj</groupId>
+         <artifactId>assertj-core</artifactId>
+         <version>3.14.0</version>
++        <scope>test</scope>
++      </dependency>
++      <!-- set dependency versions for logger parts -->
++      <dependency>
++        <groupId>org.slf4j</groupId>
++        <artifactId>slf4j-jdk14</artifactId>
++        <version>${slf4j.version}</version>
++      </dependency>
++      <dependency>
++        <groupId>org.slf4j</groupId>
++        <artifactId>slf4j-api</artifactId>
++        <version>${slf4j.version}</version>
+       </dependency>
+       <dependency>
+         <groupId>xmlunit</groupId>
+         <artifactId>xmlunit</artifactId>
+         <version>1.6</version>
+       </dependency>
+     </dependencies>
+   </dependencyManagement>
++  
++  <dependencies>
++    <!-- Used to enable findbug rule suppression annotations -->
++    <!-- This is the Apache v2 license version -->      
++    <dependency>
++      <groupId>com.github.stephenc.findbugs</groupId>
++      <artifactId>findbugs-annotations</artifactId>
++      <version>1.3.9-1</version>
++      <scope>provided</scope>
++    </dependency>
++  </dependencies>
++  
++  <build>
++    <pluginManagement>
++      <plugins>
++        
++        <plugin>
++          <groupId>org.apache.maven.plugins</groupId>
++          <artifactId>maven-surefire-plugin</artifactId>
++          <configuration>
++            <argLine>@{jacoco.argLine} -Xmx@{maven.surefire.heap} -Xms@{maven.surefire.heap} @{maven.surefire.argLine} @{maven.surefire.java9}</argLine>
++          </configuration>
++        </plugin>
++                
++        <plugin>
++          <groupId>org.apache.rat</groupId>
++          <artifactId>apache-rat-plugin</artifactId>
++          <executions>
++            <execution>
++              <id>default-cli</id>
++              <configuration>
++                <excludes combine.children="append">
++                  <exclude>src/main/run_configuration/*.launch</exclude>
++                </excludes>    
++              </configuration>
++            </execution>
++          </executions>
++        </plugin>   
++        
++        <!-- https://issues.apache.org/jira/browse/UIMA-5367 -->
++        <plugin> 
++          <groupId>org.apache.maven.plugins</groupId> 
++          <artifactId>maven-deploy-plugin</artifactId>
++          <configuration> 
++            <retryFailedDeploymentCount>10</retryFailedDeploymentCount> 
++          </configuration> 
++        </plugin>
++         
++      </plugins>
++    </pluginManagement>
++    
++  </build>
++  <profiles>
++    
++    <profile>
++      <id>pmd</id>
++      <build>
++        <plugins>
++          <plugin>
++            <groupId>org.apache.maven.plugins</groupId>
++            <artifactId>maven-pmd-plugin</artifactId>
++            <executions>
++              <execution>
++                <phase>package</phase>
++                <goals>
++                  <goal>cpd</goal>
++                  <goal>pmd</goal>
++                </goals>
++                <configuration>
++                  <sourceEncoding>${project.build.sourceEncoding}</sourceEncoding>
++                  <targetJdk>${maven.compiler.target}</targetJdk>
++                  <linkXRef>false</linkXRef>
++                </configuration>
++              </execution>
++            </executions>
++          </plugin>
++        </plugins>
++      </build>
++    </profile>
++    
++    <profile>
++      <id>findbugs</id>
++      <build>
++        <plugins>
++          <plugin>
++            <groupId>org.codehaus.mojo</groupId>
++            <artifactId>findbugs-maven-plugin</artifactId>
++            <executions>
++              <execution>
++                <phase>package</phase>
++                <goals>
++                  <goal>findbugs</goal>
++                </goals>
++                <configuration>
++                  <findbugsXmlOutput>true</findbugsXmlOutput>
++                  <xmlOutput>true</xmlOutput>
++                </configuration>
++              </execution>
++            </executions>
++          </plugin>
++        </plugins>
++      </build>
++    </profile>
++    <profile>
++      <id>cobertura</id>
++      <build>
++        <plugins>
++          <plugin>
++            <groupId>org.codehaus.mojo</groupId>
++            <artifactId>cobertura-maven-plugin</artifactId>
++            <executions>
++              <execution>
++                <phase>package</phase>
++                <goals>
++                  <goal>cobertura</goal>
++                </goals>
++                <configuration>
++                  <formats>
++                    <format>xml</format>
++                  </formats>
++                </configuration>
++              </execution>
++            </executions>
++          </plugin>
++        </plugins>
++      </build>
++    </profile>
++    <profile>
++      <id>jacoco</id>
++      <build>
++        <plugins>
++          <plugin>
++            <groupId>org.jacoco</groupId>
++            <artifactId>jacoco-maven-plugin</artifactId>
++            <configuration>
++              <excludes combine.children="append">
++                <!-- Duplicates on classpath cause an exception in JaCoCo report -->
++                <exclude>**/org/apache/uima/examples/SourceDocumentInformation*</exclude>
++                <exclude>**/org/apache/uima/examples/SourceDocumentInformation_Type*</exclude>
++              </excludes>
++            </configuration>
++            <executions>
++              <execution>
++                <id>default-prepare-agent</id>
++                <goals>
++                  <goal>prepare-agent</goal>
++                </goals>
++                <configuration>
++                  <propertyName>jacoco.argLine</propertyName>
++                </configuration>
++              </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 />
++                </configuration>
++              </execution>
++            </executions>
++          </plugin>
++        </plugins>
++      </build>
++    </profile>
++    
++    <!-- **********  Backwards compatibility report generation profile ************** -->
++    <profile>
++      <id>enforce-compatibility</id>
++      <activation>
++        <file>
++          <exists>marker-file-identifying-api-compatibility-check</exists>
++        </file>
++      </activation>
++      <build>
++
++        <pluginManagement>
++          <plugins>
++            <plugin>
++	            <groupId>org.apache.rat</groupId>
++		          <artifactId>apache-rat-plugin</artifactId>
++		          <executions>
++		            <execution>
++		              <id>default-cli</id>
++		              <configuration>
++		                <excludes combine.children="append">
++	                    <exclude>**/api-change-report/**/*.*</exclude>
++		                </excludes>
++		              </configuration>
++		            </execution>
++	          </executions>
++	          </plugin>
++          </plugins>
++        </pluginManagement>
++         
++        <plugins>
++          <!-- https://siom79.github.io/japicmp/MavenPlugin.html -->
++          <plugin>              
++            <groupId>com.github.siom79.japicmp</groupId>
++            <artifactId>japicmp-maven-plugin</artifactId>
++            <version>0.13.0</version>
++            <configuration>
++              <oldVersion>
++                <dependency>
++                  <groupId>${project.groupId}</groupId>
++                  <artifactId>${project.artifactId}</artifactId>
++                  <version>${api_check_oldVersion}</version>
++                </dependency>
++              </oldVersion> 
++              <parameter>
++                <onlyModified>true</onlyModified>
++                <!-- filter out classes with impl in their package or class name -->
++                <postAnalysisScript>${project.basedir}/../uimaj-parent/src/main/groovy/api-report.groovy</postAnalysisScript>                  
++              </parameter>
++            </configuration>
++            <executions>
++              <execution>
++                <phase>verify</phase>
++                <goals>
++                  <goal>cmp</goal>
++                </goals>
++              </execution>
++            </executions>
++          </plugin>
++          
++          <!-- This copy is to have the api change report included in the source distribution -->
++          <plugin>
++            <artifactId>maven-antrun-plugin</artifactId>
++            <executions>
++              <execution>
++                <id>copy-API-change-report</id>
++                <phase>install</phase>  <!-- must follow verify -->
++                <goals><goal>run</goal></goals>
++                <configuration>
++                  <target>
++                    <taskdef name="if" classname="net.sf.antcontrib.logic.IfTask" />
++                    <if>
++                      <available file="${project.build.directory}/japicmp/" />
++                      <then>
++                        <copy toDir="${basedir}/api-change-report">
++                          <fileset dir="${project.build.directory}/japicmp" />
++                        </copy>
++                      </then>
++                    </if>
++                  </target>
++                </configuration>
++              </execution>
++            </executions>
++            
++          </plugin>
++        </plugins>
++      </build>
++    </profile>
++    
++    <!-- ************** m2e  profile ************* -->
++    <profile>
++      <id>m2e</id>
++      <activation>
++        <property>
++          <name>m2e.version</name>
++        </property>
++      </activation>
++      <build>
++        <pluginManagement>
++          <plugins>         
++            <!-- This plugin's configuration is used to store Eclipse m2e settings 
++                only. It has no influence on the Maven build itself. -->
++            <plugin>
++              <groupId>org.eclipse.m2e</groupId>
++              <artifactId>lifecycle-mapping</artifactId>
++              <version>1.0.0</version>
++              <configuration>
++                <lifecycleMappingMetadata>
++                  <pluginExecutions>
++                  
++                    <!-- ***************************** -->
++                    <!-- IGNORE maven-bundle-plugin    -->
++                    <!-- ***************************** -->
++                    <pluginExecution>
++                      <pluginExecutionFilter>
++                        <groupId>org.apache.felix</groupId>
++                        <artifactId>
++                          maven-bundle-plugin
++                        </artifactId>
++                        <versionRange>[3,)</versionRange>
++                        <goals>
++                          <goal>process</goal>
++                          <goal>bundle</goal>
++                          <goal>manifest</goal>
++                        </goals>
++                      </pluginExecutionFilter>
++                      <action>
++                        <ignore />
++                      </action>
++                    </pluginExecution>
++                  </pluginExecutions>
++                </lifecycleMappingMetadata>
++              </configuration>
++            </plugin>
++          </plugins>
++        </pluginManagement>
++      </build>
++    </profile>  
++  </profiles>
+ </project>