jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From thom...@apache.org
Subject svn commit: r1033969 - /jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryImpl.java
Date Thu, 11 Nov 2010 15:45:52 GMT
Author: thomasm
Date: Thu Nov 11 15:45:51 2010
New Revision: 1033969

URL: http://svn.apache.org/viewvc?rev=1033969&view=rev
Log:
JCR-2811 Allow to override LockManager creation

Modified:
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryImpl.java

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryImpl.java?rev=1033969&r1=1033968&r2=1033969&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryImpl.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryImpl.java
Thu Nov 11 15:45:51 2010
@@ -1879,8 +1879,7 @@ public class RepositoryImpl extends Abst
                 // lock manager is lazily instantiated in order to avoid
                 // 'chicken & egg' bootstrap problems
                 if (lockMgr == null) {
-                    lockMgr =
-                        new LockManagerImpl(getSystemSession(), fs, executor);
+                    lockMgr = createLockManager();
                     ClusterNode clusterNode = context.getClusterNode();
                     if (clusterNode != null && config.isClustered()) {
                         lockChannel = clusterNode.createLockChannel(getName());
@@ -1892,6 +1891,16 @@ public class RepositoryImpl extends Abst
         }
 
         /**
+         * Create a new lock manager. This method is only called once within
+         * getLockManager().
+         *
+         * @return the lock manager
+         */
+        protected LockManagerImpl createLockManager() throws RepositoryException {
+            return new LockManagerImpl(getSystemSession(), fs, executor);
+        }
+
+        /**
          * Return manager used for evaluating effect retention and holds.
          *
          * @return



Mime
View raw message