ctakes-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From seanfi...@apache.org
Subject svn commit: r1653361 - /ctakes/trunk/ctakes-dictionary-lookup-fast/src/main/java/org/apache/ctakes/dictionary/lookup2/util/JdbcConnectionFactory.java
Date Tue, 20 Jan 2015 20:30:08 GMT
Author: seanfinan
Date: Tue Jan 20 20:30:08 2015
New Revision: 1653361

URL: http://svn.apache.org/r1653361
Log:
CTAKES-345 enhancement to use $CTAKES_HOME in finding dictionary database when cwd is not
associated with the ctakes installation

Modified:
    ctakes/trunk/ctakes-dictionary-lookup-fast/src/main/java/org/apache/ctakes/dictionary/lookup2/util/JdbcConnectionFactory.java

Modified: ctakes/trunk/ctakes-dictionary-lookup-fast/src/main/java/org/apache/ctakes/dictionary/lookup2/util/JdbcConnectionFactory.java
URL: http://svn.apache.org/viewvc/ctakes/trunk/ctakes-dictionary-lookup-fast/src/main/java/org/apache/ctakes/dictionary/lookup2/util/JdbcConnectionFactory.java?rev=1653361&r1=1653360&r2=1653361&view=diff
==============================================================================
--- ctakes/trunk/ctakes-dictionary-lookup-fast/src/main/java/org/apache/ctakes/dictionary/lookup2/util/JdbcConnectionFactory.java
(original)
+++ ctakes/trunk/ctakes-dictionary-lookup-fast/src/main/java/org/apache/ctakes/dictionary/lookup2/util/JdbcConnectionFactory.java
Tue Jan 20 20:30:08 2015
@@ -57,6 +57,9 @@ public enum JdbcConnectionFactory {
       if ( jdbcUrl.startsWith( HSQL_FILE_PREFIX ) ) {
          // Hack for hsqldb file needing to be absolute or relative to current working directory
          trueJdbcUrl = getConnectionUrl( jdbcUrl );
+         if ( trueJdbcUrl.endsWith( HSQL_DB_EXT ) ) {
+            trueJdbcUrl = trueJdbcUrl.substring( 0, trueJdbcUrl.length() - HSQL_DB_EXT.length()
);
+         }
       }
       try {
          // DO NOT use try with resources here.



Mime
View raw message