directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r530994 - in /directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis: operation/OperationFactory.java service/ReplicationService.java service/protocol/handler/ReplicationClientContextHandler.java
Date Sat, 21 Apr 2007 08:19:34 GMT
Author: elecharny
Date: Sat Apr 21 01:19:34 2007
New Revision: 530994

URL: http://svn.apache.org/viewvc?view=rev&rev=530994
Log:
Modified the search() operation to use SearchOperationContext.

Modified:
    directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/operation/OperationFactory.java
    directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/ReplicationService.java
    directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientContextHandler.java

Modified: directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/operation/OperationFactory.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/operation/OperationFactory.java?view=diff&rev=530994&r1=530993&r2=530994
==============================================================================
--- directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/operation/OperationFactory.java
(original)
+++ directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/operation/OperationFactory.java
Sat Apr 21 01:19:34 2007
@@ -37,6 +37,7 @@
 import org.apache.directory.server.core.interceptor.context.LookupOperationContext;
 import org.apache.directory.server.core.interceptor.context.ModifyOperationContext;
 import org.apache.directory.server.core.interceptor.context.OperationContext;
+import org.apache.directory.server.core.interceptor.context.SearchOperationContext;
 import org.apache.directory.server.core.partition.PartitionNexus;
 import org.apache.directory.shared.ldap.constants.SchemaConstants;
 import org.apache.directory.shared.ldap.filter.PresenceNode;
@@ -254,7 +255,8 @@
         // Retrieve all subtree including the base entry
         SearchControls ctrl = new SearchControls();
         ctrl.setSearchScope( SearchControls.SUBTREE_SCOPE );
-        NamingEnumeration e = nexus.search( oldName, environment, new PresenceNode( SchemaConstants.OBJECT_CLASS_AT_OID
), ctrl );
+        NamingEnumeration e = nexus.search( 
+            new SearchOperationContext( oldName, environment, new PresenceNode( SchemaConstants.OBJECT_CLASS_AT_OID
), ctrl ) );
 
         while ( e.hasMore() )
         {

Modified: directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/ReplicationService.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/ReplicationService.java?view=diff&rev=530994&r1=530993&r2=530994
==============================================================================
--- directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/ReplicationService.java
(original)
+++ directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/ReplicationService.java
Sat Apr 21 01:19:34 2007
@@ -61,6 +61,7 @@
 import org.apache.directory.server.core.interceptor.context.GetMatchedNameOperationContext;
 import org.apache.directory.server.core.interceptor.context.LookupOperationContext;
 import org.apache.directory.server.core.interceptor.context.OperationContext;
+import org.apache.directory.server.core.interceptor.context.SearchOperationContext;
 import org.apache.directory.server.core.invocation.InvocationStack;
 import org.apache.directory.server.core.partition.PartitionNexus;
 import org.apache.directory.server.schema.registries.AttributeTypeRegistry;
@@ -332,7 +333,8 @@
         ctrl.setSearchScope( SearchControls.SUBTREE_SCOPE );
         ctrl.setReturningAttributes( new String[] { "entryCSN", "entryDeleted" } );
 
-        NamingEnumeration e = nexus.search( contextName, directoryServiceConfiguration.getEnvironment(),
filter, ctrl );
+        NamingEnumeration e = nexus.search( 
+            new SearchOperationContext( contextName, directoryServiceConfiguration.getEnvironment(),
filter, ctrl ) );
 
         List<LdapDN> names = new ArrayList<LdapDN>();
         try
@@ -479,9 +481,10 @@
     {
         DirContext ctx = ( DirContext ) InvocationStack.getInstance().peek().getCaller();
         NamingEnumeration e = nextInterceptor.search(
+            new SearchOperationContext( 
                 baseName, ctx.getEnvironment(),
                 new PresenceNode( SchemaConstants.OBJECT_CLASS_AT_OID ),
-                new SearchControls() );
+                new SearchControls() ) );
 
         return new SearchResultFilteringEnumeration( e, new SearchControls(), InvocationStack.getInstance().peek(),
             Constants.DELETED_ENTRIES_FILTER );
@@ -500,7 +503,8 @@
             searchControls.setReturningAttributes( newAttrIds );
         }
         
-        NamingEnumeration e = nextInterceptor.search( baseName, environment, filter, searchControls
);
+        NamingEnumeration e = nextInterceptor.search( 
+            new SearchOperationContext( baseName, environment, filter, searchControls ) );
         return new SearchResultFilteringEnumeration( e, searchControls, InvocationStack.getInstance().peek(),
             Constants.DELETED_ENTRIES_FILTER );
     }

Modified: directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientContextHandler.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientContextHandler.java?view=diff&rev=530994&r1=530993&r2=530994
==============================================================================
--- directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientContextHandler.java
(original)
+++ directory/apacheds/trunk/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientContextHandler.java
Sat Apr 21 01:19:34 2007
@@ -53,6 +53,7 @@
 import org.apache.directory.mitosis.service.protocol.message.LoginMessage;
 import org.apache.directory.mitosis.store.ReplicationLogIterator;
 import org.apache.directory.mitosis.store.ReplicationStore;
+import org.apache.directory.server.core.interceptor.context.SearchOperationContext;
 import org.apache.directory.shared.ldap.constants.SchemaConstants;
 import org.apache.directory.shared.ldap.filter.PresenceNode;
 import org.apache.directory.shared.ldap.name.LdapDN;
@@ -352,9 +353,10 @@
         // Retrieve all subtree including the base entry
         SearchControls ctrl = new SearchControls();
         ctrl.setSearchScope( SearchControls.SUBTREE_SCOPE );
-        NamingEnumeration e = ctx.getServiceConfiguration().getPartitionNexus().search( contextName,
+        NamingEnumeration e = ctx.getServiceConfiguration().getPartitionNexus().search( 
+            new SearchOperationContext( contextName,
             ctx.getServiceConfiguration().getEnvironment(),
-            new PresenceNode( SchemaConstants.OBJECT_CLASS_AT_OID ), ctrl );
+            new PresenceNode( SchemaConstants.OBJECT_CLASS_AT_OID ), ctrl ) );
 
         try
         {



Mime
View raw message