jackrabbit-oak-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ste...@apache.org
Subject svn commit: r1374228 - /jackrabbit/oak/trunk/oak-mk/src/main/java/org/apache/jackrabbit/mk/core/MicroKernelImpl.java
Date Fri, 17 Aug 2012 12:47:08 GMT
Author: stefan
Date: Fri Aug 17 12:47:07 2012
New Revision: 1374228

URL: http://svn.apache.org/viewvc?rev=1374228&view=rev
Log:
OAK-254: waitForCommit returns null in certain situations

Modified:
    jackrabbit/oak/trunk/oak-mk/src/main/java/org/apache/jackrabbit/mk/core/MicroKernelImpl.java

Modified: jackrabbit/oak/trunk/oak-mk/src/main/java/org/apache/jackrabbit/mk/core/MicroKernelImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-mk/src/main/java/org/apache/jackrabbit/mk/core/MicroKernelImpl.java?rev=1374228&r1=1374227&r2=1374228&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-mk/src/main/java/org/apache/jackrabbit/mk/core/MicroKernelImpl.java
(original)
+++ jackrabbit/oak/trunk/oak-mk/src/main/java/org/apache/jackrabbit/mk/core/MicroKernelImpl.java
Fri Aug 17 12:47:07 2012
@@ -67,12 +67,20 @@ public class MicroKernelImpl implements 
      */
     public MicroKernelImpl(Repository rep) {
         this.rep = rep;
+        try {
+            // initialize commit gate with current head
+            gate.commit(rep.getHeadRevision().toString());
+        } catch (Exception e) {
+            throw new MicroKernelException(e);
+        }
     }
 
     protected void init(String homeDir) throws MicroKernelException {
         try {
             rep = new Repository(homeDir);
             rep.init();
+            // initialize commit gate with current head
+            gate.commit(rep.getHeadRevision().toString());
         } catch (Exception e) {
             throw new MicroKernelException(e);
         }



Mime
View raw message