directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r485849 - in /directory/branches/trunks/schema/apacheds: bootstrap-schema/src/test/java/org/ bootstrap-schema/src/test/java/org/apache/ bootstrap-schema/src/test/java/org/apache/directory/ bootstrap-schema/src/test/java/org/apache/directory...
Date Mon, 11 Dec 2006 19:55:03 GMT
Author: akarasulu
Date: Mon Dec 11 11:55:02 2006
New Revision: 485849

URL: http://svn.apache.org/viewvc?view=rev&rev=485849
Log:
got everything now to a compiling state; cleaned up some code that was using bootstrap configurations for startup

Added:
    directory/branches/trunks/schema/apacheds/bootstrap-schema/src/test/java/org/
    directory/branches/trunks/schema/apacheds/bootstrap-schema/src/test/java/org/apache/
    directory/branches/trunks/schema/apacheds/bootstrap-schema/src/test/java/org/apache/directory/
    directory/branches/trunks/schema/apacheds/bootstrap-schema/src/test/java/org/apache/directory/server/
    directory/branches/trunks/schema/apacheds/bootstrap-schema/src/test/java/org/apache/directory/server/core/
    directory/branches/trunks/schema/apacheds/bootstrap-schema/src/test/java/org/apache/directory/server/core/schema/
    directory/branches/trunks/schema/apacheds/bootstrap-schema/src/test/java/org/apache/directory/server/core/schema/bootstrap/
    directory/branches/trunks/schema/apacheds/bootstrap-schema/src/test/java/org/apache/directory/server/core/schema/bootstrap/ExtraSchemaLoadTest.java
Modified:
    directory/branches/trunks/schema/apacheds/core-unit/pom.xml
    directory/branches/trunks/schema/apacheds/core-unit/src/test/java/org/apache/directory/server/core/SearchOpsITest.java
    directory/branches/trunks/schema/apacheds/core/src/main/java/org/apache/directory/server/core/schema/bootstrap/BootstrapSchemaLoader.java
    directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/SchemaCheckerTest.java
    directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/SchemaServiceTest.java
    directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/bootstrap/BootstrapSchemaLoaderTest.java
    directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/RefinementEvaluatorTest.java
    directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/RefinementLeafEvaluatorTest.java
    directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java
    directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/ReplicationService.java
    directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientContextHandler.java
    directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationServerContextHandler.java
    directory/branches/trunks/schema/apacheds/mitosis/src/test/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStoreTest.java
    directory/branches/trunks/schema/apacheds/protocol-shared/pom.xml
    directory/branches/trunks/schema/apacheds/protocol-shared/src/main/java/org/apache/directory/server/protocol/shared/AbstractBackingStoreTest.java
    directory/branches/trunks/schema/apacheds/server-jndi/src/main/java/org/apache/directory/server/configuration/MutableServerStartupConfiguration.java
    directory/branches/trunks/schema/apacheds/server-tools/src/main/java/org/apache/directory/server/tools/commands/dumpcmd/DumpCommandExecutor.java

Added: directory/branches/trunks/schema/apacheds/bootstrap-schema/src/test/java/org/apache/directory/server/core/schema/bootstrap/ExtraSchemaLoadTest.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/bootstrap-schema/src/test/java/org/apache/directory/server/core/schema/bootstrap/ExtraSchemaLoadTest.java?view=auto&rev=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/bootstrap-schema/src/test/java/org/apache/directory/server/core/schema/bootstrap/ExtraSchemaLoadTest.java (added)
+++ directory/branches/trunks/schema/apacheds/bootstrap-schema/src/test/java/org/apache/directory/server/core/schema/bootstrap/ExtraSchemaLoadTest.java Mon Dec 11 11:55:02 2006
@@ -0,0 +1,292 @@
+/*
+ *  Licensed to the Apache Software Foundation (ASF) under one
+ *  or more contributor license agreements.  See the NOTICE file
+ *  distributed with this work for additional information
+ *  regarding copyright ownership.  The ASF licenses this file
+ *  to you under the Apache License, Version 2.0 (the
+ *  "License"); you may not use this file except in compliance
+ *  with the License.  You may obtain a copy of the License at
+ *  
+ *    http://www.apache.org/licenses/LICENSE-2.0
+ *  
+ *  Unless required by applicable law or agreed to in writing,
+ *  software distributed under the License is distributed on an
+ *  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ *  KIND, either express or implied.  See the License for the
+ *  specific language governing permissions and limitations
+ *  under the License. 
+ *  
+ */
+package org.apache.directory.server.core.schema.bootstrap;
+
+
+import java.io.PrintWriter;
+import java.io.StringWriter;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+
+import javax.naming.NamingException;
+
+import junit.framework.TestCase;
+
+import org.apache.directory.server.core.schema.bootstrap.ApacheSchema;
+import org.apache.directory.server.core.schema.bootstrap.BootstrapRegistries;
+import org.apache.directory.server.core.schema.bootstrap.BootstrapSchemaLoader;
+import org.apache.directory.server.core.schema.bootstrap.CoreSchema;
+import org.apache.directory.server.core.schema.bootstrap.SystemSchema;
+import org.apache.directory.shared.ldap.schema.AttributeType;
+
+
+/**
+ * A unit test case for the BootstrapSchemaLoader class.
+ *
+ * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
+ * @version $Rev: 437012 $
+ */
+public class ExtraSchemaLoadTest extends TestCase
+{
+    BootstrapRegistries registries;
+
+
+    protected void setUp() throws Exception
+    {
+        super.setUp();
+        registries = new BootstrapRegistries();
+    }
+
+
+    protected void tearDown() throws Exception
+    {
+        super.tearDown();
+        registries = null;
+    }
+
+
+    public void testLoadAll() throws NamingException
+    {
+        BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
+        Set<BootstrapSchema> schemas = new HashSet<BootstrapSchema>();
+        schemas.add( new CoreSchema() );
+        schemas.add( new ApacheSchema() );
+        schemas.add( new ApachednsSchema() );
+        schemas.add( new SystemSchema() );
+        schemas.add( new JavaSchema() );
+        schemas.add( new CorbaSchema() );
+        schemas.add( new CosineSchema() );
+        schemas.add( new DhcpSchema() );
+        schemas.add( new InetorgpersonSchema() );
+        schemas.add( new MozillaSchema() );
+        schemas.add( new CollectiveSchema() );
+        schemas.add( new AutofsSchema() );
+        schemas.add( new NisSchema() );
+        schemas.add( new SambaSchema() );
+        schemas.add( new Krb5kdcSchema() );
+
+        loader.load( schemas, registries );
+        AttributeType type;
+
+        // from autofs.schema
+        type = registries.getAttributeTypeRegistry().lookup( "automountInformation" );
+        assertNotNull( type );
+
+        // from core.schema
+        type = registries.getAttributeTypeRegistry().lookup( "knowledgeInformation" );
+        assertNotNull( type );
+
+        // from cosine.schema
+        type = registries.getAttributeTypeRegistry().lookup( "textEncodedORAddress" );
+        assertNotNull( type );
+
+        // from corba.schema
+        type = registries.getAttributeTypeRegistry().lookup( "corbaRepositoryId" );
+        assertNotNull( type );
+
+        // from eve.schema
+        type = registries.getAttributeTypeRegistry().lookup( "apacheAlias" );
+        assertNotNull( type );
+
+        // from inetorgperson.schema
+        type = registries.getAttributeTypeRegistry().lookup( "carLicense" );
+        assertNotNull( type );
+
+        // from java.schema
+        type = registries.getAttributeTypeRegistry().lookup( "javaClassName" );
+        assertNotNull( type );
+
+        // from krb5kdc.schema
+        type = registries.getAttributeTypeRegistry().lookup( "krb5PrincipalName" );
+        assertNotNull( type );
+
+        // from nis.schema
+        type = registries.getAttributeTypeRegistry().lookup( "homeDirectory" );
+        assertNotNull( type );
+
+        // from system.schema
+        type = registries.getAttributeTypeRegistry().lookup( "distinguishedName" );
+        assertNotNull( type );
+
+    }
+
+
+    public void testApacheSchemaLoad() throws NamingException
+    {
+        ApacheSchema apacheSchema = new ApacheSchema();
+        BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
+        loader.load( new SystemSchema(), registries );
+        loader.load( apacheSchema, registries );
+
+        AttributeType type;
+        type = registries.getAttributeTypeRegistry().lookup( "apacheNdn" );
+        assertNotNull( type );
+
+        type = registries.getAttributeTypeRegistry().lookup( "apacheAlias" );
+        assertNotNull( type );
+
+        type = registries.getAttributeTypeRegistry().lookup( "apacheUpdn" );
+        assertNotNull( type );
+    }
+
+
+    public void testDepsSchemaLoad() throws NamingException
+    {
+        BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
+
+        Set<BootstrapSchema> schemas = new HashSet<BootstrapSchema>();
+        schemas.add( new ApacheSchema() );
+        schemas.add( new SystemSchema() );
+
+        loader.load( schemas, registries );
+        AttributeType type;
+        type = registries.getAttributeTypeRegistry().lookup( "apacheNdn" );
+        assertNotNull( type );
+
+        type = registries.getAttributeTypeRegistry().lookup( "apacheAlias" );
+        assertNotNull( type );
+
+        type = registries.getAttributeTypeRegistry().lookup( "apacheUpdn" );
+        assertNotNull( type );
+    }
+
+
+    public void testCoreSchemaLoad() throws NamingException
+    {
+        CoreSchema coreSchema = new CoreSchema();
+        BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
+        loader.load( new SystemSchema(), registries );
+        loader.load( coreSchema, registries );
+
+        AttributeType type;
+        type = registries.getAttributeTypeRegistry().lookup( "knowledgeInformation" );
+        assertNotNull( type );
+
+        type = registries.getAttributeTypeRegistry().lookup( "countryName" );
+        assertNotNull( type );
+
+        type = registries.getAttributeTypeRegistry().lookup( "serialNumber" );
+        assertNotNull( type );
+    }
+
+
+    public void testJavaSchemaLoad() throws NamingException
+    {
+        testCoreSchemaLoad();
+
+        JavaSchema javaSchema = new JavaSchema();
+        BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
+        loader.load( javaSchema, registries );
+
+        AttributeType type;
+        type = registries.getAttributeTypeRegistry().lookup( "javaFactory" );
+        assertNotNull( type );
+
+        type = registries.getAttributeTypeRegistry().lookup( "javaSerializedData" );
+        assertNotNull( type );
+
+        type = registries.getAttributeTypeRegistry().lookup( "javaClassNames" );
+        assertNotNull( type );
+    }
+
+
+    public void testJavaDepsSchemaLoad() throws NamingException
+    {
+        BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
+
+        Set<BootstrapSchema> schemas = new HashSet<BootstrapSchema>();
+        schemas.add( new CoreSchema() );
+        schemas.add( new JavaSchema() );
+        schemas.add( new SystemSchema() );
+
+        loader.load( schemas, registries );
+        AttributeType type;
+        type = registries.getAttributeTypeRegistry().lookup( "javaFactory" );
+        assertNotNull( type );
+
+        type = registries.getAttributeTypeRegistry().lookup( "javaSerializedData" );
+        assertNotNull( type );
+
+        type = registries.getAttributeTypeRegistry().lookup( "javaClassNames" );
+        assertNotNull( type );
+    }
+
+
+    public void testApacheAndJavaDepsSchemaLoad() throws NamingException
+    {
+        BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
+
+        Set<BootstrapSchema> schemas = new HashSet<BootstrapSchema>();
+        schemas.add( new ApacheSchema() );
+        schemas.add( new CoreSchema() );
+        schemas.add( new JavaSchema() );
+        schemas.add( new SystemSchema() );
+
+        loader.load( schemas, registries );
+        AttributeType type;
+        type = registries.getAttributeTypeRegistry().lookup( "apacheAlias" );
+        assertNotNull( type );
+
+        type = registries.getAttributeTypeRegistry().lookup( "apacheNdn" );
+        assertNotNull( type );
+
+        type = registries.getAttributeTypeRegistry().lookup( "apacheUpdn" );
+        assertNotNull( type );
+    }
+
+
+    /**
+     * Attempts to resolve the dependent schema objects of all entities that
+     * refer to other objects within the registries.
+     *
+     * @throws NamingException if there are problems.
+     */
+    public void testReferentialIntegrity() throws NamingException
+    {
+        if ( System.getProperties().containsKey( "ignore.ref.integ.test" ) )
+        {
+            System.err.println( "REFERENTIAL INTEGRITY TESTS BYPASSED!!!" );
+            return;
+        }
+
+        testLoadAll();
+        List errors = registries.checkRefInteg();
+        assertNotNull( errors );
+
+        StringBuffer buf = new StringBuffer();
+
+        if ( !errors.isEmpty() )
+        {
+            buf.append( "expected empty erorrs but got " ).append( errors.size() ).append( " errors:\n" );
+            for ( int ii = 0; ii < errors.size(); ii++ )
+            {
+                buf.append( '\t' ).append( errors.get( ii ).toString() ).append( '\n' );
+            }
+
+            StringWriter out = new StringWriter();
+            Exception e = ( Exception ) errors.get( 0 );
+            e.printStackTrace( new PrintWriter( out ) );
+            buf.append( "\nfirst exception trace:\n" + out.getBuffer().toString() );
+        }
+
+        assertTrue( buf.toString(), errors.isEmpty() );
+    }
+}

Modified: directory/branches/trunks/schema/apacheds/core-unit/pom.xml
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/core-unit/pom.xml?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/core-unit/pom.xml (original)
+++ directory/branches/trunks/schema/apacheds/core-unit/pom.xml Mon Dec 11 11:55:02 2006
@@ -32,6 +32,13 @@
       <artifactId>apacheds-core</artifactId>
       <version>${pom.version}</version>
     </dependency>  
+
+    <dependency>
+      <groupId>org.apache.directory.server</groupId>
+      <artifactId>apacheds-bootstrap-schema</artifactId>
+      <version>${pom.version}</version>
+      <scope>test</scope>
+    </dependency>  
   </dependencies>
 
   <profiles>

Modified: directory/branches/trunks/schema/apacheds/core-unit/src/test/java/org/apache/directory/server/core/SearchOpsITest.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/core-unit/src/test/java/org/apache/directory/server/core/SearchOpsITest.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/core-unit/src/test/java/org/apache/directory/server/core/SearchOpsITest.java (original)
+++ directory/branches/trunks/schema/apacheds/core-unit/src/test/java/org/apache/directory/server/core/SearchOpsITest.java Mon Dec 11 11:55:02 2006
@@ -33,6 +33,7 @@
 
 import org.apache.directory.server.core.configuration.MutablePartitionConfiguration;
 import org.apache.directory.server.core.partition.impl.btree.MutableIndexConfiguration;
+import org.apache.directory.server.core.schema.bootstrap.BootstrapSchema;
 import org.apache.directory.server.core.schema.bootstrap.NisSchema;
 import org.apache.directory.server.core.unit.AbstractAdminTestCase;
 
@@ -55,16 +56,24 @@
     }
     
     
+    @SuppressWarnings("unchecked")
     public void setUp() throws Exception
     {
         // -------------------------------------------------------------------
         // Alter the system configuration to include the NisSchema
         // -------------------------------------------------------------------
 
-        Set schemas = new HashSet();
-        schemas.addAll( configuration.getBootstrapSchemas() );
+        if ( true )
+        {
+            throw new RuntimeException( "Fix this startup code that tries to initialize the server to use the nis " +
+                    "\nschema; so it looks like we still need some way to tell the config how to use different" +
+                    "\nschemas without having to initialize bootstrap schema objects." );
+        }
+        
+        Set<BootstrapSchema> schemas = new HashSet<BootstrapSchema>();
+        //schemas.addAll( configuration.getBootstrapSchemas() );
         schemas.add( new NisSchema() );
-        configuration.setBootstrapSchemas( schemas );
+        //configuration.setBootstrapSchemas( schemas );
         
         // -------------------------------------------------------------------
         // Alter the partition configuration to index gidNumber
@@ -108,7 +117,7 @@
      */
     public Set searchGroups( String filter ) throws NamingException
     {
-        Set results = new HashSet();
+        Set<String> results = new HashSet<String>();
         NamingEnumeration list = sysRoot.search( "ou=groups", filter, new SearchControls() );
         while( list.hasMore() )
         {

Modified: directory/branches/trunks/schema/apacheds/core/src/main/java/org/apache/directory/server/core/schema/bootstrap/BootstrapSchemaLoader.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/core/src/main/java/org/apache/directory/server/core/schema/bootstrap/BootstrapSchemaLoader.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/core/src/main/java/org/apache/directory/server/core/schema/bootstrap/BootstrapSchemaLoader.java (original)
+++ directory/branches/trunks/schema/apacheds/core/src/main/java/org/apache/directory/server/core/schema/bootstrap/BootstrapSchemaLoader.java Mon Dec 11 11:55:02 2006
@@ -45,7 +45,6 @@
 import org.apache.directory.server.core.schema.SyntaxRegistry;
 import org.apache.directory.server.core.schema.bootstrap.BootstrapSchema;
 import org.apache.directory.server.core.schema.bootstrap.ProducerTypeEnum;
-import org.apache.directory.server.core.schema.bootstrap.SystemSchema;
 import org.apache.directory.shared.ldap.schema.AttributeType;
 import org.apache.directory.shared.ldap.schema.DITContentRule;
 import org.apache.directory.shared.ldap.schema.DITStructureRule;

Modified: directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/SchemaCheckerTest.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/SchemaCheckerTest.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/SchemaCheckerTest.java (original)
+++ directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/SchemaCheckerTest.java Mon Dec 11 11:55:02 2006
@@ -28,7 +28,6 @@
 import org.apache.directory.server.core.schema.ObjectClassRegistry;
 import org.apache.directory.server.core.schema.SchemaChecker;
 import org.apache.directory.server.core.schema.bootstrap.*;
-import org.apache.directory.server.core.schema.global.GlobalRegistries;
 import org.apache.directory.shared.ldap.exception.LdapSchemaViolationException;
 import org.apache.directory.shared.ldap.message.ResultCodeEnum;
 import org.apache.directory.shared.ldap.name.LdapDN;
@@ -63,54 +62,24 @@
     {
         super( name );
 
-        BootstrapRegistries bootstrapRegistries = new BootstrapRegistries();
+        registries = new BootstrapRegistries();
 
         BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
-        Set schemas = new HashSet();
+        Set<BootstrapSchema> schemas = new HashSet<BootstrapSchema>();
         schemas.add( new SystemSchema() );
         schemas.add( new ApacheSchema() );
         schemas.add( new CoreSchema() );
-        schemas.add( new CosineSchema() );
-        schemas.add( new InetorgpersonSchema() );
-        schemas.add( new JavaSchema() );
-        loader.load( schemas, bootstrapRegistries );
+        loader.load( schemas, ( BootstrapRegistries ) registries );
 
-        java.util.List errors = bootstrapRegistries.checkRefInteg();
+        java.util.List errors = registries.checkRefInteg();
         if ( !errors.isEmpty() )
         {
             NamingException e = new NamingException();
             e.setRootCause( ( Throwable ) errors.get( 0 ) );
             throw e;
         }
-
-        registries = new GlobalRegistries( bootstrapRegistries );
     }
 
-
-    //    private GlobalRegistries getGlobalRegistries() throws NamingException
-    //    {
-    //        BootstrapRegistries bootstrapRegistries = new BootstrapRegistries();
-    //
-    //        BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
-    //        Set schemas = new HashSet();
-    //        schemas.add( new SystemSchema() );
-    //        schemas.add( new ApacheSchema() );
-    //        schemas.add( new CoreSchema() );
-    //        schemas.add( new CosineSchema() );
-    //        schemas.add( new InetorgpersonSchema() );
-    //        schemas.add( new JavaSchema() );
-    //        loader.load( schemas, bootstrapRegistries );
-    //
-    //        java.util.List errors = bootstrapRegistries.checkRefInteg();
-    //        if ( !errors.isEmpty() )
-    //        {
-    //            NamingException e = new NamingException();
-    //            e.setRootCause( ( Throwable ) errors.get( 0 ) );
-    //            throw e;
-    //        }
-    //
-    //        return new GlobalRegistries( bootstrapRegistries );
-    //    }
 
     /**
      * Test case to check the schema checker operates correctly when modify

Modified: directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/SchemaServiceTest.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/SchemaServiceTest.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/SchemaServiceTest.java (original)
+++ directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/SchemaServiceTest.java Mon Dec 11 11:55:02 2006
@@ -33,8 +33,6 @@
 import org.apache.directory.server.core.schema.bootstrap.BootstrapRegistries;
 import org.apache.directory.server.core.schema.bootstrap.BootstrapSchemaLoader;
 import org.apache.directory.server.core.schema.bootstrap.CoreSchema;
-import org.apache.directory.server.core.schema.bootstrap.CosineSchema;
-import org.apache.directory.server.core.schema.bootstrap.InetorgpersonSchema;
 import org.apache.directory.server.core.schema.bootstrap.SystemSchema;
 import org.apache.directory.shared.ldap.exception.LdapNamingException;
 import org.apache.directory.shared.ldap.message.ResultCodeEnum;
@@ -59,8 +57,6 @@
         loader.load( new SystemSchema(), registries );
         loader.load( new ApacheSchema(), registries );
         loader.load( new CoreSchema(), registries );
-        loader.load( new CosineSchema(), registries );
-        loader.load( new InetorgpersonSchema(), registries );
     }
 
     
@@ -68,7 +64,7 @@
     {
         AttributeTypeRegistry attrRegistry = registries.getAttributeTypeRegistry();
         Iterator list = attrRegistry.descendants( "name" );
-        Set nameAttrs = new HashSet();
+        Set<String> nameAttrs = new HashSet<String>();
         while ( list.hasNext() )
         {
             AttributeType type = ( AttributeType ) list.next();
@@ -128,24 +124,22 @@
 
     public void testAlterObjectClassesInetOrgPersonAttrValue() throws NamingException
     {
-        Attribute attr = new BasicAttribute( "objectClass", "inetOrgPerson" );
+        Attribute attr = new BasicAttribute( "objectClass", "organizationalPerson" );
         SchemaService.alterObjectClasses( attr, registries.getObjectClassRegistry() );
         assertEquals( 3, attr.size() );
         assertTrue( attr.contains( "person" ) );
         assertTrue( attr.contains( "organizationalPerson" ) );
-        assertTrue( attr.contains( "inetOrgPerson" ) );
     }
 
 
     public void testAlterObjectClassesOverlapping() throws NamingException
     {
-        Attribute attr = new BasicAttribute( "objectClass", "inetOrgPerson" );
+        Attribute attr = new BasicAttribute( "objectClass", "organizationalPerson" );
         attr.add( "residentialPerson" );
         SchemaService.alterObjectClasses( attr, registries.getObjectClassRegistry() );
         assertEquals( 4, attr.size() );
         assertTrue( attr.contains( "person" ) );
         assertTrue( attr.contains( "organizationalPerson" ) );
-        assertTrue( attr.contains( "inetOrgPerson" ) );
         assertTrue( attr.contains( "residentialPerson" ) );
     }
 
@@ -159,7 +153,6 @@
         assertEquals( 6, attr.size() );
         assertTrue( attr.contains( "person" ) );
         assertTrue( attr.contains( "organizationalPerson" ) );
-        assertTrue( attr.contains( "inetOrgPerson" ) );
         assertTrue( attr.contains( "residentialPerson" ) );
         assertTrue( attr.contains( "dSA" ) );
         assertTrue( attr.contains( "applicationEntity" ) );

Modified: directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/bootstrap/BootstrapSchemaLoaderTest.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/bootstrap/BootstrapSchemaLoaderTest.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/bootstrap/BootstrapSchemaLoaderTest.java (original)
+++ directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/schema/bootstrap/BootstrapSchemaLoaderTest.java Mon Dec 11 11:55:02 2006
@@ -31,16 +31,9 @@
 import junit.framework.TestCase;
 
 import org.apache.directory.server.core.schema.bootstrap.ApacheSchema;
-import org.apache.directory.server.core.schema.bootstrap.AutofsSchema;
 import org.apache.directory.server.core.schema.bootstrap.BootstrapRegistries;
 import org.apache.directory.server.core.schema.bootstrap.BootstrapSchemaLoader;
-import org.apache.directory.server.core.schema.bootstrap.CorbaSchema;
 import org.apache.directory.server.core.schema.bootstrap.CoreSchema;
-import org.apache.directory.server.core.schema.bootstrap.CosineSchema;
-import org.apache.directory.server.core.schema.bootstrap.InetorgpersonSchema;
-import org.apache.directory.server.core.schema.bootstrap.JavaSchema;
-import org.apache.directory.server.core.schema.bootstrap.Krb5kdcSchema;
-import org.apache.directory.server.core.schema.bootstrap.NisSchema;
 import org.apache.directory.server.core.schema.bootstrap.SystemSchema;
 import org.apache.directory.shared.ldap.schema.AttributeType;
 
@@ -73,61 +66,25 @@
     public void testLoadAll() throws NamingException
     {
         BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
-        Set schemas = new HashSet();
-        schemas.add( new AutofsSchema() );
+        Set<BootstrapSchema> schemas = new HashSet<BootstrapSchema>();
         schemas.add( new CoreSchema() );
-        schemas.add( new CosineSchema() );
-        schemas.add( new CorbaSchema() );
         schemas.add( new ApacheSchema() );
-        schemas.add( new InetorgpersonSchema() );
-        schemas.add( new JavaSchema() );
-        schemas.add( new Krb5kdcSchema() );
-        schemas.add( new NisSchema() );
         schemas.add( new SystemSchema() );
 
         loader.load( schemas, registries );
         AttributeType type;
 
-        // from autofs.schema
-        type = registries.getAttributeTypeRegistry().lookup( "automountInformation" );
-        assertNotNull( type );
-
         // from core.schema
         type = registries.getAttributeTypeRegistry().lookup( "knowledgeInformation" );
         assertNotNull( type );
 
-        // from cosine.schema
-        type = registries.getAttributeTypeRegistry().lookup( "textEncodedORAddress" );
-        assertNotNull( type );
-
-        // from corba.schema
-        type = registries.getAttributeTypeRegistry().lookup( "corbaRepositoryId" );
-        assertNotNull( type );
-
-        // from eve.schema
+        // from apache.schema
         type = registries.getAttributeTypeRegistry().lookup( "apacheAlias" );
         assertNotNull( type );
 
-        // from inetorgperson.schema
-        type = registries.getAttributeTypeRegistry().lookup( "carLicense" );
-        assertNotNull( type );
-
-        // from java.schema
-        type = registries.getAttributeTypeRegistry().lookup( "javaClassName" );
-        assertNotNull( type );
-
-        // from krb5kdc.schema
-        type = registries.getAttributeTypeRegistry().lookup( "krb5PrincipalName" );
-        assertNotNull( type );
-
-        // from nis.schema
-        type = registries.getAttributeTypeRegistry().lookup( "homeDirectory" );
-        assertNotNull( type );
-
         // from system.schema
         type = registries.getAttributeTypeRegistry().lookup( "distinguishedName" );
         assertNotNull( type );
-
     }
 
 
@@ -173,7 +130,7 @@
     {
         BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
 
-        Set schemas = new HashSet();
+        Set<BootstrapSchema> schemas = new HashSet<BootstrapSchema>();
         schemas.add( new ApacheSchema() );
         schemas.add( new SystemSchema() );
 
@@ -214,7 +171,7 @@
     {
         BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
 
-        Set schemas = new HashSet();
+        Set<BootstrapSchema> schemas = new HashSet<BootstrapSchema>();
         schemas.add( new CoreSchema() );
         schemas.add( new SystemSchema() );
 
@@ -227,71 +184,6 @@
         assertNotNull( type );
 
         type = registries.getAttributeTypeRegistry().lookup( "serialNumber" );
-        assertNotNull( type );
-    }
-
-
-    public void testJavaSchemaLoad() throws NamingException
-    {
-        testCoreSchemaLoad();
-
-        JavaSchema javaSchema = new JavaSchema();
-        BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
-        loader.load( javaSchema, registries );
-
-        AttributeType type;
-        type = registries.getAttributeTypeRegistry().lookup( "javaFactory" );
-        assertNotNull( type );
-
-        type = registries.getAttributeTypeRegistry().lookup( "javaSerializedData" );
-        assertNotNull( type );
-
-        type = registries.getAttributeTypeRegistry().lookup( "javaClassNames" );
-        assertNotNull( type );
-    }
-
-
-    public void testJavaDepsSchemaLoad() throws NamingException
-    {
-        BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
-
-        Set schemas = new HashSet();
-        schemas.add( new CoreSchema() );
-        schemas.add( new JavaSchema() );
-        schemas.add( new SystemSchema() );
-
-        loader.load( schemas, registries );
-        AttributeType type;
-        type = registries.getAttributeTypeRegistry().lookup( "javaFactory" );
-        assertNotNull( type );
-
-        type = registries.getAttributeTypeRegistry().lookup( "javaSerializedData" );
-        assertNotNull( type );
-
-        type = registries.getAttributeTypeRegistry().lookup( "javaClassNames" );
-        assertNotNull( type );
-    }
-
-
-    public void testEveAndJavaDepsSchemaLoad() throws NamingException
-    {
-        BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
-
-        Set schemas = new HashSet();
-        schemas.add( new ApacheSchema() );
-        schemas.add( new CoreSchema() );
-        schemas.add( new JavaSchema() );
-        schemas.add( new SystemSchema() );
-
-        loader.load( schemas, registries );
-        AttributeType type;
-        type = registries.getAttributeTypeRegistry().lookup( "apacheAlias" );
-        assertNotNull( type );
-
-        type = registries.getAttributeTypeRegistry().lookup( "apacheNdn" );
-        assertNotNull( type );
-
-        type = registries.getAttributeTypeRegistry().lookup( "apacheUpdn" );
         assertNotNull( type );
     }
 

Modified: directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/RefinementEvaluatorTest.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/RefinementEvaluatorTest.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/RefinementEvaluatorTest.java (original)
+++ directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/RefinementEvaluatorTest.java Mon Dec 11 11:55:02 2006
@@ -26,8 +26,8 @@
 import javax.naming.directory.BasicAttribute;
 
 import org.apache.directory.server.core.schema.OidRegistry;
+import org.apache.directory.server.core.schema.Registries;
 import org.apache.directory.server.core.schema.bootstrap.*;
-import org.apache.directory.server.core.schema.global.GlobalRegistries;
 import org.apache.directory.server.core.subtree.RefinementEvaluator;
 import org.apache.directory.server.core.subtree.RefinementLeafEvaluator;
 import org.apache.directory.shared.ldap.filter.BranchNode;
@@ -49,8 +49,8 @@
  */
 public class RefinementEvaluatorTest extends TestCase
 {
-    /** the global registries */
-    private GlobalRegistries registries;
+    /** the registries */
+    private Registries registries;
     /** the refinement evaluator to test */
     private RefinementEvaluator evaluator;
 
@@ -63,15 +63,12 @@
     {
         BootstrapRegistries bsRegistries = new BootstrapRegistries();
         BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
-        Set schemas = new HashSet();
+        Set<BootstrapSchema> schemas = new HashSet<BootstrapSchema>();
         schemas.add( new SystemSchema() );
         schemas.add( new ApacheSchema() );
         schemas.add( new CoreSchema() );
-        schemas.add( new CosineSchema() );
-        schemas.add( new InetorgpersonSchema() );
-        schemas.add( new JavaSchema() );
         loader.load( schemas, bsRegistries );
-        registries = new GlobalRegistries( bsRegistries );
+        registries = bsRegistries;
     }
 
 

Modified: directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/RefinementLeafEvaluatorTest.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/RefinementLeafEvaluatorTest.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/RefinementLeafEvaluatorTest.java (original)
+++ directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/RefinementLeafEvaluatorTest.java Mon Dec 11 11:55:02 2006
@@ -26,8 +26,8 @@
 import javax.naming.directory.BasicAttribute;
 
 import org.apache.directory.server.core.schema.OidRegistry;
+import org.apache.directory.server.core.schema.Registries;
 import org.apache.directory.server.core.schema.bootstrap.*;
-import org.apache.directory.server.core.schema.global.GlobalRegistries;
 import org.apache.directory.server.core.subtree.RefinementLeafEvaluator;
 import org.apache.directory.shared.ldap.filter.LeafNode;
 import org.apache.directory.shared.ldap.filter.SimpleNode;
@@ -45,7 +45,7 @@
 public class RefinementLeafEvaluatorTest extends TestCase
 {
     /** the global registries */
-    private GlobalRegistries registries;
+    private Registries registries;
     /** the refinement leaf evaluator to test */
     private RefinementLeafEvaluator evaluator;
 
@@ -58,15 +58,12 @@
     {
         BootstrapRegistries bsRegistries = new BootstrapRegistries();
         BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
-        Set schemas = new HashSet();
+        Set<BootstrapSchema> schemas = new HashSet<BootstrapSchema>();
         schemas.add( new SystemSchema() );
         schemas.add( new ApacheSchema() );
         schemas.add( new CoreSchema() );
-        schemas.add( new CosineSchema() );
-        schemas.add( new InetorgpersonSchema() );
-        schemas.add( new JavaSchema() );
         loader.load( schemas, bsRegistries );
-        registries = new GlobalRegistries( bsRegistries );
+        registries = bsRegistries;
     }
 
 

Modified: directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java (original)
+++ directory/branches/trunks/schema/apacheds/core/src/test/java/org/apache/directory/server/core/subtree/SubtreeEvaluatorTest.java Mon Dec 11 11:55:02 2006
@@ -23,8 +23,8 @@
 import junit.framework.TestCase;
 
 import org.apache.directory.server.core.schema.OidRegistry;
+import org.apache.directory.server.core.schema.Registries;
 import org.apache.directory.server.core.schema.bootstrap.*;
-import org.apache.directory.server.core.schema.global.GlobalRegistries;
 import org.apache.directory.server.core.subtree.SubtreeEvaluator;
 import org.apache.directory.shared.ldap.filter.ExprNode;
 import org.apache.directory.shared.ldap.filter.FilterParser;
@@ -49,22 +49,19 @@
  */
 public class SubtreeEvaluatorTest extends TestCase
 {
-    private GlobalRegistries registries;
+    private Registries registries;
     private SubtreeEvaluator evaluator;
 
 
     private void init() throws NamingException
     {
         BootstrapRegistries bsRegistries = new BootstrapRegistries();
-        registries = new GlobalRegistries( bsRegistries );
+        registries = bsRegistries;
         BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
-        Set schemas = new HashSet();
+        Set<BootstrapSchema> schemas = new HashSet<BootstrapSchema>();
         schemas.add( new SystemSchema() );
         schemas.add( new ApacheSchema() );
         schemas.add( new CoreSchema() );
-        schemas.add( new CosineSchema() );
-        schemas.add( new InetorgpersonSchema() );
-        schemas.add( new JavaSchema() );
         loader.load( schemas, bsRegistries );
     }
 
@@ -154,7 +151,7 @@
     public void testWithMinMaxAndChopAfter() throws Exception
     {
         SubtreeSpecificationModifier modifier = new SubtreeSpecificationModifier();
-        Set chopAfter = new HashSet();
+        Set<LdapDN> chopAfter = new HashSet<LdapDN>();
         chopAfter.add( new LdapDN( "uid=Tori Amos" ) );
         chopAfter.add( new LdapDN( "ou=twolevels,uid=akarasulu" ) );
         modifier.setChopAfterExclusions( chopAfter );
@@ -188,7 +185,7 @@
     public void testWithMinMaxAndChopBefore() throws Exception
     {
         SubtreeSpecificationModifier modifier = new SubtreeSpecificationModifier();
-        Set chopBefore = new HashSet();
+        Set<LdapDN> chopBefore = new HashSet<LdapDN>();
         chopBefore.add( new LdapDN( "uid=Tori Amos" ) );
         chopBefore.add( new LdapDN( "ou=threelevels,ou=twolevels,uid=akarasulu" ) );
         modifier.setChopBeforeExclusions( chopBefore );

Modified: directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/ReplicationService.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/ReplicationService.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/ReplicationService.java (original)
+++ directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/ReplicationService.java Mon Dec 11 11:55:02 2006
@@ -178,7 +178,7 @@
         nexus = serviceCfg.getPartitionNexus();
         store = configuration.getStore();
         operationFactory = new OperationFactory( serviceCfg, configuration );
-        attrRegistry = serviceCfg.getGlobalRegistries().getAttributeTypeRegistry();
+        attrRegistry = serviceCfg.getRegistries().getAttributeTypeRegistry();
 
         // Initialize store and service
         store.open( serviceCfg, configuration );

Modified: directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientContextHandler.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientContextHandler.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientContextHandler.java (original)
+++ directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationClientContextHandler.java Mon Dec 11 11:55:02 2006
@@ -289,7 +289,7 @@
 
             SessionLog.info( ctx.getSession(), "Sending entries under '" + contextName + '\'' );
 
-            Map mapping = ctx.getServiceConfiguration().getGlobalRegistries().getAttributeTypeRegistry()
+            Map mapping = ctx.getServiceConfiguration().getRegistries().getAttributeTypeRegistry()
                 .getNormalizerMapping();
             contextName.normalize( mapping );
             sendAllEntries( ctx, contextName );
@@ -334,7 +334,7 @@
 
                 // Convert the entry into AddEntryOperation log.
                 LdapDN dn = new LdapDN( sr.getName() );
-                dn.normalize( ctx.getServiceConfiguration().getGlobalRegistries()
+                dn.normalize( ctx.getServiceConfiguration().getRegistries()
                     .getAttributeTypeRegistry().getNormalizerMapping() );
                 Operation op = new AddEntryOperation( csn, dn, attrs );
 

Modified: directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationServerContextHandler.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationServerContextHandler.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationServerContextHandler.java (original)
+++ directory/branches/trunks/schema/apacheds/mitosis/src/main/java/org/apache/directory/mitosis/service/protocol/handler/ReplicationServerContextHandler.java Mon Dec 11 11:55:02 2006
@@ -190,7 +190,7 @@
         {
             op.execute( ctx.getServiceConfiguration().getPartitionNexus(), 
                 ctx.getConfiguration().getStore(),
-                ctx.getServiceConfiguration().getGlobalRegistries().getAttributeTypeRegistry() );
+                ctx.getServiceConfiguration().getRegistries().getAttributeTypeRegistry() );
             ack = new LogEntryAckMessage( message.getSequence(), Constants.OK );
         }
         catch ( Exception e )

Modified: directory/branches/trunks/schema/apacheds/mitosis/src/test/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStoreTest.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/mitosis/src/test/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStoreTest.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/mitosis/src/test/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStoreTest.java (original)
+++ directory/branches/trunks/schema/apacheds/mitosis/src/test/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStoreTest.java Mon Dec 11 11:55:02 2006
@@ -45,7 +45,7 @@
 import org.apache.directory.server.core.configuration.StartupConfiguration;
 import org.apache.directory.server.core.interceptor.InterceptorChain;
 import org.apache.directory.server.core.partition.PartitionNexus;
-import org.apache.directory.server.core.schema.global.GlobalRegistries;
+import org.apache.directory.server.core.schema.Registries;
 import org.apache.directory.shared.ldap.name.LdapDN;
 import org.apache.directory.mitosis.common.CSN;
 import org.apache.directory.mitosis.common.CSNFactory;
@@ -407,7 +407,7 @@
         }
 
 
-        public GlobalRegistries getGlobalRegistries()
+        public Registries getRegistries()
         {
             return null;
         }

Modified: directory/branches/trunks/schema/apacheds/protocol-shared/pom.xml
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/protocol-shared/pom.xml?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/protocol-shared/pom.xml (original)
+++ directory/branches/trunks/schema/apacheds/protocol-shared/pom.xml Mon Dec 11 11:55:02 2006
@@ -36,6 +36,12 @@
       <artifactId>apacheds-core</artifactId>
       <version>${pom.version}</version>
     </dependency>
+
+    <dependency>
+      <groupId>org.apache.directory.server</groupId>
+      <artifactId>apacheds-bootstrap-schema</artifactId>
+      <version>${pom.version}</version>
+    </dependency>
   </dependencies>
   <build>
     <plugins>

Modified: directory/branches/trunks/schema/apacheds/protocol-shared/src/main/java/org/apache/directory/server/protocol/shared/AbstractBackingStoreTest.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/protocol-shared/src/main/java/org/apache/directory/server/protocol/shared/AbstractBackingStoreTest.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/protocol-shared/src/main/java/org/apache/directory/server/protocol/shared/AbstractBackingStoreTest.java (original)
+++ directory/branches/trunks/schema/apacheds/protocol-shared/src/main/java/org/apache/directory/server/protocol/shared/AbstractBackingStoreTest.java Mon Dec 11 11:55:02 2006
@@ -155,7 +155,13 @@
         schemas.add( new Krb5kdcSchema() );
         schemas.add( new SystemSchema() );
         schemas.add( new ApachednsSchema() );
-        config.setBootstrapSchemas( schemas );
+
+        if ( true )
+        {
+            throw new RuntimeException( "Need to find a way to configure the use of different schemas on startup." );
+        }
+        
+        //config.setBootstrapSchemas( schemas );
 
         Set partitions = new HashSet();
         partitions.add( getExamplePartition() );

Modified: directory/branches/trunks/schema/apacheds/server-jndi/src/main/java/org/apache/directory/server/configuration/MutableServerStartupConfiguration.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/server-jndi/src/main/java/org/apache/directory/server/configuration/MutableServerStartupConfiguration.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/server-jndi/src/main/java/org/apache/directory/server/configuration/MutableServerStartupConfiguration.java (original)
+++ directory/branches/trunks/schema/apacheds/server-jndi/src/main/java/org/apache/directory/server/configuration/MutableServerStartupConfiguration.java Mon Dec 11 11:55:02 2006
@@ -102,11 +102,11 @@
     }
 
 
-    public void setBootstrapSchemas( Set arg0 )
-    {
-        super.setBootstrapSchemas( arg0 );
-    }
-
+//    public void setBootstrapSchemas( Set arg0 )
+//    {
+//        super.setBootstrapSchemas( arg0 );
+//    }
+//
 
     public void setContextPartitionConfigurations( Set arg0 )
     {

Modified: directory/branches/trunks/schema/apacheds/server-tools/src/main/java/org/apache/directory/server/tools/commands/dumpcmd/DumpCommandExecutor.java
URL: http://svn.apache.org/viewvc/directory/branches/trunks/schema/apacheds/server-tools/src/main/java/org/apache/directory/server/tools/commands/dumpcmd/DumpCommandExecutor.java?view=diff&rev=485849&r1=485848&r2=485849
==============================================================================
--- directory/branches/trunks/schema/apacheds/server-tools/src/main/java/org/apache/directory/server/tools/commands/dumpcmd/DumpCommandExecutor.java (original)
+++ directory/branches/trunks/schema/apacheds/server-tools/src/main/java/org/apache/directory/server/tools/commands/dumpcmd/DumpCommandExecutor.java Mon Dec 11 11:55:02 2006
@@ -48,7 +48,7 @@
 import org.apache.directory.server.core.partition.impl.btree.jdbm.JdbmMasterTable;
 import org.apache.directory.server.core.schema.AttributeTypeRegistry;
 import org.apache.directory.server.core.schema.bootstrap.BootstrapRegistries;
-import org.apache.directory.server.core.schema.bootstrap.BootstrapSchemaLoader;
+//import org.apache.directory.server.core.schema.bootstrap.BootstrapSchemaLoader;
 import org.apache.directory.server.tools.ToolCommandListener;
 import org.apache.directory.server.tools.execution.BaseToolCommandExecutor;
 import org.apache.directory.server.tools.util.ListenerParameter;
@@ -76,8 +76,8 @@
     public static final String INCLUDEOPERATIONAL_PARAMETER = "include-operational";
 
     private BootstrapRegistries bootstrapRegistries = new BootstrapRegistries();
-    private BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
-    private Set exclusions = new HashSet();
+    //private BootstrapSchemaLoader loader = new BootstrapSchemaLoader();
+    private Set<String> exclusions = new HashSet<String>();
     private boolean includeOperational = false;
     private String outputFile;
     private String[] partitions;
@@ -140,7 +140,14 @@
     private void execute() throws Exception
     {
         getLayout().verifyInstallation();
-        loader.load( getConfiguration().getBootstrapSchemas(), bootstrapRegistries );
+        
+        if ( true )
+        {
+            throw new RuntimeException( "Schema initialization is a bit messed up or needs to be " +
+                    "/n re-evaluated here." );
+        }
+        
+        // loader.load( getConfiguration().getBootstrapSchemas(), bootstrapRegistries );
 
         PrintWriter out = null;
         if ( excludedAttributes != null )
@@ -173,7 +180,7 @@
 
     private void processParameters( Parameter[] params )
     {
-        Map parameters = new HashMap();
+        Map<String, Object> parameters = new HashMap<String, Object>();
         for ( int i = 0; i < params.length; i++ )
         {
             Parameter parameter = params[i];
@@ -258,7 +265,7 @@
 
     private void processListeners( ListenerParameter[] listeners )
     {
-        Map parameters = new HashMap();
+        Map<String, ToolCommandListener> parameters = new HashMap<String, ToolCommandListener>();
         for ( int i = 0; i < listeners.length; i++ )
         {
             ListenerParameter parameter = listeners[i];
@@ -346,7 +353,7 @@
 
     private void filterAttributes( String dn, Attributes entry ) throws NamingException
     {
-        List toRemove = new ArrayList();
+        List<String> toRemove = new ArrayList<String>();
         AttributeTypeRegistry registry = bootstrapRegistries.getAttributeTypeRegistry();
         NamingEnumeration attrs = entry.getAll();
         while ( attrs.hasMore() )



Mime
View raw message