directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akaras...@apache.org
Subject svn commit: r582681 - in /directory/apacheds/branches/bigbang: bootstrap-plugin/src/main/java/org/apache/directory/server/core/bootstrap/plugin/ core/src/main/java/org/apache/directory/server/core/ mitosis/ mitosis/src/main/java/org/apache/directory/mi...
Date Sun, 07 Oct 2007 21:18:25 GMT
Author: akarasulu
Date: Sun Oct  7 14:18:22 2007
New Revision: 582681

URL: http://svn.apache.org/viewvc?rev=582681&view=rev
Log:
fixed breakage in mitosis tests and cleaned up some of the server.xmol

Modified:
    directory/apacheds/branches/bigbang/bootstrap-plugin/src/main/java/org/apache/directory/server/core/bootstrap/plugin/BootstrapPlugin.java
    directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
    directory/apacheds/branches/bigbang/mitosis/   (props changed)
    directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/operation/ReplaceAttributeOperation.java
    directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStore.java
    directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/SQLUtil.java
    directory/apacheds/branches/bigbang/mitosis/src/test/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStoreTest.java
    directory/apacheds/branches/bigbang/server-jndi/src/main/java/org/apache/directory/server/configuration/ApacheDS.java
    directory/apacheds/branches/bigbang/server-xml/src/main/resources/server.xml

Modified: directory/apacheds/branches/bigbang/bootstrap-plugin/src/main/java/org/apache/directory/server/core/bootstrap/plugin/BootstrapPlugin.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/bootstrap-plugin/src/main/java/org/apache/directory/server/core/bootstrap/plugin/BootstrapPlugin.java?rev=582681&r1=582680&r2=582681&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/bootstrap-plugin/src/main/java/org/apache/directory/server/core/bootstrap/plugin/BootstrapPlugin.java
(original)
+++ directory/apacheds/branches/bigbang/bootstrap-plugin/src/main/java/org/apache/directory/server/core/bootstrap/plugin/BootstrapPlugin.java
Sun Oct  7 14:18:22 2007
@@ -804,7 +804,7 @@
         ModificationItemImpl mod = new ModificationItemImpl( DirContext.ADD_ATTRIBUTE,
                 new AttributeImpl( MetaSchemaConstants.M_DISABLED_AT, "TRUE" ) );
         
-        List<ModificationItem> mods = new ArrayList<ModificationItem>();
+        List<ModificationItemImpl> mods = new ArrayList<ModificationItemImpl>();
         mods.add( mod );
         store.modify( dn, mods );
     }

Modified: directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java?rev=582681&r1=582680&r2=582681&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
(original)
+++ directory/apacheds/branches/bigbang/core/src/main/java/org/apache/directory/server/core/DefaultDirectoryService.java
Sun Oct  7 14:18:22 2007
@@ -85,6 +85,7 @@
 /**
  * Default implementation of {@link DirectoryService}.
  * 
+ * @org.apache.xbean.XBean
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
 public class DefaultDirectoryService extends DirectoryService

Propchange: directory/apacheds/branches/bigbang/mitosis/
------------------------------------------------------------------------------
--- svn:ignore (original)
+++ svn:ignore Sun Oct  7 14:18:22 2007
@@ -1,4 +1,5 @@
 *.iml
+server-work
 *.log
 target
 .classpath

Modified: directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/operation/ReplaceAttributeOperation.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/operation/ReplaceAttributeOperation.java?rev=582681&r1=582680&r2=582681&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/operation/ReplaceAttributeOperation.java
(original)
+++ directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/operation/ReplaceAttributeOperation.java
Sun Oct  7 14:18:22 2007
@@ -48,6 +48,8 @@
      * Creates a new operation that replaces the specified attribute.
      * 
      * @param attribute an attribute to replace
+     * @param csn ??
+     * @param name ??
      */
     public ReplaceAttributeOperation( CSN csn, LdapDN name, Attribute attribute )
     {

Modified: directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStore.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStore.java?rev=582681&r1=582680&r2=582681&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStore.java
(original)
+++ directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStore.java
Sun Oct  7 14:18:22 2007
@@ -58,7 +58,7 @@
     private String metadataTableName;
     private String uuidTableName;
     private String logTableName;
-    private final Set<ReplicaId> knownReplicaIds = new HashSet<ReplicaId>();
+    private Set<ReplicaId> knownReplicaIds;
     private final Object knownReplicaIdsLock = new Object();
     private final OperationCodec operationCodec = new OperationCodec();
 
@@ -86,12 +86,12 @@
     }
 
 
-    public void open( DirectoryService directoryService, ReplicationConfiguration cfg )
+    public void open( DirectoryService serviceCfg, ReplicationConfiguration cfg )
     {
         replicaId = cfg.getReplicaId();
 
         // Calculate DB URI
-        dbURI = DB_URI_PREFIX + directoryService.getWorkingDirectory().getPath() + File.separator
+        dbURI = DB_URI_PREFIX + serviceCfg.getWorkingDirectory().getPath() + File.separator
             + "replication";
 
         // Create database if not exists.
@@ -239,6 +239,7 @@
             // Get known replica IDs.
             ps = con.prepareStatement( "SELECT DISTINCT CSN_REPLICA_ID FROM " + logTableName
);
             rs = ps.executeQuery();
+            knownReplicaIds = new HashSet<ReplicaId>();
             while ( rs.next() )
             {
                 knownReplicaIds.add( new ReplicaId( rs.getString( 1 ) ) );
@@ -373,8 +374,7 @@
             }
             catch ( SQLException e1 )
             {
-                LOG.error( "Exception while rolling back attempt to put a UUID {} for dn
{}",
-                        uuid.toString(), dn.toString() );
+                LOG.error( "Failed to rollback transaction.", e );
             }
 
             throw new ReplicationStoreException( e );
@@ -459,8 +459,9 @@
         {
             synchronized ( knownReplicaIdsLock )
             {
-                knownReplicaIds.clear();
-                knownReplicaIds.add( csn.getReplicaId() );
+                Set<ReplicaId> newKnownReplicaIds = new HashSet<ReplicaId>( knownReplicaIds
);
+                newKnownReplicaIds.add( csn.getReplicaId() );
+                knownReplicaIds = newKnownReplicaIds;
             }
         }
     }
@@ -482,8 +483,8 @@
             buf.append( "WHERE " );
             for ( int i = updateVector.size();; )
             {
-                buf.append( "( CSN_REPLICA_ID = ? AND (CSN_TIMESTAMP = ? AND CSN_OP_SEQ >"
)
-                        .append( inclusive ? "=" : "" ).append( " ? OR CSN_TIMESTAMP >
?) ) " );
+                buf.append( "( CSN_REPLICA_ID = ? AND (CSN_TIMESTAMP = ? AND CSN_OP_SEQ >"
+ ( inclusive ? "=" : "" )
+                    + " ? OR CSN_TIMESTAMP > ?) ) " );
                 i--;
                 if ( i == 0 )
                 {
@@ -699,8 +700,10 @@
             ps = con.prepareStatement( "SELECT CSN_TIMESTAMP, CSN_OP_SEQ FROM " + logTableName
                 + " WHERE CSN_REPLICA_ID=? ORDER BY CSN_TIMESTAMP " + ORDER + ", CSN_OP_SEQ
" + ORDER );
 
-            for ( ReplicaId replicaId : knownReplicaIds )
+            Iterator<ReplicaId> it = knownReplicaIds.iterator();
+            while ( it.hasNext() )
             {
+                ReplicaId replicaId = it.next();
                 ps.setString( 1, replicaId.getId() );
                 rs = ps.executeQuery();
                 if ( rs.next() )

Modified: directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/SQLUtil.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/SQLUtil.java?rev=582681&r1=582680&r2=582681&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/SQLUtil.java
(original)
+++ directory/apacheds/branches/bigbang/mitosis/src/main/java/org/apache/directory/mitosis/store/derby/SQLUtil.java
Sun Oct  7 14:18:22 2007
@@ -20,6 +20,9 @@
 package org.apache.directory.mitosis.store.derby;
 
 
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
 import java.sql.Connection;
 import java.sql.ResultSet;
 import java.sql.SQLException;
@@ -28,6 +31,8 @@
 
 class SQLUtil
 {
+    private static final Logger LOG = LoggerFactory.getLogger( SQLUtil.class );
+
 
     static void cleanup( Connection con, Statement stmt, ResultSet rs )
     {
@@ -39,6 +44,7 @@
             }
             catch ( SQLException e )
             {
+                LOG.error( "Failed to close result set.", e );
             }
         }
         if ( stmt != null )
@@ -49,6 +55,7 @@
             }
             catch ( SQLException e )
             {
+                LOG.error( "Failed to close statement.", e );
             }
         }
         if ( con != null )
@@ -59,6 +66,7 @@
             }
             catch ( SQLException e )
             {
+                LOG.error( "Failed to close jdbc connection.", e );
             }
         }
     }

Modified: directory/apacheds/branches/bigbang/mitosis/src/test/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStoreTest.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/mitosis/src/test/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStoreTest.java?rev=582681&r1=582680&r2=582681&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/mitosis/src/test/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStoreTest.java
(original)
+++ directory/apacheds/branches/bigbang/mitosis/src/test/java/org/apache/directory/mitosis/store/derby/DerbyReplicationStoreTest.java
Sun Oct  7 14:18:22 2007
@@ -18,32 +18,50 @@
  *  
  */
 package org.apache.directory.mitosis.store.derby;
+ 
 
+import java.io.File;
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Set;
+
+import javax.naming.Name;
+import javax.naming.ldap.LdapName;
 
 import junit.framework.Assert;
 import junit.framework.TestCase;
+
 import org.apache.commons.io.FileUtils;
-import org.apache.directory.mitosis.common.*;
-import org.apache.directory.mitosis.common.UUID;
-import org.apache.directory.mitosis.configuration.ReplicationConfiguration;
-import org.apache.directory.mitosis.operation.*;
-import org.apache.directory.mitosis.store.ReplicationLogIterator;
-import org.apache.directory.mitosis.store.ReplicationStoreException;
 import org.apache.directory.server.core.DefaultDirectoryService;
 import org.apache.directory.shared.ldap.message.AttributeImpl;
 import org.apache.directory.shared.ldap.message.AttributesImpl;
 import org.apache.directory.shared.ldap.name.LdapDN;
-
-import javax.naming.Name;
-import javax.naming.ldap.LdapName;
-import java.io.File;
-import java.io.IOException;
-import java.util.*;
+import org.apache.directory.mitosis.common.CSN;
+import org.apache.directory.mitosis.common.CSNFactory;
+import org.apache.directory.mitosis.common.CSNVector;
+import org.apache.directory.mitosis.common.ReplicaId;
+import org.apache.directory.mitosis.common.DefaultCSN;
+import org.apache.directory.mitosis.common.DefaultCSNFactory;
+import org.apache.directory.mitosis.common.DefaultUUIDFactory;
+import org.apache.directory.mitosis.common.UUID;
+import org.apache.directory.mitosis.common.UUIDFactory;
+import org.apache.directory.mitosis.configuration.ReplicationConfiguration;
+import org.apache.directory.mitosis.operation.AddAttributeOperation;
+import org.apache.directory.mitosis.operation.AddEntryOperation;
+import org.apache.directory.mitosis.operation.CompositeOperation;
+import org.apache.directory.mitosis.operation.DeleteAttributeOperation;
+import org.apache.directory.mitosis.operation.Operation;
+import org.apache.directory.mitosis.operation.ReplaceAttributeOperation;
+import org.apache.directory.mitosis.store.ReplicationLogIterator;
+import org.apache.directory.mitosis.store.ReplicationStoreException;
 
 
 public class DerbyReplicationStoreTest extends TestCase
 {
-    private static final ReplicaId TEST_REPLICA_ID = new ReplicaId( "TEST_REPLICA" );
+    private static final ReplicaId REPLICA_ID = new ReplicaId( "TEST_REPLICA" );
     private static final ReplicaId OTHER_REPLICA_ID = new ReplicaId( "OTHER_REPLICA" );
     private static final ReplicaId OTHER_REPLICA_ID_2 = new ReplicaId( "OTHER_REPLICA_2"
);
     private static final File DB_PATH = new File( "target/testDB" );
@@ -58,7 +76,7 @@
     public void setUp() throws Exception
     {
         dropDatabase();
-        startupDatabase( TEST_REPLICA_ID );
+        startupDatabase( REPLICA_ID );
         initStopWatch();
     }
 
@@ -72,7 +90,9 @@
         // Open store
         store = new DerbyReplicationStore();
         store.setTablePrefix( "TEST_" );
-        store.open( new DefaultDirectoryService(), cfg );
+        DefaultDirectoryService service = new DefaultDirectoryService();
+        service.setWorkingDirectory( DB_PATH );
+        store.open( service, cfg );
     }
 
 
@@ -85,7 +105,6 @@
 
     private void dropDatabase() throws IOException
     {
-        FileUtils.deleteDirectory( new File( new DefaultDirectoryService().getWorkingDirectory().getPath(),
"replication" ) );
         FileUtils.deleteDirectory( DB_PATH );
         File logFile = new File( "derby.log" );
         if ( !logFile.delete() )
@@ -122,9 +141,8 @@
         }
         catch ( ReplicationStoreException e )
         {
-            assertNotNull( e );
         }
-        startupDatabase( TEST_REPLICA_ID );
+        startupDatabase( REPLICA_ID );
     }
 
 
@@ -144,10 +162,10 @@
     {
         ReplicationLogIterator it;
 
-        it = store.getLogs( csnFactory.newInstance( TEST_REPLICA_ID ), true );
+        it = store.getLogs( csnFactory.newInstance( REPLICA_ID ), true );
         Assert.assertFalse( it.next() );
         it.close();
-        it = store.getLogs( csnFactory.newInstance( TEST_REPLICA_ID ), false );
+        it = store.getLogs( csnFactory.newInstance( REPLICA_ID ), false );
         Assert.assertFalse( it.next() );
         it.close();
         it = store.getLogs( csnFactory.newInstance( OTHER_REPLICA_ID ), true );
@@ -163,7 +181,7 @@
 
     private void subTestWriteLog() throws Exception
     {
-        CSN csn = csnFactory.newInstance( TEST_REPLICA_ID );
+        CSN csn = csnFactory.newInstance( REPLICA_ID );
         CompositeOperation op1 = new CompositeOperation( csn );
         op1.add( new AddEntryOperation( csn, new LdapDN( "ou=a" ), new AttributesImpl( true
) ) );
         op1.add( new AddAttributeOperation( csn, new LdapDN( "ou=a" ), new AttributeImpl(
"id", "valie" ) ) );
@@ -184,7 +202,7 @@
         testGetLogs( csn, op2 );
 
         Assert.assertEquals( 2, store.getLogSize() );
-        Assert.assertEquals( 1, store.getLogSize( TEST_REPLICA_ID ) );
+        Assert.assertEquals( 1, store.getLogSize( REPLICA_ID ) );
         Assert.assertEquals( 1, store.getLogSize( OTHER_REPLICA_ID ) );
 
         // Test getLogs(CSNVector, true)
@@ -193,12 +211,15 @@
         expected.add( op2 );
         CSNVector updateVector = new CSNVector();
         testGetLogs( updateVector, true, expected );
+
         updateVector = new CSNVector();
         updateVector.setCSN( op1.getCSN() );
         testGetLogs( updateVector, true, expected );
+        
         updateVector = new CSNVector();
         updateVector.setCSN( op2.getCSN() );
         testGetLogs( updateVector, true, expected );
+        
         updateVector = new CSNVector();
         updateVector.setCSN( op1.getCSN() );
         updateVector.setCSN( op2.getCSN() );
@@ -233,14 +254,14 @@
         CSN csn;
         ReplicationLogIterator it;
 
-        it = store.getLogs( new DefaultCSN( 0, TEST_REPLICA_ID, 0 ), false );
+        it = store.getLogs( new DefaultCSN( 0, REPLICA_ID, 0 ), false );
         it.next();
         csn = it.getOperation().getCSN();
         it.close();
 
         Assert.assertEquals( 0, store.removeLogs( csn, false ) );
         Assert.assertEquals( 1, store.removeLogs( csn, true ) );
-        Assert.assertEquals( 0, store.getLogSize( TEST_REPLICA_ID ) );
+        Assert.assertEquals( 0, store.getLogSize( REPLICA_ID ) );
 
         it = store.getLogs( new DefaultCSN( 0, OTHER_REPLICA_ID, 0 ), false );
         Assert.assertTrue( it.next() );
@@ -257,8 +278,8 @@
 
     private void subTestVectors() throws Exception
     {
-        CSN csnA = new DefaultCSN( 0, TEST_REPLICA_ID, 0 );
-        CSN csnB = new DefaultCSN( 1, TEST_REPLICA_ID, 0 );
+        CSN csnA = new DefaultCSN( 0, REPLICA_ID, 0 );
+        CSN csnB = new DefaultCSN( 1, REPLICA_ID, 0 );
         CSN csnC = new DefaultCSN( 0, OTHER_REPLICA_ID_2, 0 );
         CSN csnD = new DefaultCSN( 0, OTHER_REPLICA_ID_2, 1 );
         store.putLog( new Operation( csnA ) );
@@ -267,7 +288,7 @@
         store.putLog( new Operation( csnD ) );
 
         Set<ReplicaId> expectedKnownReplicaIds = new HashSet<ReplicaId>();
-        expectedKnownReplicaIds.add( TEST_REPLICA_ID );
+        expectedKnownReplicaIds.add( REPLICA_ID );
         expectedKnownReplicaIds.add( OTHER_REPLICA_ID );
         expectedKnownReplicaIds.add( OTHER_REPLICA_ID_2 );
 
@@ -295,12 +316,10 @@
     }
 
 
-    private void testGetLogs( CSN csn, List operations )
+    private void testGetLogs( CSN csn, List<Operation> operations )
     {
-        Iterator it = operations.iterator();
-        ReplicationLogIterator rit;
-
-        rit = store.getLogs( csn, true );
+        Iterator<Operation> it = operations.iterator();
+        ReplicationLogIterator rit = store.getLogs( csn, true );
         testGetLogs( it, rit );
 
         rit = store.getLogs( csn, false );
@@ -309,21 +328,19 @@
     }
 
 
-    private void testGetLogs( CSNVector updateVector, boolean inclusive, List operations
)
+    private void testGetLogs( CSNVector updateVector, boolean inclusive, List<Operation>
operations )
     {
-        Iterator it = operations.iterator();
-        ReplicationLogIterator rit;
-
-        rit = store.getLogs( updateVector, inclusive );
+        Iterator<Operation> it = operations.iterator();
+        ReplicationLogIterator rit = store.getLogs( updateVector, inclusive );
         testGetLogs( it, rit );
     }
 
 
-    private void testGetLogs( Iterator expectedIt, ReplicationLogIterator actualIt )
+    private void testGetLogs( Iterator<Operation> expectedIt, ReplicationLogIterator
actualIt )
     {
         while ( expectedIt.hasNext() )
         {
-            Operation expected = ( Operation ) expectedIt.next();
+            Operation expected = expectedIt.next();
             Assert.assertTrue( actualIt.next() );
 
             Operation actual = actualIt.getOperation();
@@ -353,4 +370,4 @@
     {
         Assert.assertEquals( expected.toString(), actual.toString() );
     }
-}
+}
\ No newline at end of file

Modified: directory/apacheds/branches/bigbang/server-jndi/src/main/java/org/apache/directory/server/configuration/ApacheDS.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/server-jndi/src/main/java/org/apache/directory/server/configuration/ApacheDS.java?rev=582681&r1=582680&r2=582681&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/server-jndi/src/main/java/org/apache/directory/server/configuration/ApacheDS.java
(original)
+++ directory/apacheds/branches/bigbang/server-jndi/src/main/java/org/apache/directory/server/configuration/ApacheDS.java
Sun Oct  7 14:18:22 2007
@@ -80,6 +80,7 @@
 /**
  * Apache Directory Server top level.
  *
+ * @org.apache.xbean.XBean
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  * @version $Rev$
  */

Modified: directory/apacheds/branches/bigbang/server-xml/src/main/resources/server.xml
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/bigbang/server-xml/src/main/resources/server.xml?rev=582681&r1=582680&r2=582681&view=diff
==============================================================================
--- directory/apacheds/branches/bigbang/server-xml/src/main/resources/server.xml (original)
+++ directory/apacheds/branches/bigbang/server-xml/src/main/resources/server.xml Sun Oct 
7 14:18:22 2007
@@ -16,240 +16,243 @@
     </property>
   </bean>
 
-
-  <mutableServerStartupConfiguration id="configuration" xmlns="http://apacheds.org/config/1.0"
-                                     workingDirectory="example.com"
+  <apacheDS id="defaultApacheDS" xmlns="http://apacheds.org/config/1.0"
                                      synchPeriodMillis="15000"
                                      maxThreads="8"
-                                     allowAnonymousAccess="false"
-                                     accessControlEnabled="false"
-                                     denormalizeOpAttrsEnabled="false"
-          >
-
-    <changePasswordConfiguration>
-      <changePasswordConfiguration
-              enabled="false"
-              ipPort="464">
+                                     allowAnonymousAccess="false">
+
+      <defaultDirectoryService id="defaultDirectoryService"
+                                         instanceId="default"
+                                         workingDirectory="example.com"
+                                         allowAnonymousAccess="false"
+                                         accessControlEnabled="false"
+                                         denormalizeOpAttrsEnabled="false"
+              >
+        <systemPartition>
+          <!-- use the following partitionConfiguration to override defaults for -->
+          <!-- the system partition                                              -->
+
+          <jdbmPartition
+            id="system"
+            cacheSize="100"
+            suffix="ou=system"
+            optimizerEnabled="true"
+            syncOnWrite="true">
+            <indexedAttributes>
+                <jdbmIndex
+                  attributeId="1.3.6.1.4.1.18060.0.4.1.2.1"
+                  cacheSize="100"/>
+                <jdbmIndex
+                  attributeId="1.3.6.1.4.1.18060.0.4.1.2.2"
+                  cacheSize="100"/>
+                <jdbmIndex
+                  attributeId="1.3.6.1.4.1.18060.0.4.1.2.3"
+                  cacheSize="100"/>
+                <jdbmIndex
+                  attributeId="1.3.6.1.4.1.18060.0.4.1.2.4"
+                  cacheSize="100"/>
+                <jdbmIndex
+                  attributeId="1.3.6.1.4.1.18060.0.4.1.2.5"
+                  cacheSize="10"/>
+                <jdbmIndex
+                  attributeId="1.3.6.1.4.1.18060.0.4.1.2.6"
+                  cacheSize="10"/>
+                <jdbmIndex
+                  attributeId="1.3.6.1.4.1.18060.0.4.1.2.7"
+                  cacheSize="10"/>
+                <jdbmIndex
+                  attributeId="ou"
+                  cacheSize="100"/>
+                <jdbmIndex
+                  attributeId="uid"
+                  cacheSize="100"/>
+                <jdbmIndex
+                  attributeId="objectClass"
+                  cacheSize="100"/>
+            </indexedAttributes>
+            <contextEntry>
+              <value xmlns="http://www.springframework.org/schema/beans">
+                objectClass: top
+                objectClass: organizationalUnit
+                objectClass: extensibleObject
+                ou: system
+              </value>
+            </contextEntry>
+          </jdbmPartition>
+        </systemPartition>
+
+        <partitions>
+          <jdbmPartition
+            id="example"
+            cacheSize="100"
+            suffix="dc=example,dc=com"
+            optimizerEnabled="true"
+            syncOnWrite="true">
+            <indexedAttributes>
+                <jdbmIndex
+                  attributeId="1.3.6.1.4.1.18060.0.4.1.2.1"
+                  cacheSize="100"/>
+                <jdbmIndex
+                  attributeId="1.3.6.1.4.1.18060.0.4.1.2.2"
+                  cacheSize="100"/>
+                <jdbmIndex
+                  attributeId="1.3.6.1.4.1.18060.0.4.1.2.3"
+                  cacheSize="100"/>
+                <jdbmIndex
+                  attributeId="1.3.6.1.4.1.18060.0.4.1.2.4"
+                  cacheSize="100"/>
+                <jdbmIndex
+                  attributeId="1.3.6.1.4.1.18060.0.4.1.2.5"
+                  cacheSize="10"/>
+                <jdbmIndex
+                  attributeId="1.3.6.1.4.1.18060.0.4.1.2.6"
+                  cacheSize="10"/>
+                <jdbmIndex
+                  attributeId="1.3.6.1.4.1.18060.0.4.1.2.7"
+                  cacheSize="10"/>
+                <jdbmIndex
+                  attributeId="dc"
+                  cacheSize="100"/>
+                <jdbmIndex
+                  attributeId="ou"
+                  cacheSize="100"/>
+                <jdbmIndex
+                  attributeId="krb5PrincipalName"
+                  cacheSize="100"/>
+                <jdbmIndex
+                  attributeId="uid"
+                  cacheSize="100"/>
+                <jdbmIndex
+                  attributeId="objectClass"
+                  cacheSize="100"/>
+            </indexedAttributes>
+            <contextEntry>
+              <value xmlns="http://www.springframework.org/schema/beans">
+                objectClass: top
+                objectClass: domain
+                objectClass: extensibleObject
+                dc: example
+              </value>
+            </contextEntry>
+          </jdbmPartition>
+        </partitions>
+
+        <interceptors>
+          <normalizationService/>
+          <authenticationService/>
+          <referralService/>
+          <authorizationService/>
+          <defaultAuthorizationService/>
+          <exceptionService/>
+          <operationalAttributeService/>
+
+          <!-- Uncomment to enable the password policy service
+          <passwordPolicyService/>
+          <keyDerivationService/>
+          -->
+
+          <schemaService/>
+          <subentryService/>
+          <collectiveAttributeService/>
+          <eventService/>
+          <triggerService/>
+
+          <!-- Uncomment to enable replication service
+          <replicationService >
+            <configuration>
+              <replicationConfiguration
+                serverPort="10390"
+                peerReplicas="instance_b@localhost:10392">
+                <replicaId>
+                  <replicaId id="instance_a"/>
+                </replicaId>
+              </replicationConfiguration>
+            </configuration>
+          </replicationService>
+          -->
+
+        </interceptors>
+      </defaultDirectoryService>
+
+
+      <changePasswordConfiguration>
+        <changePasswordConfiguration
+                enabled="false"
+                ipPort="464">
+        </changePasswordConfiguration>
       </changePasswordConfiguration>
-    </changePasswordConfiguration>
 
-    <ntpConfiguration>
-      <ntpConfiguration
-              enabled="false"
-              ipPort="123">
+      <ntpConfiguration>
+        <ntpConfiguration
+                enabled="false"
+                ipPort="123">
+        </ntpConfiguration>
       </ntpConfiguration>
-    </ntpConfiguration>
 
-    <dnsConfiguration>
-      <dnsConfiguration
-              enabled="false"
-              ipPort="53">
+      <dnsConfiguration>
+        <dnsConfiguration
+                enabled="false"
+                ipPort="53">
+        </dnsConfiguration>
       </dnsConfiguration>
-    </dnsConfiguration>
 
-    <kdcConfiguration>
-      <kdcConfiguration
-              enabled="false"
-              ipPort="88">
+      <kdcConfiguration>
+        <kdcConfiguration
+                enabled="false"
+                ipPort="88">
+        </kdcConfiguration>
       </kdcConfiguration>
-    </kdcConfiguration>
-
-    <ldapsConfiguration>
-      <ldapConfiguration id="ldapsConfiguration"
-                         enabled="false"
-                         ipPort="636"
-                         enableLdaps="true">
-      </ldapConfiguration>
-    </ldapsConfiguration>
 
-    <ldapConfiguration>
-      <ldapConfiguration id="ldapConfiguration"
-              ipPort="10389"
-              allowAnonymousAccess="false"
-              saslHost="ldap.example.com"
-              saslPrincipal="ldap/ldap.example.com@EXAMPLE.COM"
-              searchBaseDn="ou=users,ou=system"
-              maxTimeLimit="15000"
-              maxSizeLimit="1000">
-
-        <!-- The list of supported authentication mechanisms.                   -->
-        <supportedMechanisms>
-          <value xmlns="http://www.springframework.org/schema/beans">SIMPLE</value>
-          <value xmlns="http://www.springframework.org/schema/beans">CRAM-MD5</value>
-          <value xmlns="http://www.springframework.org/schema/beans">DIGEST-MD5</value>
-          <!--<value xmlns="http://www.springframework.org/schema/beans">GSSAPI</value>-->
-        </supportedMechanisms>
-
-        <!-- The desired quality-of-protection, used by DIGEST-MD5 and GSSAPI.  -->
-        <saslQop>
-          <value xmlns="http://www.springframework.org/schema/beans">auth</value>
-          <value xmlns="http://www.springframework.org/schema/beans">auth-int</value>
-          <value xmlns="http://www.springframework.org/schema/beans">auth-conf</value>
-        </saslQop>
-
-        <!-- The realms serviced by this SASL host, used by DIGEST-MD5 and GSSAPI. -->
-        <saslRealms>
-          <value xmlns="http://www.springframework.org/schema/beans">example.com</value>
-          <value xmlns="http://www.springframework.org/schema/beans">apache.org</value>
-        </saslRealms>
-
-        <!-- the collection of extended operation handlers to install           -->
-        <extendedOperationHandlers>
-          <!--startTlsHandler/-->
-          <gracefulShutdownHandler/>
-          <launchDiagnosticUiHandler/>
-          <!-- The Stored Procedure Extended Operation is not stable yet and it may cause
security risks.-->
-          <!--storedProcedureExtendedOperationHandler/-->
-        </extendedOperationHandlers>
+      <ldapsConfiguration>
+        <ldapConfiguration id="ldapsConfiguration"
+                           enabled="false"
+                           ipPort="636"
+                           enableLdaps="true">
+        </ldapConfiguration>
+      </ldapsConfiguration>
+
+      <ldapConfiguration>
+        <ldapConfiguration id="ldapConfiguration"
+                ipPort="10389"
+                allowAnonymousAccess="false"
+                saslHost="ldap.example.com"
+                saslPrincipal="ldap/ldap.example.com@EXAMPLE.COM"
+                searchBaseDn="ou=users,ou=system"
+                maxTimeLimit="15000"
+                maxSizeLimit="1000">
+
+          <!-- The list of supported authentication mechanisms.                   -->
+          <supportedMechanisms>
+            <value xmlns="http://www.springframework.org/schema/beans">SIMPLE</value>
+            <value xmlns="http://www.springframework.org/schema/beans">CRAM-MD5</value>
+            <value xmlns="http://www.springframework.org/schema/beans">DIGEST-MD5</value>
+            <!--<value xmlns="http://www.springframework.org/schema/beans">GSSAPI</value>-->
+          </supportedMechanisms>
+
+          <!-- The desired quality-of-protection, used by DIGEST-MD5 and GSSAPI.  -->
+          <saslQop>
+            <value xmlns="http://www.springframework.org/schema/beans">auth</value>
+            <value xmlns="http://www.springframework.org/schema/beans">auth-int</value>
+            <value xmlns="http://www.springframework.org/schema/beans">auth-conf</value>
+          </saslQop>
+
+          <!-- The realms serviced by this SASL host, used by DIGEST-MD5 and GSSAPI. -->
+          <saslRealms>
+            <value xmlns="http://www.springframework.org/schema/beans">example.com</value>
+            <value xmlns="http://www.springframework.org/schema/beans">apache.org</value>
+          </saslRealms>
+
+          <!-- the collection of extended operation handlers to install           -->
+          <extendedOperationHandlers>
+            <!--startTlsHandler/-->
+            <gracefulShutdownHandler/>
+            <launchDiagnosticUiHandler/>
+            <!-- The Stored Procedure Extended Operation is not stable yet and it may
cause security risks.-->
+            <!--storedProcedureExtendedOperationHandler/-->
+          </extendedOperationHandlers>
+        </ldapConfiguration>
       </ldapConfiguration>
-    </ldapConfiguration>
-
-    <systemPartition>
-      <!-- use the following partitionConfiguration to override defaults for -->
-      <!-- the system partition                                              -->
-
-      <jdbmPartition 
-        id="system"
-        cacheSize="100"
-        suffix="ou=system"
-        optimizerEnabled="true"
-        syncOnWrite="true">
-        <indexedAttributes>
-            <jdbmIndex
-              attributeId="1.3.6.1.4.1.18060.0.4.1.2.1"
-              cacheSize="100"/>
-            <jdbmIndex
-              attributeId="1.3.6.1.4.1.18060.0.4.1.2.2"
-              cacheSize="100"/>
-            <jdbmIndex
-              attributeId="1.3.6.1.4.1.18060.0.4.1.2.3"
-              cacheSize="100"/>
-            <jdbmIndex
-              attributeId="1.3.6.1.4.1.18060.0.4.1.2.4"
-              cacheSize="100"/>
-            <jdbmIndex
-              attributeId="1.3.6.1.4.1.18060.0.4.1.2.5"
-              cacheSize="10"/>
-            <jdbmIndex
-              attributeId="1.3.6.1.4.1.18060.0.4.1.2.6"
-              cacheSize="10"/>
-            <jdbmIndex
-              attributeId="1.3.6.1.4.1.18060.0.4.1.2.7"
-              cacheSize="10"/>
-            <jdbmIndex
-              attributeId="ou"
-              cacheSize="100"/>
-            <jdbmIndex
-              attributeId="uid"
-              cacheSize="100"/>
-            <jdbmIndex
-              attributeId="objectClass"
-              cacheSize="100"/>
-        </indexedAttributes>
-        <contextEntry>
-          <value xmlns="http://www.springframework.org/schema/beans">
-            objectClass: top
-            objectClass: organizationalUnit
-            objectClass: extensibleObject
-            ou: system
-          </value>
-        </contextEntry>
-      </jdbmPartition>
-    </systemPartition>
-
-    <partitions>
-      <jdbmPartition 
-        id="example"
-        cacheSize="100"
-        suffix="dc=example,dc=com"
-        optimizerEnabled="true"
-        syncOnWrite="true">
-        <indexedAttributes>
-            <jdbmIndex
-              attributeId="1.3.6.1.4.1.18060.0.4.1.2.1"
-              cacheSize="100"/>
-            <jdbmIndex
-              attributeId="1.3.6.1.4.1.18060.0.4.1.2.2"
-              cacheSize="100"/>
-            <jdbmIndex
-              attributeId="1.3.6.1.4.1.18060.0.4.1.2.3"
-              cacheSize="100"/>
-            <jdbmIndex
-              attributeId="1.3.6.1.4.1.18060.0.4.1.2.4"
-              cacheSize="100"/>
-            <jdbmIndex
-              attributeId="1.3.6.1.4.1.18060.0.4.1.2.5"
-              cacheSize="10"/>
-            <jdbmIndex
-              attributeId="1.3.6.1.4.1.18060.0.4.1.2.6"
-              cacheSize="10"/>
-            <jdbmIndex
-              attributeId="1.3.6.1.4.1.18060.0.4.1.2.7"
-              cacheSize="10"/>
-            <jdbmIndex
-              attributeId="dc"
-              cacheSize="100"/>
-            <jdbmIndex
-              attributeId="ou"
-              cacheSize="100"/>
-            <jdbmIndex
-              attributeId="krb5PrincipalName"
-              cacheSize="100"/>
-            <jdbmIndex
-              attributeId="uid"
-              cacheSize="100"/>
-            <jdbmIndex
-              attributeId="objectClass"
-              cacheSize="100"/>
-        </indexedAttributes>
-        <contextEntry>
-          <value xmlns="http://www.springframework.org/schema/beans">
-            objectClass: top
-            objectClass: domain
-            objectClass: extensibleObject
-            dc: example
-          </value>
-        </contextEntry>
-      </jdbmPartition>
-    </partitions>
-
-    <interceptors>
-      <normalizationService/>
-      <authenticationService/>
-      <referralService/>
-      <authorizationService/>
-      <defaultAuthorizationService/>
-      <exceptionService/>
-      <operationalAttributeService/>
-
-      <!-- Uncomment to enable the password policy service
-      <passwordPolicyService/>
-      <keyDerivationService/>
-      -->
-
-      <schemaService/>
-      <subentryService/>
-      <collectiveAttributeService/>
-      <eventService/>
-      <triggerService/>
-
-      <!-- Uncomment to enable replication service
-      <replicationService >
-        <configuration>
-          <replicationConfiguration
-            serverPort="10390"
-            peerReplicas="instance_b@localhost:10392">
-            <replicaId>
-              <replicaId id="instance_a"/>
-            </replicaId>
-          </replicationConfiguration>
-        </configuration>
-      </replicationService>
-      -->
-
-    </interceptors>
-  </mutableServerStartupConfiguration>
-
+  </apacheDS>
 
 <!-- another bean I didn't convert -->
   <bean class="org.springframework.beans.factory.config.CustomEditorConfigurer">



Mime
View raw message