directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r607412 [2/4] - in /directory: apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/ apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/authn/ apacheds/branches/bigbang/core/src/main/java/...
Date Sat, 29 Dec 2007 11:42:44 GMT
Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/event/EventInterceptor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/event/EventInterceptor.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/event/EventInterceptor.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/event/EventInterceptor.java Sat Dec 29 03:42:29 2007
@@ -48,6 +48,7 @@
 import org.apache.directory.server.schema.ConcreteNameComponentNormalizer;
 import org.apache.directory.server.schema.registries.AttributeTypeRegistry;
 import org.apache.directory.server.schema.registries.OidRegistry;
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.filter.AndNode;
 import org.apache.directory.shared.ldap.filter.BranchNode;
 import org.apache.directory.shared.ldap.filter.ExprNode;
@@ -276,7 +277,7 @@
     public void delete( NextInterceptor next, DeleteOperationContext opContext ) throws NamingException
     {
     	LdapDN name = opContext.getDn();
-        Attributes entry = nexus.lookup( new LookupOperationContext( name ) );
+        Attributes entry = nexus.lookup( new LookupOperationContext( opContext.getRegistries(), name ) );
 
         next.delete( opContext );
         //super.delete( next, opContext );
@@ -306,9 +307,9 @@
     }
 
 
-    private void notifyOnModify( LdapDN name, List<ModificationItemImpl> mods, Attributes oriEntry ) throws NamingException
+    private void notifyOnModify( Registries registries, LdapDN name, List<ModificationItemImpl> mods, Attributes oriEntry ) throws NamingException
     {
-        Attributes entry = nexus.lookup( new LookupOperationContext( name ) );
+        Attributes entry = nexus.lookup( new LookupOperationContext( registries, name ) );
         Set<EventSourceRecord> selecting = getSelectingSources( name, entry );
         
         if ( selecting.isEmpty() )
@@ -339,17 +340,17 @@
     {
         Invocation invocation = InvocationStack.getInstance().peek();
         PartitionNexusProxy proxy = invocation.getProxy();
-        Attributes oriEntry = proxy.lookup( new LookupOperationContext( opContext.getDn() ), PartitionNexusProxy.LOOKUP_BYPASS );
+        Attributes oriEntry = proxy.lookup( new LookupOperationContext( opContext.getRegistries(), opContext.getDn() ), PartitionNexusProxy.LOOKUP_BYPASS );
         
         next.modify( opContext );
 
-        notifyOnModify( opContext.getDn(), opContext.getModItems(), oriEntry );
+        notifyOnModify( opContext.getRegistries(), opContext.getDn(), opContext.getModItems(), oriEntry );
     }
 
 
-    private void notifyOnNameChange( LdapDN oldName, LdapDN newName ) throws NamingException
+    private void notifyOnNameChange( Registries registries, LdapDN oldName, LdapDN newName ) throws NamingException
     {
-        Attributes entry = nexus.lookup( new LookupOperationContext( newName ) );
+        Attributes entry = nexus.lookup( new LookupOperationContext( registries, newName ) );
         Set<EventSourceRecord> selecting = getSelectingSources( oldName, entry );
         
         if ( selecting.isEmpty() )
@@ -385,7 +386,7 @@
         newName.remove( newName.size() - 1 );
         newName.add( opContext.getNewRdn() );
         newName.normalize( attributeRegistry.getNormalizerMapping() );
-        notifyOnNameChange( opContext.getDn(), newName );
+        notifyOnNameChange( opContext.getRegistries(), opContext.getDn(), newName );
     }
 
 
@@ -397,7 +398,7 @@
 
         LdapDN newName = ( LdapDN ) opContext.getParent().clone();
         newName.add( opContext.getNewRdn() );
-        notifyOnNameChange( opContext.getDn(), newName );
+        notifyOnNameChange( opContext.getRegistries(), opContext.getDn(), newName );
     }
 
 
@@ -410,7 +411,7 @@
         
         LdapDN newName = ( LdapDN ) opContext.getParent().clone();
         newName.add( oriChildName.get( oriChildName.size() - 1 ) );
-        notifyOnNameChange( oriChildName, newName );
+        notifyOnNameChange( opContext.getRegistries(), oriChildName, newName );
     }
 
 

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/exception/ExceptionInterceptor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/exception/ExceptionInterceptor.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/exception/ExceptionInterceptor.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/exception/ExceptionInterceptor.java Sat Dec 29 03:42:29 2007
@@ -39,6 +39,7 @@
 import org.apache.directory.server.core.partition.Partition;
 import org.apache.directory.server.core.partition.PartitionNexus;
 import org.apache.directory.server.core.partition.PartitionNexusProxy;
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.constants.SchemaConstants;
 import org.apache.directory.shared.ldap.exception.LdapAttributeInUseException;
 import org.apache.directory.shared.ldap.exception.LdapContextNotEmptyException;
@@ -77,6 +78,9 @@
  */
 public class ExceptionInterceptor extends BaseInterceptor
 {
+    /** The global registries */
+    private Registries registries;
+    
     private PartitionNexus nexus;
     private LdapDN subschemSubentryDn;
     
@@ -124,6 +128,7 @@
         Attribute attr = nexus.getRootDSE( null ).get( SchemaConstants.SUBSCHEMA_SUBENTRY_AT );
         subschemSubentryDn = new LdapDN( ( String ) attr.get() );
         subschemSubentryDn.normalize( normalizerMap );
+        registries = directoryService.getRegistries();
     }
 
 
@@ -147,7 +152,7 @@
         }
         
         // check if the entry already exists
-        if ( nextInterceptor.hasEntry( new EntryOperationContext( name ) ) )
+        if ( nextInterceptor.hasEntry( new EntryOperationContext( registries, name ) ) )
         {
             NamingException ne = new LdapNameAlreadyBoundException( name.getUpName() + " already exists!" );
             ne.setResolvedName( new LdapDN( name.getUpName() ) );
@@ -173,13 +178,13 @@
             
             try
             {
-                attrs = nextInterceptor.lookup( new LookupOperationContext( parentDn ) );
+                attrs = nextInterceptor.lookup( new LookupOperationContext( registries, parentDn ) );
             }
             catch ( Exception e )
             {
                 LdapNameNotFoundException e2 = new LdapNameNotFoundException( "Parent " + parentDn.getUpName() 
                     + " not found" );
-                e2.setResolvedName( new LdapDN( nexus.getMatchedName( new GetMatchedNameOperationContext( parentDn ) ).getUpName() ) );
+                e2.setResolvedName( new LdapDN( nexus.getMatchedName( new GetMatchedNameOperationContext( registries, parentDn ) ).getUpName() ) );
                 throw e2;
             }
             
@@ -228,7 +233,7 @@
 
         // check if entry to delete has children (only leaves can be deleted)
         boolean hasChildren = false;
-        NamingEnumeration<SearchResult> list = nextInterceptor.list( new ListOperationContext( name ) );
+        NamingEnumeration<SearchResult> list = nextInterceptor.list( new ListOperationContext( registries, name ) );
         
         if ( list.hasMore() )
         {
@@ -312,7 +317,7 @@
         
         assertHasEntry( nextInterceptor, msg, opContext.getDn() );
 
-        Attributes entry = nexus.lookup( new LookupOperationContext( opContext.getDn() ) );
+        Attributes entry = nexus.lookup( new LookupOperationContext( registries, opContext.getDn() ) );
         List<ModificationItemImpl> items = opContext.getModItems();
 
         for ( ModificationItemImpl item : items )
@@ -379,7 +384,7 @@
         newDn.add( opContext.getNewRdn() );
         newDn.normalize( normalizerMap );
         
-        if ( nextInterceptor.hasEntry( new EntryOperationContext( newDn ) ) )
+        if ( nextInterceptor.hasEntry( new EntryOperationContext( registries, newDn ) ) )
         {
             LdapNameAlreadyBoundException e;
             e = new LdapNameAlreadyBoundException( "target entry " + newDn.getUpName() + " already exists!" );
@@ -430,7 +435,7 @@
         LdapDN target = ( LdapDN ) newParentName.clone();
         target.add( rdn );
         
-        if ( nextInterceptor.hasEntry( new EntryOperationContext( target ) ) )
+        if ( nextInterceptor.hasEntry( new EntryOperationContext( registries, target ) ) )
         {
             // we must calculate the resolved name using the user provided Rdn value
             String upRdn = new LdapDN( oriChildName.getUpName() ).get( oriChildName.size() - 1 );
@@ -485,7 +490,7 @@
         LdapDN target = ( LdapDN ) parent.clone();
         target.add( opContext.getNewRdn() );
 
-        if ( nextInterceptor.hasEntry( new EntryOperationContext( target ) ) )
+        if ( nextInterceptor.hasEntry( new EntryOperationContext( registries, target ) ) )
         {
             // we must calculate the resolved name using the user provided Rdn value
             LdapDN upTarget = ( LdapDN ) parent.clone();
@@ -560,7 +565,7 @@
         Invocation invocation = InvocationStack.getInstance().peek();
         PartitionNexusProxy proxy = invocation.getProxy();
         
-        if ( !nextInterceptor.hasEntry( new EntryOperationContext( dn ) ) )
+        if ( !nextInterceptor.hasEntry( new EntryOperationContext( registries, dn ) ) )
         {
             LdapNameNotFoundException e;
 
@@ -576,7 +581,7 @@
             e.setResolvedName( 
                 new LdapDN( 
                     proxy.getMatchedName( 
-                        new GetMatchedNameOperationContext( dn ) ).getUpName() ) );
+                        new GetMatchedNameOperationContext( registries, dn ) ).getUpName() ) );
             throw e;
         }
     }

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/AbstractOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/AbstractOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/AbstractOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/AbstractOperationContext.java Sat Dec 29 03:42:29 2007
@@ -42,9 +42,14 @@
 
     /** The DN associated with the context */
     private LdapDN dn;
+    
+    /** The associated request's controls */
     private Map<String, Control> requestControls = new HashMap<String, Control>(4);
+
+    /** The associated response's controls */
     private Map<String, Control> responseControls = new HashMap<String, Control>(4);
 
+    /** A flag to tell that this is a collateral operation */
     private boolean collateralOperation;
     
     /** The global registries reference */
@@ -52,21 +57,9 @@
 
     
     /**
-     * 
      * Creates a new instance of AbstractOperationContext.
      *
-     */
-    public AbstractOperationContext()
-    {
-        this.registries = null;
-    }
-
-
-    /**
-     * 
-     * Creates a new instance of AbstractOperationContext.
-     *
-     * @param atRegistry The AttributeType registry
+     * @param Registries The global registries
      */
     public AbstractOperationContext( Registries registries )
     {
@@ -77,18 +70,7 @@
     /**
      * Creates a new instance of AbstractOperationContext.
      *
-     * @param dn The associated DN
-     */
-    public AbstractOperationContext( LdapDN dn )
-    {
-        this.dn = dn;
-    }
-
-
-    /**
-     * Creates a new instance of AbstractOperationContext.
-     *
-     * @param atRegistry The AttributeType registry
+     * @param Registries The global registries
      * @param dn The associated DN
      */
     public AbstractOperationContext( Registries registries, LdapDN dn )
@@ -101,20 +83,7 @@
     /**
      * Creates a new instance of AbstractOperationContext.
      *
-     * @param dn the associated DN
-     * @param collateralOperation true if op is collateral, false otherwise
-     */
-    public AbstractOperationContext( LdapDN dn, boolean collateralOperation )
-    {
-        this.dn = dn;
-        this.collateralOperation = collateralOperation;
-    }
-
-
-    /**
-     * Creates a new instance of AbstractOperationContext.
-     *
-     * @param atRegistry The AttributeType registry
+     * @param Registries The global registries
      * @param dn the associated DN
      * @param collateralOperation true if op is collateral, false otherwise
      */
@@ -130,19 +99,7 @@
      * Creates an operation context where the operation is considered a side
      * effect of a direct operation.
      *
-     * @param collateralOperation true if this is a side effect operation
-     */
-    public AbstractOperationContext( boolean collateralOperation )
-    {
-        this.collateralOperation = collateralOperation;
-    }
-
-
-    /**
-     * Creates an operation context where the operation is considered a side
-     * effect of a direct operation.
-     *
-     * @param atRegistry The AttributeType registry
+     * @param Registries The global registries
      * @param collateralOperation true if this is a side effect operation
      */
     public AbstractOperationContext( Registries registries, boolean collateralOperation )

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/AddContextPartitionOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/AddContextPartitionOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/AddContextPartitionOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/AddContextPartitionOperationContext.java Sat Dec 29 03:42:29 2007
@@ -21,6 +21,7 @@
 
 
 import org.apache.directory.server.core.partition.Partition;
+import org.apache.directory.server.schema.registries.Registries;
 
 
 /**
@@ -32,7 +33,7 @@
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class AddContextPartitionOperationContext  extends EmptyOperationContext
+public class AddContextPartitionOperationContext extends EmptyOperationContext
 {
     /** the instantiated partition class */
     private Partition partition;
@@ -43,9 +44,9 @@
      *
      * @param partition The partition to add
      */
-    public AddContextPartitionOperationContext( Partition partition )
+    public AddContextPartitionOperationContext( Registries registries, Partition partition )
     {
-        super();
+        super( registries );
         this.partition = partition;
     }
     

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/BindOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/BindOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/BindOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/BindOperationContext.java Sat Dec 29 03:42:29 2007
@@ -21,6 +21,7 @@
 
 import java.util.List;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.util.StringTools;
 
 /**
@@ -40,6 +41,17 @@
     
     /** The SASL identifier */
     private String saslAuthId;
+    
+    /**
+     * Creates a new instance of BindOperationContext.
+     *
+     * @param Registries The global registries
+     */
+    public BindOperationContext( Registries registries )
+    {
+        super( registries );
+    }
+
     
     /**
      * @return The list of supported mechanisms

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/CompareOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/CompareOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/CompareOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/CompareOperationContext.java Sat Dec 29 03:42:29 2007
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.server.core.interceptor.context;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 import org.apache.directory.shared.ldap.util.StringTools;
 
@@ -29,7 +30,7 @@
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class CompareOperationContext  extends AbstractOperationContext
+public class CompareOperationContext extends AbstractOperationContext
 {
     /** The entry OID */
     private String oid;
@@ -37,14 +38,15 @@
     /** The value to be compared */
     private Object value;
     
+    
     /**
      * 
      * Creates a new instance of CompareOperationContext.
      *
      */
-    public CompareOperationContext()
+    public CompareOperationContext( Registries registries )
     {
-    	super();
+    	super( registries );
     }
 
     /**
@@ -52,9 +54,9 @@
      * Creates a new instance of CompareOperationContext.
      *
      */
-    public CompareOperationContext( LdapDN dn )
+    public CompareOperationContext( Registries registries, LdapDN dn )
     {
-        super( dn );
+        super( registries, dn );
     }
 
     /**
@@ -62,9 +64,9 @@
      * Creates a new instance of LookupOperationContext.
      *
      */
-    public CompareOperationContext( String oid )
+    public CompareOperationContext( Registries registries, String oid )
     {
-    	super();
+    	super( registries );
         this.oid = oid;
     }
 
@@ -73,9 +75,9 @@
      * Creates a new instance of LookupOperationContext.
      *
      */
-    public CompareOperationContext( LdapDN dn, String oid )
+    public CompareOperationContext( Registries registries, LdapDN dn, String oid )
     {
-    	super( dn );
+    	super( registries, dn );
         this.oid = oid;
     }
 
@@ -84,9 +86,9 @@
      * Creates a new instance of LookupOperationContext.
      *
      */
-    public CompareOperationContext( LdapDN dn, String oid, Object value )
+    public CompareOperationContext( Registries registries, LdapDN dn, String oid, Object value )
     {
-    	super( dn );
+    	super( registries, dn );
         this.oid = oid;
         this.value = value;
     }

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/DeleteOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/DeleteOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/DeleteOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/DeleteOperationContext.java Sat Dec 29 03:42:29 2007
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.server.core.interceptor.context;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 
 /**
@@ -28,14 +29,14 @@
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class DeleteOperationContext  extends AbstractOperationContext
+public class DeleteOperationContext extends AbstractOperationContext
 {
     /**
      * Creates a new instance of DeleteOperationContext.
      */
-    public DeleteOperationContext()
+    public DeleteOperationContext( Registries registries )
     {
-        super();
+        super( registries );
     }
     
 
@@ -44,9 +45,9 @@
      *
      * @param collateralOperation true if this is a side effect operation
      */
-    public DeleteOperationContext( boolean collateralOperation )
+    public DeleteOperationContext( Registries registries, boolean collateralOperation )
     {
-        super( collateralOperation );
+        super( registries, collateralOperation );
     }
 
 
@@ -55,9 +56,9 @@
      *
      * @param deleteDn The entry DN to delete
      */
-    public DeleteOperationContext( LdapDN deleteDn )
+    public DeleteOperationContext( Registries registries, LdapDN deleteDn )
     {
-        super( deleteDn );
+        super( registries, deleteDn );
     }
 
 
@@ -67,9 +68,9 @@
      * @param deleteDn The entry DN to delete
      * @param collateralOperation true if this is a side effect operation
      */
-    public DeleteOperationContext( LdapDN deleteDn, boolean collateralOperation )
+    public DeleteOperationContext( Registries registries, LdapDN deleteDn, boolean collateralOperation )
     {
-        super( deleteDn, collateralOperation );
+        super( registries, deleteDn, collateralOperation );
     }
 
 

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/EmptyOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/EmptyOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/EmptyOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/EmptyOperationContext.java Sat Dec 29 03:42:29 2007
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.server.core.interceptor.context;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 
 /**
@@ -33,9 +34,9 @@
     /**
      * Creates a new instance of EmptyOperationContext.
      */
-    public EmptyOperationContext()
+    public EmptyOperationContext( Registries registries )
     {
-        super( LdapDN.EMPTY_LDAPDN );
+        super( registries, LdapDN.EMPTY_LDAPDN );
     }
     
 

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/EntryOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/EntryOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/EntryOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/EntryOperationContext.java Sat Dec 29 03:42:29 2007
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.server.core.interceptor.context;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 
 /**
@@ -28,13 +29,14 @@
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class EntryOperationContext  extends AbstractOperationContext
+public class EntryOperationContext extends AbstractOperationContext
 {
     /**
      * Creates a new instance of EntryOperationContext.
      */
-    public EntryOperationContext()
+    public EntryOperationContext( Registries registries )
     {
+        super( registries );
     }
     
     /**
@@ -42,9 +44,9 @@
      *
      * @param entryDn The Entry DN to unbind
      */
-    public EntryOperationContext( LdapDN entryDn )
+    public EntryOperationContext( Registries registries, LdapDN entryDn )
     {
-        super( entryDn );
+        super( registries, entryDn );
     }
     
     /**

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/GetMatchedNameOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/GetMatchedNameOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/GetMatchedNameOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/GetMatchedNameOperationContext.java Sat Dec 29 03:42:29 2007
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.server.core.interceptor.context;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 
 /**
@@ -28,14 +29,14 @@
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class GetMatchedNameOperationContext  extends AbstractOperationContext
+public class GetMatchedNameOperationContext extends AbstractOperationContext
 {
     /**
      * Creates a new instance of GetMatchedNameOperationContext.
      */
-    public GetMatchedNameOperationContext()
+    public GetMatchedNameOperationContext( Registries registries )
     {
-        super();
+        super( registries );
     }
     
     /**
@@ -43,9 +44,9 @@
      *
      * @param dn The DN to match
      */
-    public GetMatchedNameOperationContext( LdapDN dn )
+    public GetMatchedNameOperationContext( Registries registries, LdapDN dn )
     {
-        super( dn );
+        super( registries, dn );
     }
     
     /**

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/GetRootDSEOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/GetRootDSEOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/GetRootDSEOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/GetRootDSEOperationContext.java Sat Dec 29 03:42:29 2007
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.server.core.interceptor.context;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 
 /**
@@ -28,14 +29,14 @@
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class GetRootDSEOperationContext  extends AbstractOperationContext
+public class GetRootDSEOperationContext extends AbstractOperationContext
 {
     /**
      * Creates a new instance of GetRootDSEOperationContext.
      */
-    public GetRootDSEOperationContext()
+    public GetRootDSEOperationContext( Registries registries )
     {
-        super();
+        super( registries );
     }
     
     /**
@@ -43,9 +44,9 @@
      *
      * @param dn The entry DN used to get the rootDSE
      */
-    public GetRootDSEOperationContext( LdapDN dn )
+    public GetRootDSEOperationContext( Registries registries, LdapDN dn )
     {
-        super( dn );
+        super( registries, dn );
     }
     
     /**

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/GetSuffixOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/GetSuffixOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/GetSuffixOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/GetSuffixOperationContext.java Sat Dec 29 03:42:29 2007
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.server.core.interceptor.context;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 
 /**
@@ -28,14 +29,14 @@
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class GetSuffixOperationContext  extends AbstractOperationContext
+public class GetSuffixOperationContext extends AbstractOperationContext
 {
     /**
      * Creates a new instance of GetSuffixOperationContext.
      */
-    public GetSuffixOperationContext()
+    public GetSuffixOperationContext( Registries registries )
     {
-        super();
+        super( registries );
     }
     
     /**
@@ -43,9 +44,9 @@
      *
      * @param dn The DN to get the suffix from
      */
-    public GetSuffixOperationContext( LdapDN dn )
+    public GetSuffixOperationContext( Registries registries, LdapDN dn )
     {
-        super( dn );
+        super( registries, dn );
     }
     
     /**

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/ListOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/ListOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/ListOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/ListOperationContext.java Sat Dec 29 03:42:29 2007
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.server.core.interceptor.context;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 import org.apache.directory.shared.ldap.message.AliasDerefMode;
 
@@ -29,7 +30,7 @@
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class ListOperationContext  extends AbstractOperationContext
+public class ListOperationContext extends AbstractOperationContext
 {
     private AliasDerefMode aliasDerefMode = AliasDerefMode.DEREF_ALWAYS;
 
@@ -37,9 +38,9 @@
     /**
      * Creates a new instance of ListOperationContext.
      */
-    public ListOperationContext()
+    public ListOperationContext( Registries registries )
     {
-        super();
+        super( registries );
     }
 
 
@@ -48,9 +49,9 @@
      *
      * @param dn The DN to get the suffix from
      */
-    public ListOperationContext( LdapDN dn )
+    public ListOperationContext( Registries registries, LdapDN dn )
     {
-        super( dn );
+        super( registries, dn );
     }
 
 
@@ -60,9 +61,9 @@
      * @param dn The DN to get the suffix from
      * @param aliasDerefMode the alias dereferencing mode to use
      */
-    public ListOperationContext( LdapDN dn, AliasDerefMode aliasDerefMode )
+    public ListOperationContext( Registries registries, LdapDN dn, AliasDerefMode aliasDerefMode )
     {
-        super( dn );
+        super( registries, dn );
         this.aliasDerefMode = aliasDerefMode;
     }
 

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/ListSuffixOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/ListSuffixOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/ListSuffixOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/ListSuffixOperationContext.java Sat Dec 29 03:42:29 2007
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.server.core.interceptor.context;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 
 /**
@@ -28,14 +29,14 @@
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class ListSuffixOperationContext  extends AbstractOperationContext
+public class ListSuffixOperationContext extends AbstractOperationContext
 {
     /**
      * Creates a new instance of ListSuffixOperationContext.
      */
-    public ListSuffixOperationContext()
+    public ListSuffixOperationContext( Registries registries )
     {
-        super();
+        super( registries );
     }
     
     /**
@@ -43,9 +44,9 @@
      *
      * @param dn The DN to get the suffix from
      */
-    public ListSuffixOperationContext( LdapDN dn )
+    public ListSuffixOperationContext( Registries registries, LdapDN dn )
     {
-        super( dn );
+        super( registries, dn );
     }
     
     /**

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/LookupOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/LookupOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/LookupOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/LookupOperationContext.java Sat Dec 29 03:42:29 2007
@@ -23,6 +23,7 @@
 import java.util.Arrays;
 import java.util.List;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 import org.apache.directory.shared.ldap.util.StringTools;
 
@@ -33,7 +34,7 @@
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class LookupOperationContext  extends AbstractOperationContext
+public class LookupOperationContext extends AbstractOperationContext
 {
     /** The list of attributes id to return */
     private List<String> attrsId;
@@ -46,9 +47,9 @@
      * Creates a new instance of LookupOperationContext.
      *
      */
-    public LookupOperationContext()
+    public LookupOperationContext( Registries registries )
     {
-    	super();
+    	super( registries );
     }
 
     /**
@@ -56,9 +57,9 @@
      * Creates a new instance of LookupOperationContext.
      *
      */
-    public LookupOperationContext( LdapDN dn )
+    public LookupOperationContext( Registries registries, LdapDN dn )
     {
-        super( dn );
+        super( registries, dn );
     }
 
     /**
@@ -66,9 +67,9 @@
      * Creates a new instance of LookupOperationContext.
      *
      */
-    public LookupOperationContext( String attrsId[] )
+    public LookupOperationContext( Registries registries, String attrsId[] )
     {
-    	super();
+    	super( registries );
         this.attrsId = new ArrayList<String>();
         attrsOid = new ArrayList<String>();
         setAttrsId( attrsId );
@@ -79,9 +80,9 @@
      * Creates a new instance of LookupOperationContext.
      *
      */
-    public LookupOperationContext( LdapDN dn, String attrsId[] )
+    public LookupOperationContext( Registries registries, LdapDN dn, String attrsId[] )
     {
-        super( dn );
+        super( registries, dn );
         this.attrsId = new ArrayList<String>();
         attrsOid = new ArrayList<String>();
         setAttrsId( attrsId );

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveAndRenameOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveAndRenameOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveAndRenameOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveAndRenameOperationContext.java Sat Dec 29 03:42:29 2007
@@ -20,6 +20,7 @@
 package org.apache.directory.server.core.interceptor.context;
 
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 import org.apache.directory.shared.ldap.name.Rdn;
 
@@ -40,9 +41,9 @@
     /**
      * Creates a new instance of MoveAndRenameOperationContext.
      */
-    public MoveAndRenameOperationContext()
+    public MoveAndRenameOperationContext( Registries registries )
     {
-    	super();
+    	super( registries );
     }
 
 
@@ -54,9 +55,9 @@
      * @param newRdn the new rdn to use for the target once renamed
      * @param delOldRdn true if the old rdn value is deleted, false otherwise
      */
-    public MoveAndRenameOperationContext( LdapDN oldDn, LdapDN parent, Rdn newRdn, boolean delOldRdn )
+    public MoveAndRenameOperationContext( Registries registries, LdapDN oldDn, LdapDN parent, Rdn newRdn, boolean delOldRdn )
     {
-        super( oldDn, newRdn, delOldRdn );
+        super( registries, oldDn, newRdn, delOldRdn );
         this.parent = parent;
     }
 

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/MoveOperationContext.java Sat Dec 29 03:42:29 2007
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.server.core.interceptor.context;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 
 /**
@@ -38,9 +39,9 @@
      * Creates a new instance of MoveOperationContext.
      *
      */
-    public MoveOperationContext()
+    public MoveOperationContext( Registries registries )
     {
-    	super();
+    	super( registries );
     }
 
     /**
@@ -48,9 +49,9 @@
      * Creates a new instance of MoveOperationContext.
      *
      */
-    public MoveOperationContext( LdapDN oldDn, LdapDN parent )
+    public MoveOperationContext( Registries registries, LdapDN oldDn, LdapDN parent )
     {
-        super( oldDn );
+        super( registries, oldDn );
         this.parent = parent;
     }
 

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/OperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/OperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/OperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/OperationContext.java Sat Dec 29 03:42:29 2007
@@ -22,6 +22,7 @@
 
 import javax.naming.ldap.Control;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 
 
@@ -57,6 +58,11 @@
      */
     LdapDN getDn();
     
+    
+    /**
+     *  @return The global registries 
+     */
+    Registries getRegistries();
     
     /**
      * Set the context DN

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/RemoveContextPartitionOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/RemoveContextPartitionOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/RemoveContextPartitionOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/RemoveContextPartitionOperationContext.java Sat Dec 29 03:42:29 2007
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.server.core.interceptor.context;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 
 /**
@@ -28,13 +29,14 @@
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class RemoveContextPartitionOperationContext  extends AbstractOperationContext
+public class RemoveContextPartitionOperationContext extends AbstractOperationContext
 {
     /**
      * Creates a new instance of RemoveContextPartitionOperationContext.
      */
-    public RemoveContextPartitionOperationContext()
+    public RemoveContextPartitionOperationContext( Registries registries )
     {
+        super( registries );
     }
     
     /**
@@ -42,9 +44,9 @@
      *
      * @param entryDn The Entry DN from which the partition should be removed
      */
-    public RemoveContextPartitionOperationContext( LdapDN dn )
+    public RemoveContextPartitionOperationContext( Registries registries, LdapDN dn )
     {
-        super( dn );
+        super( registries, dn );
     }
     
     /**

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/RenameOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/RenameOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/RenameOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/RenameOperationContext.java Sat Dec 29 03:42:29 2007
@@ -20,6 +20,7 @@
 package org.apache.directory.server.core.interceptor.context;
 
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 import org.apache.directory.shared.ldap.name.Rdn;
 
@@ -45,9 +46,9 @@
     /**
      * Creates a new instance of RenameOperationContext.
      */
-    public RenameOperationContext()
+    public RenameOperationContext( Registries registries )
     {
-    	super();
+    	super( registries );
     }
 
 
@@ -58,9 +59,9 @@
      * @param newRdn the new RDN to use for the target
      * @param delOldDn true if we delete the old RDN value
      */
-    public RenameOperationContext( LdapDN oldDn, Rdn newRdn, boolean delOldDn )
+    public RenameOperationContext( Registries registries, LdapDN oldDn, Rdn newRdn, boolean delOldDn )
     {
-        super( oldDn );
+        super( registries, oldDn );
         this.newRdn = newRdn;
         this.delOldDn = delOldDn;
     }

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/ReplaceOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/ReplaceOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/ReplaceOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/ReplaceOperationContext.java Sat Dec 29 03:42:29 2007
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.server.core.interceptor.context;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 
 /**
@@ -38,9 +39,9 @@
      * Creates a new instance of ReplaceOperationContext.
      *
      */
-    public ReplaceOperationContext()
+    public ReplaceOperationContext( Registries registries )
     {
-    	super();
+    	super( registries );
     }
 
     /**
@@ -48,9 +49,9 @@
      * Creates a new instance of ReplaceOperationContext.
      *
      */
-    public ReplaceOperationContext( LdapDN oldDn, LdapDN parent )
+    public ReplaceOperationContext( Registries registries, LdapDN oldDn, LdapDN parent )
     {
-        super( oldDn );
+        super( registries, oldDn );
         this.parent = parent;
     }
 

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/SearchOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/SearchOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/SearchOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/SearchOperationContext.java Sat Dec 29 03:42:29 2007
@@ -20,6 +20,7 @@
 package org.apache.directory.server.core.interceptor.context;
 
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.filter.ExprNode;
 import org.apache.directory.shared.ldap.message.AliasDerefMode;
 import org.apache.directory.shared.ldap.name.LdapDN;
@@ -42,15 +43,16 @@
     /** The controls */
     private SearchControls searchControls;
 
+    /** The mode of alias handling */
     private AliasDerefMode aliasDerefMode;
 
 
     /**
      * Creates a new instance of SearchOperationContext.
      */
-    public SearchOperationContext()
+    public SearchOperationContext( Registries registries )
     {
-    	super();
+    	super( registries );
     }
 
 
@@ -61,34 +63,50 @@
      * @param filter the filter AST to use for the search
      * @param searchControls the search controls
      */
-    public SearchOperationContext( LdapDN dn, AliasDerefMode aliasDerefMode, ExprNode filter,
+    public SearchOperationContext( Registries registries, LdapDN dn, AliasDerefMode aliasDerefMode, ExprNode filter,
                                    SearchControls searchControls )
     {
-        super( dn );
+        super( registries, dn );
         this.filter = filter;
         this.aliasDerefMode = aliasDerefMode;
         this.searchControls = searchControls;
     }
 
 
+    /**
+     * @return The filter
+     */
     public ExprNode getFilter()
     {
         return filter;
     }
 
 
+    /**
+     * Set the filter into the context.
+     *
+     * @param filter The filter to set
+     */
     public void setFilter( ExprNode filter )
     {
         this.filter = filter;
     }
 
 
+    /**
+     *  @return The search controls
+     */
     public SearchControls getSearchControls()
     {
         return searchControls;
     }
 
 
+    /**
+     * Set the search controls
+     *
+     * @param searchControls The search controls
+     */
     public void setSearchControls( SearchControls searchControls )
     {
         this.searchControls = searchControls;
@@ -105,12 +123,19 @@
     }
 
 
+    /**
+     *  @return The alias handling mode
+     */
     public AliasDerefMode getAliasDerefMode()
     {
         return aliasDerefMode;
     }
 
 
+    /**
+     * Set the alias handling mode
+     *  @param aliasDerefMode The alias handling mode
+     */
     public void setAliasDerefMode( AliasDerefMode aliasDerefMode )
     {
         this.aliasDerefMode = aliasDerefMode;

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/UnbindOperationContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/UnbindOperationContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/UnbindOperationContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/interceptor/context/UnbindOperationContext.java Sat Dec 29 03:42:29 2007
@@ -19,6 +19,7 @@
  */
 package org.apache.directory.server.core.interceptor.context;
 
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 
 /**
@@ -28,14 +29,14 @@
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$, $Date$
  */
-public class UnbindOperationContext  extends AbstractOperationContext
+public class UnbindOperationContext extends AbstractOperationContext
 {
     /**
      * Creates a new instance of UnbindOperationContext.
      */
-    public UnbindOperationContext()
+    public UnbindOperationContext( Registries registries )
     {
-        super();
+        super( registries );
     }
     
     /**
@@ -43,9 +44,9 @@
      *
      * @param unbindDn The principal DN to unbind
      */
-    public UnbindOperationContext( LdapDN unbindDn )
+    public UnbindOperationContext( Registries registries, LdapDN unbindDn )
     {
-        super( unbindDn );
+        super( registries, unbindDn );
     }
     
     /**

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/ServerContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/ServerContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/ServerContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/ServerContext.java Sat Dec 29 03:42:29 2007
@@ -101,7 +101,7 @@
     /** The directory service which owns this context **/
     private final DirectoryService service;
 
-    /** The AttributeType registry **/
+    /** The global registries **/
     protected final Registries registries;
 
     /** The interceptor proxy to the backend nexus */
@@ -163,12 +163,12 @@
         doBindOperation( props.getBindDn(), props.getCredentials(), props.getAuthenticationMechanisms(), 
             props.getSaslAuthId() );
         
-        if ( ! nexusProxy.hasEntry( new EntryOperationContext( dn ) ) )
+        registries = service.getRegistries();
+
+        if ( ! nexusProxy.hasEntry( new EntryOperationContext( registries, dn ) ) )
         {
             throw new NameNotFoundException( dn + " does not exist" );
         }
-        
-        registries = service.getRegistries();
     }
     
     
@@ -238,7 +238,7 @@
     protected void doDeleteOperation( LdapDN target ) throws NamingException
     {
         // setup the op context and populate with request controls
-        DeleteOperationContext opCtx = new DeleteOperationContext( target );
+        DeleteOperationContext opCtx = new DeleteOperationContext( registries, target );
         opCtx.addRequestControls( requestControls );
         
         // execute delete operation
@@ -263,7 +263,7 @@
         throws NamingException
     {
         // setup the op context and populate with request controls
-        SearchOperationContext opCtx = new SearchOperationContext( dn, aliasDerefMode, filter, searchControls );
+        SearchOperationContext opCtx = new SearchOperationContext( registries, dn, aliasDerefMode, filter, searchControls );
         opCtx.addRequestControls( requestControls );
         
         // execute search operation
@@ -283,7 +283,7 @@
     protected NamingEnumeration<SearchResult> doListOperation( LdapDN target ) throws NamingException
     {
         // setup the op context and populate with request controls
-        ListOperationContext opCtx = new ListOperationContext( target );
+        ListOperationContext opCtx = new ListOperationContext( registries, target );
         opCtx.addRequestControls( requestControls );
         
         // execute list operation
@@ -299,7 +299,7 @@
     
     protected Attributes doGetRootDSEOperation( LdapDN target ) throws NamingException
     {
-        GetRootDSEOperationContext opCtx = new GetRootDSEOperationContext( target );
+        GetRootDSEOperationContext opCtx = new GetRootDSEOperationContext( registries, target );
         opCtx.addRequestControls( requestControls );
         
         // do not reset request controls since this is not an external 
@@ -317,7 +317,7 @@
         LookupOperationContext opCtx;
         
         // execute lookup/getRootDSE operation
-        opCtx = new LookupOperationContext( target );
+        opCtx = new LookupOperationContext( registries, target );
         opCtx.addRequestControls( requestControls );
         Attributes attributes = nexusProxy.lookup( opCtx );
 
@@ -337,7 +337,7 @@
         LookupOperationContext opCtx;
         
         // execute lookup/getRootDSE operation
-        opCtx = new LookupOperationContext( target, attrIds );
+        opCtx = new LookupOperationContext( registries, target, attrIds );
         opCtx.addRequestControls( requestControls );
         Attributes attributes = nexusProxy.lookup( opCtx );
 
@@ -356,7 +356,7 @@
         throws NamingException
     {
         // setup the op context and populate with request controls
-        BindOperationContext opCtx = new BindOperationContext();
+        BindOperationContext opCtx = new BindOperationContext( registries );
         opCtx.setDn( bindDn );
         opCtx.setCredentials( credentials );
         opCtx.setMechanisms( mechanisms );
@@ -380,7 +380,7 @@
     {
         // setup the op context and populate with request controls
         MoveAndRenameOperationContext opCtx =
-                new MoveAndRenameOperationContext( oldDn, parent, new Rdn( newRdn ), delOldDn );
+                new MoveAndRenameOperationContext( registries, oldDn, parent, new Rdn( newRdn ), delOldDn );
         opCtx.addRequestControls( requestControls );
         
         // execute moveAndRename operation
@@ -416,7 +416,7 @@
     protected void doMove( LdapDN oldDn, LdapDN target ) throws NamingException
     {
         // setup the op context and populate with request controls
-        MoveOperationContext opCtx = new MoveOperationContext( oldDn, target );
+        MoveOperationContext opCtx = new MoveOperationContext( registries, oldDn, target );
         opCtx.addRequestControls( requestControls );
         
         // execute move operation
@@ -434,7 +434,7 @@
     protected void doRename( LdapDN oldDn, String newRdn, boolean delOldRdn ) throws NamingException
     {
         // setup the op context and populate with request controls
-        RenameOperationContext opCtx = new RenameOperationContext( oldDn, new Rdn( newRdn ), delOldRdn );
+        RenameOperationContext opCtx = new RenameOperationContext( registries, oldDn, new Rdn( newRdn ), delOldRdn );
         opCtx.addRequestControls( requestControls );
         
         // execute rename operation
@@ -860,7 +860,7 @@
     {
         LdapDN target = buildTarget( name );
         
-        if ( nexusProxy.hasEntry( new EntryOperationContext( target ) ) )
+        if ( nexusProxy.hasEntry( new EntryOperationContext( registries, target ) ) )
         {
             doDeleteOperation( target );
         }

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/ServerDirContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/ServerDirContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/ServerDirContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/ServerDirContext.java Sat Dec 29 03:42:29 2007
@@ -372,7 +372,7 @@
     {
         LdapDN target = buildTarget( name );
         
-        if ( getNexusProxy().hasEntry( new EntryOperationContext( target ) ) )
+        if ( getNexusProxy().hasEntry( new EntryOperationContext( registries, target ) ) )
         {
             doDeleteOperation( target );
         }

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/ServerLdapContext.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/ServerLdapContext.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/ServerLdapContext.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/jndi/ServerLdapContext.java Sat Dec 29 03:42:29 2007
@@ -168,7 +168,7 @@
     public boolean compare( LdapDN name, String oid, Object value ) throws NamingException
     {
         // make sure we add the request controls to operation
-        CompareOperationContext opCtx = new CompareOperationContext( name, oid, value );
+        CompareOperationContext opCtx = new CompareOperationContext( registries, name, oid, value );
         opCtx.addRequestControls( requestControls );
 
         // execute operation
@@ -204,7 +204,7 @@
             principalDn = new LdapDN( bindDn );
         }
 
-        UnbindOperationContext opCtx = new UnbindOperationContext( principalDn );
+        UnbindOperationContext opCtx = new UnbindOperationContext( registries, principalDn );
         opCtx.addRequestControls( requestControls );
         super.getNexusProxy().unbind( opCtx );
         responseControls = opCtx.getResponseControls();

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/partition/AbstractPartition.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/partition/AbstractPartition.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/partition/AbstractPartition.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/partition/AbstractPartition.java Sat Dec 29 03:42:29 2007
@@ -152,7 +152,7 @@
     {
         try
         {
-            return lookup( new LookupOperationContext( entryContext.getDn() ) ) != null;
+            return lookup( new LookupOperationContext( entryContext.getRegistries(), entryContext.getDn() ) ) != null;
         }
         catch ( NameNotFoundException e )
         {

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/partition/DefaultPartitionNexus.java Sat Dec 29 03:42:29 2007
@@ -49,6 +49,7 @@
 import org.apache.directory.server.core.partition.tree.Node;
 import org.apache.directory.server.schema.registries.AttributeTypeRegistry;
 import org.apache.directory.server.schema.registries.OidRegistry;
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.MultiException;
 import org.apache.directory.shared.ldap.NotImplementedException;
 import org.apache.directory.shared.ldap.constants.SchemaConstants;
@@ -144,7 +145,13 @@
     /** the read only rootDSE attributes */
     private final Attributes rootDSE;
 
-    private AttributeTypeRegistry attrRegistry;
+    /** The global registries */
+    private Registries registries;
+    
+    /** The attributeType registry */
+    private AttributeTypeRegistry atRegistry;
+    
+    /** The OID registry */
     private OidRegistry oidRegistry;
     private Object partitionLookupTreeLock = new Object();
 
@@ -321,8 +328,9 @@
         }
 
         this.directoryService = directoryService;
-        this.attrRegistry = directoryService.getRegistries().getAttributeTypeRegistry();
-        this.oidRegistry = directoryService.getRegistries().getOidRegistry();
+        registries = directoryService.getRegistries();
+        atRegistry = registries.getAttributeTypeRegistry();
+        oidRegistry = registries.getOidRegistry();
         
         initializeSystemPartition();
         List<Partition> initializedPartitions = new ArrayList<Partition>();
@@ -334,8 +342,9 @@
         {
             while ( partitions.hasNext() )
             {
-                Partition p = partitions.next();
-                AddContextPartitionOperationContext opCtx = new AddContextPartitionOperationContext( p );
+                Partition partition = partitions.next();
+                AddContextPartitionOperationContext opCtx = 
+                    new AddContextPartitionOperationContext( registries, partition );
                 addContextPartition( opCtx );
                 initializedPartitions.add( opCtx.getPartition() );
             }
@@ -405,7 +414,7 @@
             {
                 Set<Index> indices = ( ( JdbmPartition ) override ).getIndexedAttributes();
                 Set<String> indexOids = new HashSet<String>();
-                OidRegistry registry = directoryService.getRegistries().getOidRegistry();
+                OidRegistry registry = registries.getOidRegistry();
 
                 for ( Index index : indices )
                 {
@@ -492,7 +501,7 @@
         {
             try
             {
-                removeContextPartition( new RemoveContextPartitionOperationContext( new LdapDN( suffix ) ) );
+                removeContextPartition( new RemoveContextPartitionOperationContext( registries, new LdapDN( suffix ) ) );
             }
             catch ( NamingException e )
             {
@@ -548,7 +557,7 @@
     public boolean compare( CompareOperationContext compareContext ) throws NamingException
     {
         Partition partition = getPartition( compareContext.getDn() );
-        AttributeTypeRegistry registry = directoryService.getRegistries().getAttributeTypeRegistry();
+        AttributeTypeRegistry registry = registries.getAttributeTypeRegistry();
         
         // complain if we do not recognize the attribute being compared
         if ( !registry.hasAttributeType( compareContext.getOid() ) )
@@ -558,7 +567,7 @@
 
         AttributeType attrType = registry.lookup( compareContext.getOid() );
         
-        Attribute attr = partition.lookup( new LookupOperationContext( compareContext.getDn() ) ).get( attrType.getName() );
+        Attribute attr = partition.lookup( new LookupOperationContext( registries, compareContext.getDn() ) ).get( attrType.getName() );
 
         // complain if the attribute being compared does not exist in the entry
         if ( attr == null )
@@ -712,7 +721,7 @@
         
         while ( dn.size() > 0 )
         {
-            if ( hasEntry( new EntryOperationContext( dn ) ) )
+            if ( hasEntry( new EntryOperationContext( registries, dn ) ) )
             {
                 return dn;
             }
@@ -932,7 +941,7 @@
                     {
                         // add all user attribute
                         Attribute attr = ii.next();
-                        AttributeType type = attrRegistry.lookup( attr.getID() );
+                        AttributeType type = atRegistry.lookup( attr.getID() );
                         if ( type.getUsage() == UsageEnum.USER_APPLICATIONS )
                         {
                             attrs.put( attr );
@@ -950,7 +959,7 @@
                     {
                         // add all operational attributes
                         Attribute attr = ii.next();
-                        AttributeType type = attrRegistry.lookup( attr.getID() );
+                        AttributeType type = atRegistry.lookup( attr.getID() );
                         if ( type.getUsage() != UsageEnum.USER_APPLICATIONS )
                         {
                             attrs.put( attr );
@@ -968,7 +977,7 @@
                     {
                       // add user attributes specifically asked for
                         Attribute attr = ii.next();
-                        AttributeType type = attrRegistry.lookup( attr.getID() );
+                        AttributeType type = atRegistry.lookup( attr.getID() );
                         if ( realIds.contains( type.getOid() ) )
                         {
                             attrs.put( attr );

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/referral/ReferralInterceptor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/referral/ReferralInterceptor.java?rev=607412&r1=607411&r2=607412&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/referral/ReferralInterceptor.java (original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/referral/ReferralInterceptor.java Sat Dec 29 03:42:29 2007
@@ -65,6 +65,7 @@
 import org.apache.directory.server.core.trigger.TriggerInterceptor;
 import org.apache.directory.server.schema.registries.AttributeTypeRegistry;
 import org.apache.directory.server.schema.registries.OidRegistry;
+import org.apache.directory.server.schema.registries.Registries;
 import org.apache.directory.shared.ldap.NotImplementedException;
 import org.apache.directory.shared.ldap.codec.util.LdapURL;
 import org.apache.directory.shared.ldap.codec.util.LdapURLEncodingException;
@@ -115,7 +116,14 @@
 
     private ReferralLut lut = new ReferralLut();
     private PartitionNexus nexus;
-    private AttributeTypeRegistry attrRegistry;
+    
+    /** The attributeType registry */
+    private AttributeTypeRegistry atRegistry;
+    
+    /** Thre global registries */
+    private Registries registries;
+    
+    /** The OID registry */
     private OidRegistry oidRegistry;
 
     
@@ -274,8 +282,9 @@
     public void init( DirectoryService directoryService ) throws NamingException
     {
         nexus = directoryService.getPartitionNexus();
-        attrRegistry = directoryService.getRegistries().getAttributeTypeRegistry();
-        oidRegistry = directoryService.getRegistries().getOidRegistry();
+        registries = directoryService.getRegistries();
+        atRegistry = registries.getAttributeTypeRegistry();
+        oidRegistry = registries.getOidRegistry();
 
         Iterator<String> suffixes = nexus.listSuffixes( null );
         
@@ -283,7 +292,7 @@
         {
             LdapDN suffix = new LdapDN( suffixes.next() );
             addReferrals( nexus.search( new SearchOperationContext(
-                    suffix, AliasDerefMode.DEREF_ALWAYS, getReferralFilter(), getControls() ) ), suffix );
+                    registries, suffix, AliasDerefMode.DEREF_ALWAYS, getReferralFilter(), getControls() ) ), suffix );
         }
     }
 
@@ -316,7 +325,7 @@
             }
 
             LdapDN urlDn = new LdapDN( ldapUrl.getDn().toNormName() );
-            urlDn.normalize( attrRegistry.getNormalizerMapping() );
+            urlDn.normalize( atRegistry.getNormalizerMapping() );
             
             if ( urlDn.equals( farthest ) )
             {
@@ -402,8 +411,8 @@
                 return;
             }
 
-            Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( farthest ), PartitionNexusProxy.LOOKUP_BYPASS );
-            AttributeType refsType = attrRegistry.lookup( oidRegistry.getOid( SchemaConstants.REF_AT ) );
+            Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( registries, farthest ), PartitionNexusProxy.LOOKUP_BYPASS );
+            AttributeType refsType = atRegistry.lookup( oidRegistry.getOid( SchemaConstants.REF_AT ) );
             Attribute refs = AttributeUtils.getAttribute( referral, refsType );
             doReferralException( farthest, new LdapDN( name.getUpName() ), refs );
         }
@@ -442,7 +451,7 @@
                 return next.compare( opContext );
             }
 
-            Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( farthest ), PartitionNexusProxy.LOOKUP_BYPASS );
+            Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( registries, farthest ), PartitionNexusProxy.LOOKUP_BYPASS );
             Attribute refs = referral.get( SchemaConstants.REF_AT );
             doReferralException( farthest, new LdapDN( name.getUpName() ), refs );
 
@@ -497,7 +506,7 @@
                 return;
             }
 
-            Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( farthest ), PartitionNexusProxy.LOOKUP_BYPASS );
+            Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( registries, farthest ), PartitionNexusProxy.LOOKUP_BYPASS );
             Attribute refs = referral.get( SchemaConstants.REF_AT );
             doReferralException( farthest, new LdapDN( name.getUpName() ), refs );
         }
@@ -569,7 +578,7 @@
             }
             else if ( farthestSrc != null )
             {
-                Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( farthestSrc ),
+                Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( registries, farthestSrc ),
                     PartitionNexusProxy.LOOKUP_BYPASS );
                 Attribute refs = referral.get( SchemaConstants.REF_AT );
                 doReferralException( farthestSrc, new LdapDN( oldName.getUpName() ), refs );
@@ -641,7 +650,7 @@
             }
             else if ( farthestSrc != null )
             {
-                Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( farthestSrc ),
+                Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( registries, farthestSrc ),
                     PartitionNexusProxy.LOOKUP_BYPASS );
                 Attribute refs = referral.get( SchemaConstants.REF_AT );
                 doReferralException( farthestSrc, new LdapDN( oldName.getUpName() ), refs );
@@ -718,7 +727,7 @@
             
             if ( farthestSrc != null )
             {
-                Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( farthestSrc ),
+                Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( registries, farthestSrc ),
                     PartitionNexusProxy.LOOKUP_BYPASS );
                 Attribute refs = referral.get( SchemaConstants.REF_AT );
                 doReferralException( farthestSrc, new LdapDN( oldName.getUpName() ), refs );
@@ -847,7 +856,7 @@
                 return;
             }
 
-            Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( farthest ), PartitionNexusProxy.LOOKUP_BYPASS );
+            Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( registries, farthest ), PartitionNexusProxy.LOOKUP_BYPASS );
             Attribute refs = referral.get( SchemaConstants.REF_AT );
             doReferralException( farthest, new LdapDN( name.getUpName() ), refs );
         }
@@ -886,7 +895,7 @@
         Partition partition = opContext.getPartition();
         LdapDN suffix = partition.getSuffixDn();
         Invocation invocation = InvocationStack.getInstance().peek();
-        NamingEnumeration<SearchResult> list = invocation.getProxy().search( new SearchOperationContext( suffix,
+        NamingEnumeration<SearchResult> list = invocation.getProxy().search( new SearchOperationContext( registries, suffix,
                 AliasDerefMode.DEREF_ALWAYS, getReferralFilter(), getControls() ), SEARCH_BYPASS );
         addReferrals( list, suffix );
     }
@@ -897,7 +906,7 @@
         // remove referrals immediately before removing the partition
         Invocation invocation = InvocationStack.getInstance().peek();
         NamingEnumeration<SearchResult> list = invocation.getProxy().search( 
-            new SearchOperationContext( opContext.getDn(), AliasDerefMode.DEREF_ALWAYS,
+            new SearchOperationContext( registries, opContext.getDn(), AliasDerefMode.DEREF_ALWAYS,
                     getReferralFilter(), getControls() ), SEARCH_BYPASS );
         
         deleteReferrals( list, opContext.getDn() );
@@ -912,7 +921,7 @@
             SearchResult r = referrals.next();
             LdapDN referral;
             LdapDN result = new LdapDN( r.getName() );
-            result.normalize( attrRegistry.getNormalizerMapping() );
+            result.normalize( atRegistry.getNormalizerMapping() );
             
             if ( r.isRelative() )
             {
@@ -933,7 +942,7 @@
             SearchResult r = referrals.next();
             LdapDN referral;
             LdapDN result = new LdapDN( r.getName() );
-            result.normalize( attrRegistry.getNormalizerMapping() );
+            result.normalize( atRegistry.getNormalizerMapping() );
 
             if ( r.isRelative() )
             {
@@ -973,7 +982,7 @@
         {
             if ( lut.isReferral( base ) )
             {
-                Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( base ), PartitionNexusProxy.LOOKUP_BYPASS );
+                Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( registries, base ), PartitionNexusProxy.LOOKUP_BYPASS );
                 Attribute refs = referral.get( SchemaConstants.REF_AT );
                 doReferralExceptionOnSearchBase( base, refs, controls.getSearchScope() );
             }
@@ -985,7 +994,7 @@
                 return next.search( opContext );
             }
 
-            Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( farthest ), PartitionNexusProxy.LOOKUP_BYPASS );
+            Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( registries, farthest ), PartitionNexusProxy.LOOKUP_BYPASS );
             Attribute refs = referral.get( SchemaConstants.REF_AT );
             doReferralExceptionOnSearchBase( farthest, new LdapDN( base.getUpName() ), refs, controls.getSearchScope() );
             throw new IllegalStateException( "Should never get here: shutting up compiler" );
@@ -995,7 +1004,7 @@
         {
             if ( lut.isReferral( base ) )
             {
-                Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( base ), PartitionNexusProxy.LOOKUP_BYPASS );
+                Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( registries, base ), PartitionNexusProxy.LOOKUP_BYPASS );
                 Attribute refs = referral.get( SchemaConstants.REF_AT );
                 doReferralExceptionOnSearchBase( base, refs, controls.getSearchScope() );
             }
@@ -1006,10 +1015,10 @@
             {
                 SearchResultFilteringEnumeration srfe = 
                     ( SearchResultFilteringEnumeration ) next.search( opContext );
-                return new ReferralHandlingEnumeration( srfe, lut, attrRegistry, nexus, controls.getSearchScope(), true );
+                return new ReferralHandlingEnumeration( srfe, lut, opContext.getRegistries(), nexus, controls.getSearchScope(), true );
             }
 
-            Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( farthest ), PartitionNexusProxy.LOOKUP_BYPASS );
+            Attributes referral = invocation.getProxy().lookup( new LookupOperationContext( registries, farthest ), PartitionNexusProxy.LOOKUP_BYPASS );
             Attribute refs = referral.get( SchemaConstants.REF_AT );
             doReferralExceptionOnSearchBase( farthest, new LdapDN( base.getUpName() ), refs, controls.getSearchScope() );
             throw new IllegalStateException( "Should never get here: shutting up compiler" );
@@ -1131,7 +1140,7 @@
             }
 
             LdapDN urlDn = new LdapDN( ldapUrl.getDn().toNormName() );
-            urlDn.normalize( attrRegistry.getNormalizerMapping() );
+            urlDn.normalize( atRegistry.getNormalizerMapping() );
             int diff = targetUpdn.size() - farthest.size();
             LdapDN extra = new LdapDN();
             
@@ -1195,7 +1204,7 @@
         }
 
         LdapDN dn = new LdapDN( name );
-        dn.normalize( attrRegistry.getNormalizerMapping() );
+        dn.normalize( atRegistry.getNormalizerMapping() );
 
         return lut.isReferral( dn );
     }
@@ -1209,6 +1218,6 @@
      */
     public boolean isReferral( LdapDN name ) throws NamingException
     {
-  		return lut.isReferral( name.isNormalized() ? name :  LdapDN.normalize( name, attrRegistry.getNormalizerMapping() ) );
+  		return lut.isReferral( name.isNormalized() ? name :  LdapDN.normalize( name, atRegistry.getNormalizerMapping() ) );
     }
 }



Mime
View raw message