db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From oyste...@apache.org
Subject svn commit: r633807 - /db/derby/code/trunk/java/engine/org/apache/derby/impl/services/replication/master/MasterController.java
Date Wed, 05 Mar 2008 10:16:38 GMT
Author: oysteing
Date: Wed Mar  5 02:16:37 2008
New Revision: 633807

URL: http://svn.apache.org/viewvc?rev=633807&view=rev
Log:
DERBY-3492: Adds missing append of the log chunk to the replication log buffer after forcing
a log shipment to the slave.
Contributed by Jorgen Loland

Modified:
    db/derby/code/trunk/java/engine/org/apache/derby/impl/services/replication/master/MasterController.java

Modified: db/derby/code/trunk/java/engine/org/apache/derby/impl/services/replication/master/MasterController.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/engine/org/apache/derby/impl/services/replication/master/MasterController.java?rev=633807&r1=633806&r2=633807&view=diff
==============================================================================
--- db/derby/code/trunk/java/engine/org/apache/derby/impl/services/replication/master/MasterController.java
(original)
+++ db/derby/code/trunk/java/engine/org/apache/derby/impl/services/replication/master/MasterController.java
Wed Mar  5 02:16:37 2008
@@ -320,7 +320,8 @@
     }
     
     /**
-     * Append a chunk of log records to the log buffer.
+     * Append a chunk of log records to the log buffer. The method is not 
+     * threadsafe; only one thread should access this method at a time. 
      *
      * @param greatestInstant   the instant of the log record that was
      *                          added last to this chunk of log
@@ -337,6 +338,8 @@
         } catch (LogBufferFullException lbfe) {
             try {
                 logShipper.forceFlush();
+                // There should now be room for this log chunk in the buffer
+                appendLog(greatestInstant, log, logOffset, logLength);
             } catch (IOException ioe) {
                 printStackAndStopMaster(ioe);
             } catch (StandardException se) {



Mime
View raw message