db-torque-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tfisc...@apache.org
Subject svn commit: r1398216 - in /db/torque/torque4/trunk: torque-runtime/src/main/java/org/apache/torque/util/ExceptionMapperImpl.java torque-test/src/test/profile/oracle/Torque.properties
Date Mon, 15 Oct 2012 08:48:15 GMT
Author: tfischer
Date: Mon Oct 15 08:48:15 2012
New Revision: 1398216

URL: http://svn.apache.org/viewvc?rev=1398216&view=rev
Log:
TORQUE-233 exception translation for Oracle

Modified:
    db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/ExceptionMapperImpl.java
    db/torque/torque4/trunk/torque-test/src/test/profile/oracle/Torque.properties

Modified: db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/ExceptionMapperImpl.java
URL: http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/ExceptionMapperImpl.java?rev=1398216&r1=1398215&r2=1398216&view=diff
==============================================================================
--- db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/ExceptionMapperImpl.java
(original)
+++ db/torque/torque4/trunk/torque-runtime/src/main/java/org/apache/torque/util/ExceptionMapperImpl.java
Mon Oct 15 08:48:15 2012
@@ -50,6 +50,12 @@ public class ExceptionMapperImpl extends
             // postgresql
             return new DeadlockException(sqlException);
         }
+        if (StringUtils.equals(sqlException.getSQLState(), "61000")
+                && sqlException.getErrorCode() == 60)
+        {
+            // oracle
+            return new DeadlockException(sqlException);
+        }
         return new TorqueException(sqlException);
     }
 }

Modified: db/torque/torque4/trunk/torque-test/src/test/profile/oracle/Torque.properties
URL: http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-test/src/test/profile/oracle/Torque.properties?rev=1398216&r1=1398215&r2=1398216&view=diff
==============================================================================
--- db/torque/torque4/trunk/torque-test/src/test/profile/oracle/Torque.properties (original)
+++ db/torque/torque4/trunk/torque-test/src/test/profile/oracle/Torque.properties Mon Oct
15 08:48:15 2012
@@ -33,7 +33,7 @@ torque.dsfactory.bookstore.connection.pa
 
 torque.dsfactory.bookstore.pool.validationQuery = SELECT 1 FROM DUAL
 torque.dsfactory.bookstore.pool.maxWait = 5000
-torque.dsfactory.bookstore.pool.maxWait = 5000
+torque.dsfactory.bookstore.pool.defaultAutoCommit = false
 
 # use Caching. This property is only used if managers are used by generators.
 torque.manager.useCache = true
\ No newline at end of file



---------------------------------------------------------------------
To unsubscribe, e-mail: torque-dev-unsubscribe@db.apache.org
For additional commands, e-mail: torque-dev-help@db.apache.org


Mime
View raw message