jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From thom...@apache.org
Subject svn commit: r701154 - /jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/data/db/DbDataStore.java
Date Thu, 02 Oct 2008 15:27:26 GMT
Author: thomasm
Date: Thu Oct  2 08:27:26 2008
New Revision: 701154

URL: http://svn.apache.org/viewvc?rev=701154&view=rev
Log:
JCR-1572 DbDataStore connection does not always reconnect

Modified:
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/data/db/DbDataStore.java

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/data/db/DbDataStore.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/data/db/DbDataStore.java?rev=701154&r1=701153&r2=701154&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/data/db/DbDataStore.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/data/db/DbDataStore.java
Thu Oct  2 08:27:26 2008
@@ -285,7 +285,6 @@
         TempFileInputStream fileInput = null;
         ConnectionRecoveryManager conn = getConnection();
         try {
-            conn.setAutoReconnect(false);
             String id = null, tempId = null;
             long now;
             for (int i = 0; i < ConnectionRecoveryManager.TRIALS; i++) {
@@ -326,6 +325,7 @@
             } else {
                 throw new DataStoreException("Unsupported stream store algorithm: " + storeStream);
             }
+            // UPDATE DATASTORE SET DATA=? WHERE ID=?
             conn.executeStmt(updateDataSQL, new Object[]{wrapper, tempId});
             now = System.currentTimeMillis();
             long length = in.getPosition();
@@ -362,7 +362,6 @@
             }
             usesIdentifier(identifier);
             DbDataRecord record = new DbDataRecord(this, identifier, length, now);
-            conn.setAutoReconnect(true);
             return record;
         } catch (Exception e) {
             throw convert("Can not insert new record", e);



Mime
View raw message