jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From thom...@apache.org
Subject svn commit: r820917 - in /jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core: RepositoryFactoryImpl.java RepositoryManagerImpl.java SessionImpl.java data/GarbageCollector.java
Date Fri, 02 Oct 2009 07:33:35 GMT
Author: thomasm
Date: Fri Oct  2 07:33:35 2009
New Revision: 820917

URL: http://svn.apache.org/viewvc?rev=820917&view=rev
Log:
JCR-1865 Add the Data Store to the Jackrabbit API

Modified:
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryFactoryImpl.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryManagerImpl.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/SessionImpl.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/data/GarbageCollector.java

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryFactoryImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryFactoryImpl.java?rev=820917&r1=820916&r2=820917&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryFactoryImpl.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryFactoryImpl.java
Fri Oct  2 07:33:35 2009
@@ -106,7 +106,7 @@
     }
 
     public RepositoryManager getRepositoryManager(JackrabbitRepository repo) throws RepositoryException
{
-        if (repo instanceof TransientRepository) {
+        if (!(repo instanceof TransientRepository)) {
             throw new RepositoryException("The repository was not created in this factory");
         }
         if (!ownRepositories.contains(repo)) {

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryManagerImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryManagerImpl.java?rev=820917&r1=820916&r2=820917&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryManagerImpl.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryManagerImpl.java
Fri Oct  2 07:33:35 2009
@@ -75,7 +75,7 @@
             }
             ipmList[i] = (IterablePersistenceManager) pm;
         }
-        GarbageCollector gc = new GarbageCollector(null, ipmList, sessions);
+        GarbageCollector gc = new GarbageCollector(rep, null, ipmList, sessions);
         return gc;
     }
 

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/SessionImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/SessionImpl.java?rev=820917&r1=820916&r2=820917&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/SessionImpl.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/SessionImpl.java
Fri Oct  2 07:33:35 2009
@@ -688,7 +688,7 @@
             }
             ipmList[i] = (IterablePersistenceManager) pm;
         }
-        GarbageCollector gc = new GarbageCollector(this, ipmList, sessions);
+        GarbageCollector gc = new GarbageCollector(rep, this, ipmList, sessions);
         return gc;
     }
 
@@ -1542,7 +1542,7 @@
     }
 
     /**
-     * @see javax.jcr.Session#hasCapability(String, Object, Object[]) 
+     * @see javax.jcr.Session#hasCapability(String, Object, Object[])
      * @since JCR 2.0
      */
     public boolean hasCapability(String methodName, Object target, Object[] arguments)

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/data/GarbageCollector.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/data/GarbageCollector.java?rev=820917&r1=820916&r2=820917&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/data/GarbageCollector.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/data/GarbageCollector.java
Fri Oct  2 07:33:35 2009
@@ -107,12 +107,12 @@
      * This method is usually not called by the application, it is called
      * by SessionImpl.createDataStoreGarbageCollector().
      *
-     * @param session the session that created this object
+     * @param rep the repository
+     * @param session the session that created this object (optional)
      * @param list the persistence managers
      * @param sessionList the sessions to access the workspaces
      */
-    public GarbageCollector(SessionImpl session, IterablePersistenceManager[] list, Session[]
sessionList) {
-        RepositoryImpl rep = (RepositoryImpl) session.getRepository();
+    public GarbageCollector(RepositoryImpl rep, SessionImpl session, IterablePersistenceManager[]
list, Session[] sessionList) {
         store = rep.getDataStore();
         this.pmList = list;
         this.persistenceManagerScan = list != null;



Mime
View raw message