You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ctakes.apache.org by se...@apache.org on 2017/09/26 21:17:19 UTC

svn commit: r1809787 - in /ctakes/trunk: ctakes-core/src/main/java/org/apache/ctakes/core/pipeline/PiperFileReader.java pom.xml

Author: seanfinan
Date: Tue Sep 26 21:17:19 2017
New Revision: 1809787

URL: http://svn.apache.org/viewvc?rev=1809787&view=rev
Log:
Check for piper files without .piper specified in the name

Modified:
    ctakes/trunk/ctakes-core/src/main/java/org/apache/ctakes/core/pipeline/PiperFileReader.java
    ctakes/trunk/pom.xml

Modified: ctakes/trunk/ctakes-core/src/main/java/org/apache/ctakes/core/pipeline/PiperFileReader.java
URL: http://svn.apache.org/viewvc/ctakes/trunk/ctakes-core/src/main/java/org/apache/ctakes/core/pipeline/PiperFileReader.java?rev=1809787&r1=1809786&r2=1809787&view=diff
==============================================================================
--- ctakes/trunk/ctakes-core/src/main/java/org/apache/ctakes/core/pipeline/PiperFileReader.java (original)
+++ ctakes/trunk/ctakes-core/src/main/java/org/apache/ctakes/core/pipeline/PiperFileReader.java Tue Sep 26 21:17:19 2017
@@ -349,12 +349,14 @@ final public class PiperFileReader {
       if ( piperFile.isAbsolute() ) {
          parentPath = piperFile.getParent();
       } else {
-         try {
-            final File located = FileLocator.getFile( filePath );
+//         try {
+         final File located = FileLocator.getFileQuiet( filePath );
+         if ( located != null ) {
             parentPath = located.getParent();
-         } catch ( FileNotFoundException fnfE ) {
-            // do nothing
          }
+//         } catch ( FileNotFoundException fnfE ) {
+            // do nothing
+//         }
       }
       if ( parentPath != null && !parentPath.isEmpty() && !_userPackages.contains( parentPath ) ) {
          _userPackages.add( parentPath );
@@ -385,6 +387,9 @@ final public class PiperFileReader {
             return stream;
          }
       }
+      if ( !filePath.toLowerCase().endsWith( ".piper" ) ) {
+         return getPiperStream( filePath + ".piper" );
+      }
       LOGGER.error( "No piper file found for " + filePath );
       return null;
    }

Modified: ctakes/trunk/pom.xml
URL: http://svn.apache.org/viewvc/ctakes/trunk/pom.xml?rev=1809787&r1=1809786&r2=1809787&view=diff
==============================================================================
--- ctakes/trunk/pom.xml (original)
+++ ctakes/trunk/pom.xml Tue Sep 26 21:17:19 2017
@@ -140,6 +140,7 @@
 		<module>ctakes-ytex-web</module>
 		<module>ctakes-dictionary-lookup-fast</module>
 		<module>ctakes-dictionary-lookup-fast-res</module>
+        <module>ctakes-scaleout</module>
 	</modules>
 	<dependencyManagement>
 		<dependencies>
@@ -667,9 +668,16 @@
 				<groupId>org.apache.ctakes</groupId>
 				<artifactId>
 					ctakes-distribution
-				</artifactId>
-				<version>${ctakes.version}</version>
-			</dependency>
+                </artifactId>
+                <version>${ctakes.version}</version>
+            </dependency>
+            <dependency>
+                <groupId>org.apache.ctakes</groupId>
+                <artifactId>
+                    ctakes-scaleout
+                </artifactId>
+                <version>${ctakes.version}</version>
+            </dependency>
 		</dependencies>
 	</dependencyManagement>
 	<build>