directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kayyag...@apache.org
Subject svn commit: r990904 - in /directory/apacheds/trunk: core-api/src/main/java/org/apache/directory/server/core/ core-api/src/test/java/org/apache/directory/server/core/ core/src/main/java/org/apache/directory/server/core/
Date Mon, 30 Aug 2010 19:14:54 GMT
Author: kayyagari
Date: Mon Aug 30 19:14:54 2010
New Revision: 990904

URL: http://svn.apache.org/viewvc?rev=990904&view=rev
Log:
o added methods to access cache service from directory service

Modified:
    directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/DirectoryService.java
    directory/apacheds/trunk/core-api/src/test/java/org/apache/directory/server/core/MockDirectoryService.java
    directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java

Modified: directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/DirectoryService.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/DirectoryService.java?rev=990904&r1=990903&r2=990904&view=diff
==============================================================================
--- directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/DirectoryService.java
(original)
+++ directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/DirectoryService.java
Mon Aug 30 19:14:54 2010
@@ -517,4 +517,9 @@ public interface DirectoryService extend
      * @return the syncPeriodMillis
      */
     long getSyncPeriodMillis();
+    
+    /**
+     * @return the cache service
+     */
+    CacheService getCacheService();
 }

Modified: directory/apacheds/trunk/core-api/src/test/java/org/apache/directory/server/core/MockDirectoryService.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core-api/src/test/java/org/apache/directory/server/core/MockDirectoryService.java?rev=990904&r1=990903&r2=990904&view=diff
==============================================================================
--- directory/apacheds/trunk/core-api/src/test/java/org/apache/directory/server/core/MockDirectoryService.java
(original)
+++ directory/apacheds/trunk/core-api/src/test/java/org/apache/directory/server/core/MockDirectoryService.java
Mon Aug 30 19:14:54 2010
@@ -485,4 +485,11 @@ public class MockDirectoryService implem
         // TODO Auto-generated method stub
         
     }
+
+
+    public CacheService getCacheService()
+    {
+        // TODO Auto-generated method stub
+        return null;
+    }
 }

Modified: directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java?rev=990904&r1=990903&r2=990904&view=diff
==============================================================================
--- directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
(original)
+++ directory/apacheds/trunk/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
Mon Aug 30 19:14:54 2010
@@ -240,6 +240,9 @@ public class DefaultDirectoryService imp
 
     private static final String LOCK_FILE_NAME = ".dirservice.lock";
 
+    /** the ehcache based cache service */
+    private CacheService cacheService;
+
     /**
      * The synchronizer thread. It flush data on disk periodically.
      */
@@ -1010,7 +1013,8 @@ public class DefaultDirectoryService imp
         // And shutdown the server
         // --------------------------------------------------------------------
         interceptorChain.destroy();
-
+        cacheService.destroy();
+        
         if ( lockFile != null )
         {
             try
@@ -1437,7 +1441,10 @@ public class DefaultDirectoryService imp
         // --------------------------------------------------------------------
 
         firstStart = createBootstrapEntries();
-
+        
+        cacheService = new CacheService();
+        cacheService.initialize( this );
+        
         interceptorChain = new InterceptorChain();
         interceptorChain.init( this );
 
@@ -1767,4 +1774,13 @@ public class DefaultDirectoryService imp
         }
 
     }
+
+    /**
+     * {@inheritDoc}
+     */
+    public CacheService getCacheService()
+    {
+        return cacheService;
+    }
+
 }



Mime
View raw message