directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From elecha...@apache.org
Subject svn commit: r1378653 [2/5] - in /directory: apacheds/branches/apacheds-mvbt/core-annotations/src/main/java/org/apache/directory/server/core/factory/ apacheds/branches/apacheds-mvbt/core-api/src/main/java/org/apache/directory/server/core/api/partition/ ...
Date Wed, 29 Aug 2012 17:13:59 GMT
Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/AbstractBTreePartition.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/AbstractBTreePartition.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/AbstractBTreePartition.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/AbstractBTreePartition.java Wed Aug 29 17:13:56 2012
@@ -29,7 +29,6 @@ import java.util.HashSet;
 import java.util.Iterator;
 import java.util.Map;
 import java.util.Set;
-import java.util.UUID;
 import java.util.concurrent.atomic.AtomicBoolean;
 
 import org.apache.directory.server.constants.ApacheSchemaConstants;
@@ -122,46 +121,46 @@ public abstract class AbstractBTreeParti
     protected AtomicBoolean isSyncOnWrite = new AtomicBoolean( true );
 
     /** The suffix UUID */
-    private volatile UUID suffixId;
+    private volatile String suffixId;
 
     /** The path in which this Partition stores files */
     protected URI partitionPath;
 
     /** The set of indexed attributes */
-    private Set<Index<?, Entry, UUID>> indexedAttributes;
+    private Set<Index<?, Entry, String>> indexedAttributes;
 
     /** the master table storing entries by primary key */
     protected MasterTable<Entry> master;
 
     /** a map of attributeType numeric UUID to user userIndices */
-    protected Map<String, Index<?, Entry, UUID>> userIndices = new HashMap<String, Index<?, Entry, UUID>>();
+    protected Map<String, Index<?, Entry, String>> userIndices = new HashMap<String, Index<?, Entry, String>>();
 
     /** a map of attributeType numeric UUID to system userIndices */
-    protected Map<String, Index<?, Entry, UUID>> systemIndices = new HashMap<String, Index<?, Entry, UUID>>();
+    protected Map<String, Index<?, Entry, String>> systemIndices = new HashMap<String, Index<?, Entry, String>>();
 
     /** the relative distinguished name index */
-    protected Index<ParentIdAndRdn, Entry, UUID> rdnIdx;
+    protected Index<ParentIdAndRdn, Entry, String> rdnIdx;
 
     /** a system index on objectClass attribute*/
-    protected Index<String, Entry, UUID> objectClassIdx;
+    protected Index<String, Entry, String> objectClassIdx;
 
     /** the attribute presence index */
-    protected Index<String, Entry, UUID> presenceIdx;
+    protected Index<String, Entry, String> presenceIdx;
 
     /** a system index on entryUUID attribute */
-    protected Index<UUID, Entry, UUID> entryUuidIdx;
+    protected Index<String, Entry, String> entryUuidIdx;
 
     /** a system index on entryCSN attribute */
-    protected Index<String, Entry, UUID> entryCsnIdx;
+    protected Index<String, Entry, String> entryCsnIdx;
 
     /** a system index on aliasedObjectName attribute */
-    protected Index<String, Entry, UUID> aliasIdx;
+    protected Index<String, Entry, String> aliasIdx;
 
     /** the subtree scope alias index */
-    protected Index<UUID, Entry, UUID> subAliasIdx;
+    protected Index<String, Entry, String> subAliasIdx;
 
     /** the one level scope alias index */
-    protected Index<UUID, Entry, UUID> oneAliasIdx;
+    protected Index<String, Entry, String> oneAliasIdx;
 
     /** Cached attributes types to avoid lookup all over the code */
     protected AttributeType OBJECT_CLASS_AT;
@@ -187,7 +186,7 @@ public abstract class AbstractBTreeParti
     {
         this.schemaManager = schemaManager;
 
-        indexedAttributes = new HashSet<Index<?, Entry, UUID>>();
+        indexedAttributes = new HashSet<Index<?, Entry, String>>();
 
         // Initialize Attribute types used all over this method
         OBJECT_CLASS_AT = schemaManager.getAttributeType( SchemaConstants.OBJECT_CLASS_AT );
@@ -285,14 +284,14 @@ public abstract class AbstractBTreeParti
         // add missing system indices
         if ( getPresenceIndex() == null )
         {
-            Index<String, Entry, UUID> index = createSystemIndex( ApacheSchemaConstants.APACHE_PRESENCE_AT_OID,
+            Index<String, Entry, String> index = createSystemIndex( ApacheSchemaConstants.APACHE_PRESENCE_AT_OID,
                 partitionPath, NO_REVERSE );
             addIndex( index );
         }
 
         if ( getRdnIndex() == null )
         {
-            Index<ParentIdAndRdn, Entry, UUID> index = createSystemIndex(
+            Index<ParentIdAndRdn, Entry, String> index = createSystemIndex(
                 ApacheSchemaConstants.APACHE_RDN_AT_OID,
                 partitionPath, WITH_REVERSE );
             addIndex( index );
@@ -300,42 +299,42 @@ public abstract class AbstractBTreeParti
 
         if ( getAliasIndex() == null )
         {
-            Index<String, Entry, UUID> index = createSystemIndex( ApacheSchemaConstants.APACHE_ALIAS_AT_OID,
+            Index<String, Entry, String> index = createSystemIndex( ApacheSchemaConstants.APACHE_ALIAS_AT_OID,
                 partitionPath, WITH_REVERSE );
             addIndex( index );
         }
 
         if ( getOneAliasIndex() == null )
         {
-            Index<UUID, Entry, UUID> index = createSystemIndex( ApacheSchemaConstants.APACHE_ONE_ALIAS_AT_OID,
+            Index<String, Entry, String> index = createSystemIndex( ApacheSchemaConstants.APACHE_ONE_ALIAS_AT_OID,
                 partitionPath, WITH_REVERSE );
             addIndex( index );
         }
 
         if ( getSubAliasIndex() == null )
         {
-            Index<UUID, Entry, UUID> index = createSystemIndex( ApacheSchemaConstants.APACHE_SUB_ALIAS_AT_OID,
+            Index<String, Entry, String> index = createSystemIndex( ApacheSchemaConstants.APACHE_SUB_ALIAS_AT_OID,
                 partitionPath, WITH_REVERSE );
             addIndex( index );
         }
 
         if ( getObjectClassIndex() == null )
         {
-            Index<String, Entry, UUID> index = createSystemIndex( SchemaConstants.OBJECT_CLASS_AT_OID, partitionPath,
+            Index<String, Entry, String> index = createSystemIndex( SchemaConstants.OBJECT_CLASS_AT_OID, partitionPath,
                 NO_REVERSE );
             addIndex( index );
         }
 
         if ( getEntryUuidIndex() == null )
         {
-            Index<UUID, Entry, UUID> index = createSystemIndex( SchemaConstants.ENTRY_UUID_AT_OID, partitionPath,
+            Index<String, Entry, String> index = createSystemIndex( SchemaConstants.ENTRY_UUID_AT_OID, partitionPath,
                 NO_REVERSE );
             addIndex( index );
         }
 
         if ( getEntryCsnIndex() == null )
         {
-            Index<String, Entry, UUID> index = createSystemIndex( SchemaConstants.ENTRY_CSN_AT_OID, partitionPath,
+            Index<String, Entry, String> index = createSystemIndex( SchemaConstants.ENTRY_CSN_AT_OID, partitionPath,
                 NO_REVERSE );
             addIndex( index );
         }
@@ -343,21 +342,23 @@ public abstract class AbstractBTreeParti
         // convert and initialize system indices
         for ( String oid : systemIndices.keySet() )
         {
-            Index<?, Entry, UUID> index = systemIndices.get( oid );
+            Index<?, Entry, String> index = systemIndices.get( oid );
             index = convertAndInit( index );
             systemIndices.put( oid, index );
         }
 
         // set index shortcuts
-        rdnIdx = ( Index<ParentIdAndRdn, Entry, UUID> ) systemIndices
+        rdnIdx = ( Index<ParentIdAndRdn, Entry, String> ) systemIndices
             .get( ApacheSchemaConstants.APACHE_RDN_AT_OID );
-        presenceIdx = ( Index<String, Entry, UUID> ) systemIndices.get( ApacheSchemaConstants.APACHE_PRESENCE_AT_OID );
-        aliasIdx = ( Index<String, Entry, UUID> ) systemIndices.get( ApacheSchemaConstants.APACHE_ALIAS_AT_OID );
-        oneAliasIdx = ( Index<UUID, Entry, UUID> ) systemIndices.get( ApacheSchemaConstants.APACHE_ONE_ALIAS_AT_OID );
-        subAliasIdx = ( Index<UUID, Entry, UUID> ) systemIndices.get( ApacheSchemaConstants.APACHE_SUB_ALIAS_AT_OID );
-        objectClassIdx = ( Index<String, Entry, UUID> ) systemIndices.get( SchemaConstants.OBJECT_CLASS_AT_OID );
-        entryUuidIdx = ( Index<UUID, Entry, UUID> ) systemIndices.get( SchemaConstants.ENTRY_UUID_AT_OID );
-        entryCsnIdx = ( Index<String, Entry, UUID> ) systemIndices.get( SchemaConstants.ENTRY_CSN_AT_OID );
+        presenceIdx = ( Index<String, Entry, String> ) systemIndices.get( ApacheSchemaConstants.APACHE_PRESENCE_AT_OID );
+        aliasIdx = ( Index<String, Entry, String> ) systemIndices.get( ApacheSchemaConstants.APACHE_ALIAS_AT_OID );
+        oneAliasIdx = ( Index<String, Entry, String> ) systemIndices
+            .get( ApacheSchemaConstants.APACHE_ONE_ALIAS_AT_OID );
+        subAliasIdx = ( Index<String, Entry, String> ) systemIndices
+            .get( ApacheSchemaConstants.APACHE_SUB_ALIAS_AT_OID );
+        objectClassIdx = ( Index<String, Entry, String> ) systemIndices.get( SchemaConstants.OBJECT_CLASS_AT_OID );
+        entryUuidIdx = ( Index<String, Entry, String> ) systemIndices.get( SchemaConstants.ENTRY_UUID_AT_OID );
+        entryCsnIdx = ( Index<String, Entry, String> ) systemIndices.get( SchemaConstants.ENTRY_CSN_AT_OID );
     }
 
 
@@ -367,7 +368,7 @@ public abstract class AbstractBTreeParti
     protected void setupUserIndices() throws Exception
     {
         // convert and initialize system indices
-        Map<String, Index<?, Entry, UUID>> tmp = new HashMap<String, Index<?, Entry, UUID>>();
+        Map<String, Index<?, Entry, String>> tmp = new HashMap<String, Index<?, Entry, String>>();
 
         for ( String oid : userIndices.keySet() )
         {
@@ -377,7 +378,7 @@ public abstract class AbstractBTreeParti
 
             if ( mr != null )
             {
-                Index<?, Entry, UUID> index = userIndices.get( oid );
+                Index<?, Entry, String> index = userIndices.get( oid );
                 index = convertAndInit( index );
                 tmp.put( oid, index );
             }
@@ -413,7 +414,7 @@ public abstract class AbstractBTreeParti
      * @return the converted and initialized index
      * @throws Exception
      */
-    protected abstract Index<?, Entry, UUID> convertAndInit( Index<?, Entry, UUID> index ) throws Exception;
+    protected abstract Index<?, Entry, String> convertAndInit( Index<?, Entry, String> index ) throws Exception;
 
 
     /**
@@ -447,7 +448,7 @@ public abstract class AbstractBTreeParti
 
         MultiException errors = new MultiException( I18n.err( I18n.ERR_577 ) );
 
-        for ( Index<?, Entry, UUID> index : userIndices.values() )
+        for ( Index<?, Entry, String> index : userIndices.values() )
         {
             try
             {
@@ -461,7 +462,7 @@ public abstract class AbstractBTreeParti
             }
         }
 
-        for ( Index<?, Entry, UUID> index : systemIndices.values() )
+        for ( Index<?, Entry, String> index : systemIndices.values() )
         {
             try
             {
@@ -534,18 +535,18 @@ public abstract class AbstractBTreeParti
     }
 
 
-    public void dumpRdnIdx( UUID id, String tabs ) throws Exception
+    public void dumpRdnIdx( String id, String tabs ) throws Exception
     {
         // Start with the root
-        Cursor<IndexEntry<ParentIdAndRdn, UUID>> cursor = rdnIdx.forwardCursor();
+        Cursor<IndexEntry<ParentIdAndRdn, String>> cursor = rdnIdx.forwardCursor();
 
-        IndexEntry<ParentIdAndRdn, UUID> startingPos = new ForwardIndexEntry<ParentIdAndRdn, UUID>();
+        IndexEntry<ParentIdAndRdn, String> startingPos = new ForwardIndexEntry<ParentIdAndRdn, String>();
         startingPos.setKey( new ParentIdAndRdn( id, ( Rdn[] ) null ) );
         cursor.before( startingPos );
 
         while ( cursor.next() )
         {
-            IndexEntry<ParentIdAndRdn, UUID> entry = cursor.get();
+            IndexEntry<ParentIdAndRdn, String> entry = cursor.get();
             System.out.println( tabs + entry );
         }
 
@@ -553,19 +554,19 @@ public abstract class AbstractBTreeParti
     }
 
 
-    private void dumpRdnIdx( UUID id, int nbSibbling, String tabs ) throws Exception
+    private void dumpRdnIdx( String id, int nbSibbling, String tabs ) throws Exception
     {
         // Start with the root
-        Cursor<IndexEntry<ParentIdAndRdn, UUID>> cursor = rdnIdx.forwardCursor();
+        Cursor<IndexEntry<ParentIdAndRdn, String>> cursor = rdnIdx.forwardCursor();
 
-        IndexEntry<ParentIdAndRdn, UUID> startingPos = new ForwardIndexEntry<ParentIdAndRdn, UUID>();
+        IndexEntry<ParentIdAndRdn, String> startingPos = new ForwardIndexEntry<ParentIdAndRdn, String>();
         startingPos.setKey( new ParentIdAndRdn( id, ( Rdn[] ) null ) );
         cursor.before( startingPos );
         int countChildren = 0;
 
         while ( cursor.next() && ( countChildren < nbSibbling ) )
         {
-            IndexEntry<ParentIdAndRdn, UUID> entry = cursor.get();
+            IndexEntry<ParentIdAndRdn, String> entry = cursor.get();
             System.out.println( tabs + entry );
             countChildren++;
 
@@ -603,7 +604,7 @@ public abstract class AbstractBTreeParti
                 throw ne;
             }
 
-            UUID parentId = null;
+            String parentId = null;
 
             //
             // Suffix entry cannot have a parent since it is the root so it is
@@ -635,7 +636,7 @@ public abstract class AbstractBTreeParti
             // Get a new UUID for the added entry if it does not have any already
             Attribute entryUUID = entry.get( ENTRY_UUID_AT );
 
-            UUID id = null;
+            String id = null;
 
             if ( entryUUID == null )
             {
@@ -643,7 +644,7 @@ public abstract class AbstractBTreeParti
             }
             else
             {
-                id = UUID.fromString( entryUUID.getString() );
+                id = entryUUID.getString();
             }
 
             // Update the RDN index
@@ -703,7 +704,7 @@ public abstract class AbstractBTreeParti
                 throw new LdapSchemaViolationException( ResultCodeEnum.OBJECT_CLASS_VIOLATION, msg );
             }
 
-            entryUuidIdx.add( UUID.fromString( entryUuid.getString() ), id );
+            entryUuidIdx.add( entryUuid.getString(), id );
 
             // Now work on the user defined userIndices
             for ( Attribute attribute : entry )
@@ -713,7 +714,7 @@ public abstract class AbstractBTreeParti
 
                 if ( hasUserIndexOn( attributeType ) )
                 {
-                    Index<Object, Entry, UUID> idx = ( Index<Object, Entry, UUID> ) getUserIndex( attributeType );
+                    Index<Object, Entry, String> idx = ( Index<Object, Entry, String> ) getUserIndex( attributeType );
 
                     // here lookup by attributeId is OK since we got attributeId from
                     // the entry via the enumeration - it's in there as is for sure
@@ -745,7 +746,6 @@ public abstract class AbstractBTreeParti
         }
         catch ( Exception e )
         {
-            e.printStackTrace();
             throw new LdapException( e );
         }
     }
@@ -761,7 +761,7 @@ public abstract class AbstractBTreeParti
     {
         Dn dn = deleteContext.getDn();
 
-        UUID id = getEntryId( dn );
+        String id = getEntryId( dn );
 
         // don't continue if id is null
         if ( id == null )
@@ -783,7 +783,7 @@ public abstract class AbstractBTreeParti
     }
 
 
-    protected void updateRdnIdx( UUID parentId, boolean addRemove, int nbDescendant ) throws Exception
+    protected void updateRdnIdx( String parentId, boolean addRemove, int nbDescendant ) throws Exception
     {
         boolean isFirst = true;
 
@@ -835,7 +835,7 @@ public abstract class AbstractBTreeParti
      * @param id The id of the entry to delete
      * @throws Exception If the deletion failed
      */
-    public void delete( UUID id ) throws LdapException
+    public void delete( String id ) throws LdapException
     {
         try
         {
@@ -871,7 +871,7 @@ public abstract class AbstractBTreeParti
             dumpRdnIdx();
 
             entryCsnIdx.drop( entry.get( ENTRY_CSN_AT ).getString(), id );
-            entryUuidIdx.drop( UUID.fromString( entry.get( ENTRY_UUID_AT ).getString() ), id );
+            entryUuidIdx.drop( entry.get( ENTRY_UUID_AT ).getString(), id );
 
             // Update the user indexes
             for ( Attribute attribute : entry )
@@ -881,7 +881,7 @@ public abstract class AbstractBTreeParti
 
                 if ( hasUserIndexOn( attributeType ) )
                 {
-                    Index<?, Entry, UUID> index = getUserIndex( attributeType );
+                    Index<?, Entry, String> index = getUserIndex( attributeType );
 
                     // here lookup by attributeId is ok since we got attributeId from
                     // the entry via the enumeration - it's in there as is for sure
@@ -925,15 +925,15 @@ public abstract class AbstractBTreeParti
     /**
      * {@inheritDoc}
      */
-    public final Cursor<IndexEntry<UUID, UUID>> list( UUID id ) throws LdapException
+    public final Cursor<IndexEntry<String, String>> list( String id ) throws LdapException
     {
         try
         {
             // We use the OneLevel index to get all the entries from a starting point
             // and below up to the number of children
-            Cursor<IndexEntry<ParentIdAndRdn, UUID>> cursor = rdnIdx.forwardCursor();
+            Cursor<IndexEntry<ParentIdAndRdn, String>> cursor = rdnIdx.forwardCursor();
 
-            IndexEntry<ParentIdAndRdn, UUID> startingPos = new ForwardIndexEntry<ParentIdAndRdn, UUID>();
+            IndexEntry<ParentIdAndRdn, String> startingPos = new ForwardIndexEntry<ParentIdAndRdn, String>();
             startingPos.setKey( new ParentIdAndRdn( id, ( Rdn[] ) null ) );
             cursor.before( startingPos );
 
@@ -959,7 +959,7 @@ public abstract class AbstractBTreeParti
         try
         {
             SearchScope scope = searchContext.getScope();
-            Cursor<IndexEntry<UUID, UUID>> underlying;
+            Cursor<IndexEntry<String, String>> underlying;
             Dn dn = searchContext.getDn();
             AliasDerefMode derefMode = searchContext.getAliasDerefMode();
             ExprNode filter = searchContext.getFilter();
@@ -989,7 +989,7 @@ public abstract class AbstractBTreeParti
      */
     public Entry lookup( LookupOperationContext lookupContext ) throws LdapException
     {
-        UUID id = getEntryId( lookupContext.getDn() );
+        String id = getEntryId( lookupContext.getDn() );
 
         if ( id == null )
         {
@@ -1089,7 +1089,7 @@ public abstract class AbstractBTreeParti
      * @return The found Entry, or null if not found
      * @throws Exception If the lookup failed for any reason (except a not found entry)
      */
-    public Entry lookup( UUID id ) throws LdapException
+    public Entry lookup( String id ) throws LdapException
     {
         try
         {
@@ -1120,7 +1120,7 @@ public abstract class AbstractBTreeParti
      * @return The found Entry, or null if not found
      * @throws Exception If the lookup failed for any reason (except a not found entry)
      */
-    public Entry lookup( UUID id, Dn dn ) throws LdapException
+    public Entry lookup( String id, Dn dn ) throws LdapException
     {
         try
         {
@@ -1170,7 +1170,7 @@ public abstract class AbstractBTreeParti
      */
     public synchronized final Entry modify( Dn dn, Modification... mods ) throws Exception
     {
-        UUID id = getEntryId( dn );
+        String id = getEntryId( dn );
         Entry entry = master.get( id );
 
         for ( Modification mod : mods )
@@ -1219,7 +1219,7 @@ public abstract class AbstractBTreeParti
      * @throws Exception if index alteration or attribute addition fails
      */
     @SuppressWarnings("unchecked")
-    private void modifyAdd( UUID id, Entry entry, Attribute mods ) throws Exception
+    private void modifyAdd( String id, Entry entry, Attribute mods ) throws Exception
     {
         if ( entry instanceof ClonedServerEntry )
         {
@@ -1239,7 +1239,7 @@ public abstract class AbstractBTreeParti
         }
         else if ( hasUserIndexOn( attributeType ) )
         {
-            Index<?, Entry, UUID> index = getUserIndex( attributeType );
+            Index<?, Entry, String> index = getUserIndex( attributeType );
 
             for ( Value<?> value : mods )
             {
@@ -1281,7 +1281,7 @@ public abstract class AbstractBTreeParti
      * fails.
      */
     @SuppressWarnings("unchecked")
-    private void modifyReplace( UUID id, Entry entry, Attribute mods ) throws Exception
+    private void modifyReplace( String id, Entry entry, Attribute mods ) throws Exception
     {
         if ( entry instanceof ClonedServerEntry )
         {
@@ -1313,18 +1313,18 @@ public abstract class AbstractBTreeParti
         }
         else if ( hasUserIndexOn( attributeType ) )
         {
-            Index<?, Entry, UUID> index = getUserIndex( attributeType );
+            Index<?, Entry, String> index = getUserIndex( attributeType );
 
             // if the id exists in the index drop all existing attribute
             // value index entries and add new ones
             if ( index.reverse( id ) )
             {
-                ( ( Index<?, Entry, UUID> ) index ).drop( id );
+                ( ( Index<?, Entry, String> ) index ).drop( id );
             }
 
             for ( Value<?> value : mods )
             {
-                ( ( Index<Object, Entry, UUID> ) index ).add( value.getNormValue(), id );
+                ( ( Index<Object, Entry, String> ) index ).add( value.getNormValue(), id );
             }
 
             /*
@@ -1378,7 +1378,7 @@ public abstract class AbstractBTreeParti
      * @throws Exception if index alteration or attribute modification fails.
      */
     @SuppressWarnings("unchecked")
-    private void modifyRemove( UUID id, Entry entry, Attribute mods ) throws Exception
+    private void modifyRemove( String id, Entry entry, Attribute mods ) throws Exception
     {
         if ( entry instanceof ClonedServerEntry )
         {
@@ -1413,7 +1413,7 @@ public abstract class AbstractBTreeParti
         }
         else if ( hasUserIndexOn( attributeType ) )
         {
-            Index<?, Entry, UUID> index = getUserIndex( attributeType );
+            Index<?, Entry, String> index = getUserIndex( attributeType );
 
             /*
              * If there are no attribute values in the modifications then this
@@ -1514,7 +1514,7 @@ public abstract class AbstractBTreeParti
     public synchronized final void move( Dn oldDn, Dn newSuperiorDn, Dn newDn, Entry modifiedEntry ) throws Exception
     {
         // Check that the parent Dn exists
-        UUID newParentId = getEntryId( newSuperiorDn );
+        String newParentId = getEntryId( newSuperiorDn );
 
         if ( newParentId == null )
         {
@@ -1525,7 +1525,7 @@ public abstract class AbstractBTreeParti
         }
 
         // Now check that the new entry does not exist
-        UUID newId = getEntryId( newDn );
+        String newId = getEntryId( newDn );
 
         if ( newId != null )
         {
@@ -1537,8 +1537,8 @@ public abstract class AbstractBTreeParti
         }
 
         // Get the entry and the old parent IDs
-        UUID entryId = getEntryId( oldDn );
-        UUID oldParentId = getParentId( entryId );
+        String entryId = getEntryId( oldDn );
+        String oldParentId = getParentId( entryId );
 
         /*
          * All aliases including and below oldChildDn, will be affected by
@@ -1644,7 +1644,7 @@ public abstract class AbstractBTreeParti
         boolean deleteOldRdn ) throws Exception
     {
         // Check that the old entry exists
-        UUID oldId = getEntryId( oldDn );
+        String oldId = getEntryId( oldDn );
 
         if ( oldId == null )
         {
@@ -1655,7 +1655,7 @@ public abstract class AbstractBTreeParti
         }
 
         // Check that the new superior exist
-        UUID newSuperiorId = getEntryId( newSuperiorDn );
+        String newSuperiorId = getEntryId( newSuperiorDn );
 
         if ( newSuperiorId == null )
         {
@@ -1668,7 +1668,7 @@ public abstract class AbstractBTreeParti
         Dn newDn = newSuperiorDn.add( newRdn );
 
         // Now check that the new entry does not exist
-        UUID newId = getEntryId( newDn );
+        String newId = getEntryId( newDn );
 
         if ( newId != null )
         {
@@ -1711,12 +1711,12 @@ public abstract class AbstractBTreeParti
      * @param modifiedEntry the modified entry
      * @throws Exception if something goes wrong
      */
-    private void moveAndRename( Dn oldDn, UUID entryId, Dn newSuperior, Rdn newRdn, Entry modifiedEntry )
+    private void moveAndRename( Dn oldDn, String entryId, Dn newSuperior, Rdn newRdn, Entry modifiedEntry )
         throws Exception
     {
         // Get the child and the new parent to be entries and Ids
-        UUID newParentId = getEntryId( newSuperior );
-        UUID oldParentId = getParentId( entryId );
+        String newParentId = getEntryId( newSuperior );
+        String oldParentId = getParentId( entryId );
 
         /*
          * All aliases including and below oldChildDn, will be affected by
@@ -1798,7 +1798,7 @@ public abstract class AbstractBTreeParti
     }
 
 
-    private void rename( UUID oldId, Rdn newRdn, boolean deleteOldRdn, Entry entry ) throws Exception
+    private void rename( String oldId, Rdn newRdn, boolean deleteOldRdn, Entry entry ) throws Exception
     {
         if ( entry == null )
         {
@@ -1828,7 +1828,7 @@ public abstract class AbstractBTreeParti
 
             if ( hasUserIndexOn( newRdnAttrType ) )
             {
-                Index<?, Entry, UUID> index = getUserIndex( newRdnAttrType );
+                Index<?, Entry, String> index = getUserIndex( newRdnAttrType );
                 ( ( Index ) index ).add( newNormValue, oldId );
 
                 // Make sure the altered entry shows the existence of the new attrib
@@ -1884,7 +1884,7 @@ public abstract class AbstractBTreeParti
 
                     if ( hasUserIndexOn( oldRdnAttrType ) )
                     {
-                        Index<?, Entry, UUID> index = getUserIndex( oldRdnAttrType );
+                        Index<?, Entry, String> index = getUserIndex( oldRdnAttrType );
                         ( ( Index ) index ).drop( oldNormValue, id );
 
                         /*
@@ -1911,7 +1911,7 @@ public abstract class AbstractBTreeParti
     @SuppressWarnings("unchecked")
     public synchronized final void rename( Dn dn, Rdn newRdn, boolean deleteOldRdn, Entry entry ) throws Exception
     {
-        UUID oldId = getEntryId( dn );
+        String oldId = getEntryId( dn );
 
         rename( oldId, newRdn, deleteOldRdn, entry );
 
@@ -1921,7 +1921,7 @@ public abstract class AbstractBTreeParti
          * We only need to update the Rdn index.
          * No need to calculate the new Dn.
          */
-        UUID parentId = getParentId( oldId );
+        String parentId = getParentId( oldId );
 
         // Get the old parentIdAndRdn to get the nb of children and descendant
         ParentIdAndRdn parentIdAndRdn = rdnIdx.reverseLookup( oldId );
@@ -1963,7 +1963,7 @@ public abstract class AbstractBTreeParti
     {
         try
         {
-            UUID id = getEntryId( entryContext.getDn() );
+            String id = getEntryId( entryContext.getDn() );
 
             Entry entry = lookup( id, entryContext.getDn() );
 
@@ -1986,7 +1986,7 @@ public abstract class AbstractBTreeParti
      * @param id UUID of the entry
      * @throws Exception
      */
-    private void updateCsnIndex( Entry entry, UUID id ) throws Exception
+    private void updateCsnIndex( Entry entry, String id ) throws Exception
     {
         String entryCsn = entry.get( SchemaConstants.ENTRY_CSN_AT ).getString();
         entryCsnIdx.drop( id );
@@ -2004,10 +2004,10 @@ public abstract class AbstractBTreeParti
      * @return the normalized Dn of the entry
      * @throws Exception
      */
-    protected Dn buildEntryDn( UUID id ) throws Exception
+    protected Dn buildEntryDn( String id ) throws Exception
     {
-        UUID parentId = id;
-        UUID rootId = Partition.ROOT_ID;
+        String parentId = id;
+        String rootId = Partition.ROOT_ID;
 
         // Create an array of 10 rdns, just in case. We will extend it if needed
         Rdn[] rdnArray = new Rdn[10];
@@ -2053,7 +2053,7 @@ public abstract class AbstractBTreeParti
     /**
      * {@inheritDoc}
      */
-    public final int getChildCount( UUID id ) throws LdapException
+    public final int getChildCount( String id ) throws LdapException
     {
         try
         {
@@ -2071,7 +2071,7 @@ public abstract class AbstractBTreeParti
     /**
      * {@inheritDoc}
      */
-    public final Dn getEntryDn( UUID id ) throws Exception
+    public final Dn getEntryDn( String id ) throws Exception
     {
         return buildEntryDn( id );
     }
@@ -2080,7 +2080,7 @@ public abstract class AbstractBTreeParti
     /**
      * {@inheritDoc}
      */
-    public final UUID getEntryId( Dn dn ) throws LdapException
+    public final String getEntryId( Dn dn ) throws LdapException
     {
         try
         {
@@ -2092,7 +2092,7 @@ public abstract class AbstractBTreeParti
             ParentIdAndRdn suffixKey = new ParentIdAndRdn( Partition.ROOT_ID, suffixDn.getRdns() );
 
             // Check into the Rdn index, starting with the partition Suffix
-            UUID currentId = rdnIdx.forwardLookup( suffixKey );
+            String currentId = rdnIdx.forwardLookup( suffixKey );
 
             for ( int i = dn.size() - suffixDn.size(); i > 0; i-- )
             {
@@ -2118,7 +2118,7 @@ public abstract class AbstractBTreeParti
     /**
      * {@inheritDoc}
      */
-    public UUID getParentId( UUID childId ) throws Exception
+    public String getParentId( String childId ) throws Exception
     {
         ParentIdAndRdn key = rdnIdx.reverseLookup( childId );
 
@@ -2134,7 +2134,7 @@ public abstract class AbstractBTreeParti
     /**
      * Retrieve the SuffixID
      */
-    protected UUID getSuffixId() throws Exception
+    protected String getSuffixId() throws Exception
     {
         if ( suffixId == null )
         {
@@ -2153,11 +2153,11 @@ public abstract class AbstractBTreeParti
     /**
      * {@inheritDoc}
      */
-    public void addIndex( Index<?, Entry, UUID> index ) throws Exception
+    public void addIndex( Index<?, Entry, String> index ) throws Exception
     {
         checkInitialized( "addIndex" );
 
-        // Check that the index UUID is valid
+        // Check that the index String is valid
         AttributeType attributeType = schemaManager.lookupAttributeTypeRegistry( index.getAttributeId() );
 
         if ( attributeType == null )
@@ -2188,9 +2188,9 @@ public abstract class AbstractBTreeParti
      * Add some new indexes
      * @param indexes The added indexes
      */
-    public void addIndexedAttributes( Index<?, Entry, UUID>... indexes )
+    public void addIndexedAttributes( Index<?, Entry, String>... indexes )
     {
-        for ( Index<?, Entry, UUID> index : indexes )
+        for ( Index<?, Entry, String> index : indexes )
         {
             indexedAttributes.add( index );
         }
@@ -2201,7 +2201,7 @@ public abstract class AbstractBTreeParti
      * Set the list of indexes for this partition
      * @param indexedAttributes The list of indexes
      */
-    public void setIndexedAttributes( Set<Index<?, Entry, UUID>> indexedAttributes )
+    public void setIndexedAttributes( Set<Index<?, Entry, String>> indexedAttributes )
     {
         this.indexedAttributes = indexedAttributes;
     }
@@ -2210,7 +2210,7 @@ public abstract class AbstractBTreeParti
     /**
      * @return The list of indexed attributes
      */
-    public Set<Index<?, Entry, UUID>> getIndexedAttributes()
+    public Set<Index<?, Entry, String>> getIndexedAttributes()
     {
         return indexedAttributes;
     }
@@ -2237,7 +2237,7 @@ public abstract class AbstractBTreeParti
     /**
      * {@inheritDoc}
      */
-    public Index<?, Entry, UUID> getIndex( AttributeType attributeType ) throws IndexNotFoundException
+    public Index<?, Entry, String> getIndex( AttributeType attributeType ) throws IndexNotFoundException
     {
         String id = attributeType.getOid();
 
@@ -2258,7 +2258,7 @@ public abstract class AbstractBTreeParti
     /**
      * {@inheritDoc}
      */
-    public Index<?, Entry, UUID> getUserIndex( AttributeType attributeType ) throws IndexNotFoundException
+    public Index<?, Entry, String> getUserIndex( AttributeType attributeType ) throws IndexNotFoundException
     {
         if ( attributeType == null )
         {
@@ -2279,7 +2279,7 @@ public abstract class AbstractBTreeParti
     /**
      * {@inheritDoc}
      */
-    public Index<?, Entry, UUID> getSystemIndex( AttributeType attributeType ) throws IndexNotFoundException
+    public Index<?, Entry, String> getSystemIndex( AttributeType attributeType ) throws IndexNotFoundException
     {
         if ( attributeType == null )
         {
@@ -2301,9 +2301,9 @@ public abstract class AbstractBTreeParti
      * {@inheritDoc}
      */
     @SuppressWarnings("unchecked")
-    public Index<String, Entry, UUID> getAliasIndex()
+    public Index<String, Entry, String> getAliasIndex()
     {
-        return ( Index<String, Entry, UUID> ) systemIndices.get( ApacheSchemaConstants.APACHE_ALIAS_AT_OID );
+        return ( Index<String, Entry, String> ) systemIndices.get( ApacheSchemaConstants.APACHE_ALIAS_AT_OID );
     }
 
 
@@ -2311,9 +2311,9 @@ public abstract class AbstractBTreeParti
      * {@inheritDoc}
      */
     @SuppressWarnings("unchecked")
-    public Index<UUID, Entry, UUID> getOneAliasIndex()
+    public Index<String, Entry, String> getOneAliasIndex()
     {
-        return ( Index<UUID, Entry, UUID> ) systemIndices.get( ApacheSchemaConstants.APACHE_ONE_ALIAS_AT_OID );
+        return ( Index<String, Entry, String> ) systemIndices.get( ApacheSchemaConstants.APACHE_ONE_ALIAS_AT_OID );
     }
 
 
@@ -2321,9 +2321,9 @@ public abstract class AbstractBTreeParti
      * {@inheritDoc}
      */
     @SuppressWarnings("unchecked")
-    public Index<UUID, Entry, UUID> getSubAliasIndex()
+    public Index<String, Entry, String> getSubAliasIndex()
     {
-        return ( Index<UUID, Entry, UUID> ) systemIndices.get( ApacheSchemaConstants.APACHE_SUB_ALIAS_AT_OID );
+        return ( Index<String, Entry, String> ) systemIndices.get( ApacheSchemaConstants.APACHE_SUB_ALIAS_AT_OID );
     }
 
 
@@ -2331,9 +2331,9 @@ public abstract class AbstractBTreeParti
      * {@inheritDoc}
      */
     @SuppressWarnings("unchecked")
-    public Index<String, Entry, UUID> getObjectClassIndex()
+    public Index<String, Entry, String> getObjectClassIndex()
     {
-        return ( Index<String, Entry, UUID> ) systemIndices.get( SchemaConstants.OBJECT_CLASS_AT_OID );
+        return ( Index<String, Entry, String> ) systemIndices.get( SchemaConstants.OBJECT_CLASS_AT_OID );
     }
 
 
@@ -2341,9 +2341,9 @@ public abstract class AbstractBTreeParti
      * {@inheritDoc}
      */
     @SuppressWarnings("unchecked")
-    public Index<String, Entry, UUID> getEntryUuidIndex()
+    public Index<String, Entry, String> getEntryUuidIndex()
     {
-        return ( Index<String, Entry, UUID> ) systemIndices.get( SchemaConstants.ENTRY_UUID_AT_OID );
+        return ( Index<String, Entry, String> ) systemIndices.get( SchemaConstants.ENTRY_UUID_AT_OID );
     }
 
 
@@ -2351,9 +2351,9 @@ public abstract class AbstractBTreeParti
      * {@inheritDoc}
      */
     @SuppressWarnings("unchecked")
-    public Index<String, Entry, UUID> getEntryCsnIndex()
+    public Index<String, Entry, String> getEntryCsnIndex()
     {
-        return ( Index<String, Entry, UUID> ) systemIndices.get( SchemaConstants.ENTRY_CSN_AT_OID );
+        return ( Index<String, Entry, String> ) systemIndices.get( SchemaConstants.ENTRY_CSN_AT_OID );
     }
 
 
@@ -2361,9 +2361,9 @@ public abstract class AbstractBTreeParti
      * {@inheritDoc}
      */
     @SuppressWarnings("unchecked")
-    public Index<String, Entry, UUID> getPresenceIndex()
+    public Index<String, Entry, String> getPresenceIndex()
     {
-        return ( Index<String, Entry, UUID> ) systemIndices.get( ApacheSchemaConstants.APACHE_PRESENCE_AT_OID );
+        return ( Index<String, Entry, String> ) systemIndices.get( ApacheSchemaConstants.APACHE_PRESENCE_AT_OID );
     }
 
 
@@ -2371,9 +2371,9 @@ public abstract class AbstractBTreeParti
      * {@inheritDoc}
      */
     @SuppressWarnings("unchecked")
-    public Index<ParentIdAndRdn, Entry, UUID> getRdnIndex()
+    public Index<ParentIdAndRdn, Entry, String> getRdnIndex()
     {
-        return ( Index<ParentIdAndRdn, Entry, UUID> ) systemIndices.get( ApacheSchemaConstants.APACHE_RDN_AT_OID );
+        return ( Index<ParentIdAndRdn, Entry, String> ) systemIndices.get( ApacheSchemaConstants.APACHE_RDN_AT_OID );
     }
 
 
@@ -2418,12 +2418,12 @@ public abstract class AbstractBTreeParti
      * not allowed due to chaining or cycle formation.
      * @throws Exception if the wrappedCursor btrees cannot be altered
      */
-    protected void addAliasIndices( UUID aliasId, Dn aliasDn, String aliasTarget ) throws Exception
+    protected void addAliasIndices( String aliasId, Dn aliasDn, String aliasTarget ) throws Exception
     {
         Dn normalizedAliasTargetDn; // Name value of aliasedObjectName
-        UUID targetId; // Id of the aliasedObjectName
+        String targetId; // Id of the aliasedObjectName
         Dn ancestorDn; // Name of an alias entry relative
-        UUID ancestorId; // Id of an alias entry relative
+        String ancestorId; // Id of an alias entry relative
 
         // Access aliasedObjectName, normalize it and generate the Name
         normalizedAliasTargetDn = new Dn( schemaManager, aliasTarget );
@@ -2533,10 +2533,10 @@ public abstract class AbstractBTreeParti
      * @throws LdapException if we cannot parse ldap names
      * @throws Exception if we cannot delete index values in the database
      */
-    protected void dropAliasIndices( UUID aliasId ) throws Exception
+    protected void dropAliasIndices( String aliasId ) throws Exception
     {
         String targetDn = aliasIdx.reverseLookup( aliasId );
-        UUID targetId = getEntryId( new Dn( schemaManager, targetDn ) );
+        String targetId = getEntryId( new Dn( schemaManager, targetDn ) );
 
         if ( targetId == null )
         {
@@ -2548,7 +2548,7 @@ public abstract class AbstractBTreeParti
         Dn aliasDn = getEntryDn( aliasId );
 
         Dn ancestorDn = aliasDn.getParent();
-        UUID ancestorId = getEntryId( ancestorDn );
+        String ancestorId = getEntryId( ancestorDn );
 
         /*
          * We cannot just drop all tuples in the one level and subtree userIndices
@@ -2587,7 +2587,7 @@ public abstract class AbstractBTreeParti
      */
     protected void dropMovedAliasIndices( final Dn movedBase ) throws Exception
     {
-        UUID movedBaseId = getEntryId( movedBase );
+        String movedBaseId = getEntryId( movedBase );
 
         if ( aliasIdx.reverseLookup( movedBaseId ) != null )
         {
@@ -2604,10 +2604,10 @@ public abstract class AbstractBTreeParti
      * @param movedBase the base where the move occurred
      * @throws Exception if userIndices fail
      */
-    protected void dropAliasIndices( UUID aliasId, Dn movedBase ) throws Exception
+    protected void dropAliasIndices( String aliasId, Dn movedBase ) throws Exception
     {
         String targetDn = aliasIdx.reverseLookup( aliasId );
-        UUID targetId = getEntryId( new Dn( schemaManager, targetDn ) );
+        String targetId = getEntryId( new Dn( schemaManager, targetDn ) );
         Dn aliasDn = getEntryDn( aliasId );
 
         /*
@@ -2615,7 +2615,7 @@ public abstract class AbstractBTreeParti
          * moved base.  This is the first ancestor effected by the move.
          */
         Dn ancestorDn = new Dn( schemaManager, movedBase.getRdn( movedBase.size() - 1 ) );
-        UUID ancestorId = getEntryId( ancestorDn );
+        String ancestorId = getEntryId( ancestorDn );
 
         /*
          * We cannot just drop all tuples in the one level and subtree userIndices
@@ -2649,15 +2649,15 @@ public abstract class AbstractBTreeParti
     //---------------------------------------------------------------------------------------------
     // Debug methods
     //---------------------------------------------------------------------------------------------
-    private void dumpIndex( OutputStream stream, Index<?, Entry, UUID> index )
+    private void dumpIndex( OutputStream stream, Index<?, Entry, String> index )
     {
         try
         {
-            Cursor<IndexEntry<?, UUID>> cursor = ( Cursor ) index.forwardCursor();
+            Cursor<IndexEntry<?, String>> cursor = ( Cursor ) index.forwardCursor();
 
             while ( cursor.next() )
             {
-                IndexEntry<?, UUID> entry = cursor.get();
+                IndexEntry<?, String> entry = cursor.get();
 
                 System.out.println( entry );
             }

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/EntryCursorAdaptor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/EntryCursorAdaptor.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/EntryCursorAdaptor.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/EntryCursorAdaptor.java Wed Aug 29 17:13:56 2012
@@ -20,8 +20,6 @@
 package org.apache.directory.server.core.partition.impl.btree;
 
 
-import java.util.UUID;
-
 import org.apache.directory.server.xdbm.IndexEntry;
 import org.apache.directory.shared.ldap.model.cursor.AbstractCursor;
 import org.apache.directory.shared.ldap.model.cursor.ClosureMonitor;
@@ -42,10 +40,10 @@ public class EntryCursorAdaptor extends 
     private static final Logger LOG_CURSOR = LoggerFactory.getLogger( "CURSOR" );
 
     private final AbstractBTreePartition db;
-    private final Cursor<IndexEntry<UUID, UUID>> indexCursor;
+    private final Cursor<IndexEntry<String, String>> indexCursor;
 
 
-    public EntryCursorAdaptor( AbstractBTreePartition db, Cursor<IndexEntry<UUID, UUID>> indexCursor )
+    public EntryCursorAdaptor( AbstractBTreePartition db, Cursor<IndexEntry<String, String>> indexCursor )
     {
         LOG_CURSOR.debug( "Creating EntryCursorAdaptor {}", this );
         this.db = db;
@@ -138,7 +136,7 @@ public class EntryCursorAdaptor extends 
      */
     public Entry get() throws Exception
     {
-        IndexEntry<UUID, UUID> indexEntry = indexCursor.get();
+        IndexEntry<String, String> indexEntry = indexCursor.get();
 
         if ( indexEntry.getEntry() == null )
         {

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/IndexCursorAdaptor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/IndexCursorAdaptor.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/IndexCursorAdaptor.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/IndexCursorAdaptor.java Wed Aug 29 17:13:56 2012
@@ -21,7 +21,6 @@ package org.apache.directory.server.core
 
 
 import java.util.Iterator;
-import java.util.UUID;
 
 import org.apache.directory.server.xdbm.AbstractIndexCursor;
 import org.apache.directory.server.xdbm.ForwardIndexEntry;
@@ -49,8 +48,8 @@ public class IndexCursorAdaptor<K> exten
 
     @SuppressWarnings("unchecked")
     final Cursor<Tuple> wrappedCursor;
-    final ForwardIndexEntry<K, UUID> forwardEntry;
-    final ReverseIndexEntry<K, UUID> reverseEntry;
+    final ForwardIndexEntry<K, String> forwardEntry;
+    final ReverseIndexEntry<K, String> reverseEntry;
 
 
     /**
@@ -69,13 +68,13 @@ public class IndexCursorAdaptor<K> exten
 
         if ( forwardIndex )
         {
-            forwardEntry = new ForwardIndexEntry<K, UUID>();
+            forwardEntry = new ForwardIndexEntry<K, String>();
             reverseEntry = null;
         }
         else
         {
             forwardEntry = null;
-            reverseEntry = new ReverseIndexEntry<K, UUID>();
+            reverseEntry = new ReverseIndexEntry<K, String>();
         }
     }
 
@@ -86,13 +85,13 @@ public class IndexCursorAdaptor<K> exten
     }
 
 
-    public void before( IndexEntry<K, UUID> element ) throws Exception
+    public void before( IndexEntry<K, String> element ) throws Exception
     {
         wrappedCursor.before( element.getTuple() );
     }
 
 
-    public void after( IndexEntry<K, UUID> element ) throws Exception
+    public void after( IndexEntry<K, String> element ) throws Exception
     {
         wrappedCursor.after( element.getTuple() );
     }
@@ -141,17 +140,17 @@ public class IndexCursorAdaptor<K> exten
 
 
     @SuppressWarnings("unchecked")
-    public IndexEntry<K, UUID> get() throws Exception
+    public IndexEntry<K, String> get() throws Exception
     {
         if ( forwardEntry != null )
         {
-            Tuple<K, UUID> tuple = wrappedCursor.get();
+            Tuple<K, String> tuple = wrappedCursor.get();
             forwardEntry.setTuple( tuple, null );
             return forwardEntry;
         }
         else
         {
-            Tuple<UUID, K> tuple = wrappedCursor.get();
+            Tuple<String, K> tuple = wrappedCursor.get();
             reverseEntry.setTuple( tuple, null );
             return reverseEntry;
         }
@@ -178,9 +177,9 @@ public class IndexCursorAdaptor<K> exten
     }
 
 
-    public Iterator<IndexEntry<K, UUID>> iterator()
+    public Iterator<IndexEntry<K, String>> iterator()
     {
-        return new CursorIterator<IndexEntry<K, UUID>>( this );
+        return new CursorIterator<IndexEntry<K, String>>( this );
     }
 
 

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/AbstractIndexCursor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/AbstractIndexCursor.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/AbstractIndexCursor.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/AbstractIndexCursor.java Wed Aug 29 17:13:56 2012
@@ -20,8 +20,6 @@
 package org.apache.directory.server.xdbm;
 
 
-import java.util.UUID;
-
 import org.apache.directory.shared.ldap.model.cursor.AbstractCursor;
 
 
@@ -30,7 +28,7 @@ import org.apache.directory.shared.ldap.
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public abstract class AbstractIndexCursor<V> extends AbstractCursor<IndexEntry<V, UUID>>
+public abstract class AbstractIndexCursor<V> extends AbstractCursor<IndexEntry<V, String>>
 {
     /** Tells if there are some element available in the cursor */
     private boolean available = false;
@@ -59,7 +57,7 @@ public abstract class AbstractIndexCurso
     /**
      * {@inheritDoc}
      */
-    public void after( IndexEntry<V, UUID> element ) throws Exception
+    public void after( IndexEntry<V, String> element ) throws Exception
     {
         throw new UnsupportedOperationException( getUnsupportedMessage() );
     }
@@ -68,7 +66,7 @@ public abstract class AbstractIndexCurso
     /**
      * {@inheritDoc}
      */
-    public void before( IndexEntry<V, UUID> element ) throws Exception
+    public void before( IndexEntry<V, String> element ) throws Exception
     {
         throw new UnsupportedOperationException( getUnsupportedMessage() );
     }

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/EmptyIndexCursor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/EmptyIndexCursor.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/EmptyIndexCursor.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/EmptyIndexCursor.java Wed Aug 29 17:13:56 2012
@@ -19,8 +19,6 @@
 package org.apache.directory.server.xdbm;
 
 
-import java.util.UUID;
-
 import org.apache.directory.server.i18n.I18n;
 import org.apache.directory.shared.ldap.model.cursor.InvalidCursorPositionException;
 import org.slf4j.Logger;
@@ -47,7 +45,7 @@ public class EmptyIndexCursor<K> extends
     /**
      * {@inheritDoc}
      */
-    public void before( IndexEntry<K, UUID> element ) throws Exception
+    public void before( IndexEntry<K, String> element ) throws Exception
     {
         checkNotClosed( "before()" );
     }
@@ -65,7 +63,7 @@ public class EmptyIndexCursor<K> extends
     /**
      * {@inheritDoc}
      */
-    public void after( IndexEntry<K, UUID> element ) throws Exception
+    public void after( IndexEntry<K, String> element ) throws Exception
     {
         checkNotClosed( "after()" );
     }
@@ -111,7 +109,7 @@ public class EmptyIndexCursor<K> extends
     }
 
 
-    public IndexEntry<K, UUID> get() throws Exception
+    public IndexEntry<K, String> get() throws Exception
     {
         checkNotClosed( "get()" );
         throw new InvalidCursorPositionException( I18n.err( I18n.ERR_703 ) );
@@ -121,7 +119,7 @@ public class EmptyIndexCursor<K> extends
     /**
      * {@inheritDoc}
      */
-    public void afterValue( UUID id, K indexValue ) throws Exception
+    public void afterValue( String id, K indexValue ) throws Exception
     {
         checkNotClosed( "after()" );
     }
@@ -130,7 +128,7 @@ public class EmptyIndexCursor<K> extends
     /**
      * {@inheritDoc}
      */
-    public void beforeValue( UUID id, K indexValue ) throws Exception
+    public void beforeValue( String id, K indexValue ) throws Exception
     {
         checkNotClosed( "after()" );
     }

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/MasterTable.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/MasterTable.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/MasterTable.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/MasterTable.java Wed Aug 29 17:13:56 2012
@@ -20,7 +20,6 @@
 package org.apache.directory.server.xdbm;
 
 
-import java.util.UUID;
 
 
 /**
@@ -28,7 +27,7 @@ import java.util.UUID;
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public interface MasterTable<E> extends Table<UUID, E>
+public interface MasterTable<E> extends Table<String, E>
 {
     /** the base name for the db file for this table */
     String DBF = "master";
@@ -45,5 +44,5 @@ public interface MasterTable<E> extends 
      * @return the current value of this MasterTable's sequence incremented by one
      * @throws Exception on failure to update the id sequence
      */
-    UUID getNextId( E entry ) throws Exception;
+    String getNextId( E entry ) throws Exception;
 }
\ No newline at end of file

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/ParentIdAndRdn.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/ParentIdAndRdn.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/ParentIdAndRdn.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/ParentIdAndRdn.java Wed Aug 29 17:13:56 2012
@@ -26,7 +26,6 @@ import java.io.ObjectInput;
 import java.io.ObjectOutput;
 import java.util.Arrays;
 import java.util.List;
-import java.util.UUID;
 
 import org.apache.directory.shared.ldap.model.name.Rdn;
 
@@ -41,7 +40,7 @@ import org.apache.directory.shared.ldap.
 public class ParentIdAndRdn implements Externalizable, Comparable<ParentIdAndRdn>
 {
     /** The entry ID */
-    protected UUID parentId;
+    protected String parentId;
 
     /** The list of Rdn for this instance */
     protected Rdn[] rdns;
@@ -67,7 +66,7 @@ public class ParentIdAndRdn implements E
      * @param parentId the parent ID
      * @param rdns the RDNs
      */
-    public ParentIdAndRdn( UUID parentId, Rdn... rdns )
+    public ParentIdAndRdn( String parentId, Rdn... rdns )
     {
         this.parentId = parentId;
         this.rdns = rdns;
@@ -80,7 +79,7 @@ public class ParentIdAndRdn implements E
      * @param parentId the parent ID
      * @param rdns the RDNs
      */
-    public ParentIdAndRdn( UUID parentId, List<Rdn> rdns )
+    public ParentIdAndRdn( String parentId, List<Rdn> rdns )
     {
         this.parentId = parentId;
         this.rdns = rdns.toArray( new Rdn[rdns.size()] );
@@ -94,7 +93,7 @@ public class ParentIdAndRdn implements E
      * 
      * @return the parent ID
      */
-    public UUID getParentId()
+    public String getParentId()
     {
         return parentId;
     }
@@ -105,7 +104,7 @@ public class ParentIdAndRdn implements E
      * 
      * @param parentId the new parent ID
      */
-    public void setParentId( UUID parentId )
+    public void setParentId( String parentId )
     {
         this.parentId = parentId;
     }
@@ -264,8 +263,7 @@ public class ParentIdAndRdn implements E
 
     public void writeExternal( ObjectOutput out ) throws IOException
     {
-        out.writeLong( parentId.getMostSignificantBits() );
-        out.writeLong( parentId.getLeastSignificantBits() );
+        out.writeUTF( parentId );
         out.writeInt( nbChildren );
         out.writeInt( nbDescendants );
         out.writeInt( rdns.length );
@@ -280,9 +278,7 @@ public class ParentIdAndRdn implements E
     @SuppressWarnings("unchecked")
     public void readExternal( ObjectInput in ) throws IOException, ClassNotFoundException
     {
-        long uuidMsb = in.readLong();
-        long uuidLsb = in.readLong();
-        parentId = new UUID( uuidMsb, uuidLsb );
+        parentId = in.readUTF();
         nbChildren = in.readInt();
         nbDescendants = in.readInt();
         int size = in.readInt();

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/SingletonIndexCursor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/SingletonIndexCursor.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/SingletonIndexCursor.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/SingletonIndexCursor.java Wed Aug 29 17:13:56 2012
@@ -19,8 +19,6 @@
 package org.apache.directory.server.xdbm;
 
 
-import java.util.UUID;
-
 import org.apache.directory.server.i18n.I18n;
 import org.apache.directory.shared.ldap.model.cursor.InvalidCursorPositionException;
 import org.slf4j.Logger;
@@ -40,10 +38,10 @@ public class SingletonIndexCursor<V> ext
     private boolean beforeFirst = true;
     private boolean afterLast;
     private boolean onSingleton;
-    private final IndexEntry<V, UUID> singleton;
+    private final IndexEntry<V, String> singleton;
 
 
-    public SingletonIndexCursor( IndexEntry<V, UUID> singleton )
+    public SingletonIndexCursor( IndexEntry<V, String> singleton )
     {
         LOG_CURSOR.debug( "Creating SingletonIndexCursor {}", this );
         this.singleton = singleton;
@@ -179,7 +177,7 @@ public class SingletonIndexCursor<V> ext
     }
 
 
-    public IndexEntry<V, UUID> get() throws Exception
+    public IndexEntry<V, String> get() throws Exception
     {
         checkNotClosed( "()" );
 

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/Store.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/Store.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/Store.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/Store.java Wed Aug 29 17:13:56 2012
@@ -26,7 +26,6 @@ import java.util.Collections;
 import java.util.HashSet;
 import java.util.Iterator;
 import java.util.Set;
-import java.util.UUID;
 
 import org.apache.directory.server.constants.ApacheSchemaConstants;
 import org.apache.directory.shared.ldap.model.constants.SchemaConstants;
@@ -159,7 +158,7 @@ public interface Store<E>
      * @param index The index to add
      * @throws Exception If the addition failed
      */
-    void addIndex( Index<?, E, UUID> index ) throws Exception;
+    void addIndex( Index<?, E, String> index ) throws Exception;
 
 
     //------------------------------------------------------------------------
@@ -168,49 +167,49 @@ public interface Store<E>
     /**
      * @return The Presence system index
      */
-    Index<String, E, UUID> getPresenceIndex();
+    Index<String, E, String> getPresenceIndex();
 
 
     /**
      * @return The Alias system index
      */
-    Index<String, E, UUID> getAliasIndex();
+    Index<String, E, String> getAliasIndex();
 
 
     /**
      * @return The OneAlias system index
      */
-    Index<UUID, E, UUID> getOneAliasIndex();
+    Index<String, E, String> getOneAliasIndex();
 
 
     /**
      * @return The SubAlias system index
      */
-    Index<UUID, E, UUID> getSubAliasIndex();
+    Index<String, E, String> getSubAliasIndex();
 
 
     /**
      * @return The Rdn system index
      */
-    Index<ParentIdAndRdn, E, UUID> getRdnIndex();
+    Index<ParentIdAndRdn, E, String> getRdnIndex();
 
 
     /**
      * @return The ObjectClass system index
      */
-    Index<String, E, UUID> getObjectClassIndex();
+    Index<String, E, String> getObjectClassIndex();
 
 
     /**
      * @return The EntryUUID system index
      */
-    Index<String, E, UUID> getEntryUuidIndex();
+    Index<String, E, String> getEntryUuidIndex();
 
 
     /**
      * @return The EntryCSN system index
      */
-    Index<String, E, UUID> getEntryCsnIndex();
+    Index<String, E, String> getEntryCsnIndex();
 
 
     /**
@@ -262,7 +261,7 @@ public interface Store<E>
      * @return The associated user <strong>or</strong> system index
      * @throws IndexNotFoundException If the index does not exist
      */
-    Index<?, E, UUID> getIndex( AttributeType attributeType ) throws IndexNotFoundException;
+    Index<?, E, String> getIndex( AttributeType attributeType ) throws IndexNotFoundException;
 
 
     /**
@@ -271,7 +270,7 @@ public interface Store<E>
      * @return The associated user index
      * @throws IndexNotFoundException If the index does not exist
      */
-    Index<?, E, UUID> getUserIndex( AttributeType attributeType ) throws IndexNotFoundException;
+    Index<?, E, String> getUserIndex( AttributeType attributeType ) throws IndexNotFoundException;
 
 
     /**
@@ -280,7 +279,7 @@ public interface Store<E>
      * @return The associated system index
      * @throws IndexNotFoundException If the index does not exist
      */
-    Index<?, E, UUID> getSystemIndex( AttributeType attributeType ) throws IndexNotFoundException;
+    Index<?, E, String> getSystemIndex( AttributeType attributeType ) throws IndexNotFoundException;
 
 
     /**
@@ -289,7 +288,7 @@ public interface Store<E>
      * @param dn the normalized entry Dn
      * @return the entry's id, or <code>null</code> if the Dn doesn't exists
      */
-    UUID getEntryId( Dn dn ) throws Exception;
+    String getEntryId( Dn dn ) throws Exception;
 
 
     /**
@@ -298,7 +297,7 @@ public interface Store<E>
      * @param id the entry's id
      * @return the entry's Dn
      */
-    Dn getEntryDn( UUID id ) throws Exception;
+    Dn getEntryDn( String id ) throws Exception;
 
 
     /**
@@ -309,7 +308,7 @@ public interface Store<E>
      * @return the id of the parent entry or zero if the suffix entry UUID is used
      * @throws Exception on failures to access the underlying store
      */
-    UUID getParentId( UUID childId ) throws Exception;
+    String getParentId( String childId ) throws Exception;
 
 
     /**
@@ -327,7 +326,7 @@ public interface Store<E>
      * @param id The Entry UUID we want to delete
      * @throws Exception If the deletion failed for any reason
      */
-    void delete( UUID id ) throws Exception;
+    void delete( String id ) throws Exception;
 
 
     /**
@@ -337,7 +336,7 @@ public interface Store<E>
      * @return an IndexEntry Cursor over the child entries
      * @throws Exception on failures to access the underlying store
      */
-    Cursor<IndexEntry<UUID, UUID>> list( UUID id ) throws Exception;
+    Cursor<IndexEntry<String, String>> list( String id ) throws Exception;
 
 
     /**
@@ -347,7 +346,7 @@ public interface Store<E>
      * @return The found Entry, or null if not found
      * @throws Exception If the lookup failed for any reason (except a not found entry)
      */
-    Entry lookup( UUID id ) throws Exception;
+    Entry lookup( String id ) throws Exception;
 
 
     /**
@@ -358,7 +357,7 @@ public interface Store<E>
      * @return The found Entry, or null if not found
      * @throws Exception If the lookup failed for any reason (except a not found entry)
      */
-    Entry lookup( UUID id, Dn dn ) throws Exception;
+    Entry lookup( String id, Dn dn ) throws Exception;
 
 
     /**
@@ -368,7 +367,7 @@ public interface Store<E>
      * @return the child count
      * @throws Exception on failures to access the underlying store
      */
-    int getChildCount( UUID id ) throws Exception;
+    int getChildCount( String id ) throws Exception;
 
 
     /**

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlIndex.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlIndex.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlIndex.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlIndex.java Wed Aug 29 17:13:56 2012
@@ -21,7 +21,6 @@ package org.apache.directory.server.xdbm
 
 
 import java.net.URI;
-import java.util.UUID;
 
 import org.apache.directory.server.core.partition.impl.btree.IndexCursorAdaptor;
 import org.apache.directory.server.i18n.I18n;
@@ -44,11 +43,11 @@ import org.apache.directory.shared.ldap.
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class AvlIndex<K, O> extends AbstractIndex<K, O, UUID>
+public class AvlIndex<K, O> extends AbstractIndex<K, O, String>
 {
     protected Normalizer normalizer;
-    protected AvlTable<K, UUID> forward;
-    protected AvlTable<UUID, K> reverse;
+    protected AvlTable<K, String> forward;
+    protected AvlTable<String, K> reverse;
 
 
     public AvlIndex()
@@ -99,7 +98,7 @@ public class AvlIndex<K, O> extends Abst
          * primary keys.  A value for an attribute can occur several times in
          * different entries so the forward map can have more than one value.
          */
-        forward = new AvlTable<K, UUID>( attributeType.getName(), comp, UuidComparator.INSTANCE, true );
+        forward = new AvlTable<K, String>( attributeType.getName(), comp, UuidComparator.INSTANCE, true );
 
         /*
          * Now the reverse map stores the primary key into the master table as
@@ -111,17 +110,17 @@ public class AvlIndex<K, O> extends Abst
         {
             if ( attributeType.isSingleValued() )
             {
-                reverse = new AvlTable<UUID, K>( attributeType.getName(), UuidComparator.INSTANCE, comp, false );
+                reverse = new AvlTable<String, K>( attributeType.getName(), UuidComparator.INSTANCE, comp, false );
             }
             else
             {
-                reverse = new AvlTable<UUID, K>( attributeType.getName(), UuidComparator.INSTANCE, comp, true );
+                reverse = new AvlTable<String, K>( attributeType.getName(), UuidComparator.INSTANCE, comp, true );
             }
         }
     }
 
 
-    public void add( K attrVal, UUID id ) throws Exception
+    public void add( K attrVal, String id ) throws Exception
     {
         forward.put( attrVal, id );
 
@@ -170,17 +169,17 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public void drop( UUID id ) throws Exception
+    public void drop( String id ) throws Exception
     {
         if ( withReverse )
         {
             if ( isDupsEnabled() )
             {
-                Cursor<Tuple<UUID, K>> cursor = reverse.cursor( id );
+                Cursor<Tuple<String, K>> cursor = reverse.cursor( id );
 
                 while ( cursor.next() )
                 {
-                    Tuple<UUID, K> tuple = cursor.get();
+                    Tuple<String, K> tuple = cursor.get();
                     forward.remove( tuple.getValue(), id );
                 }
 
@@ -201,7 +200,7 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public void drop( K attrVal, UUID id ) throws Exception
+    public void drop( K attrVal, String id ) throws Exception
     {
         forward.remove( attrVal, id );
 
@@ -224,7 +223,7 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public boolean forward( K attrVal, UUID id ) throws Exception
+    public boolean forward( K attrVal, String id ) throws Exception
     {
         return forward.has( attrVal, id );
     }
@@ -234,7 +233,7 @@ public class AvlIndex<K, O> extends Abst
      * {@inheritDoc}
      */
     @SuppressWarnings("unchecked")
-    public Cursor<IndexEntry<K, UUID>> forwardCursor() throws Exception
+    public Cursor<IndexEntry<K, String>> forwardCursor() throws Exception
     {
         return new IndexCursorAdaptor( forward.cursor(), true );
     }
@@ -244,7 +243,7 @@ public class AvlIndex<K, O> extends Abst
      * {@inheritDoc}
      */
     @SuppressWarnings("unchecked")
-    public Cursor<IndexEntry<K, UUID>> forwardCursor( K key ) throws Exception
+    public Cursor<IndexEntry<K, String>> forwardCursor( K key ) throws Exception
     {
         return new IndexCursorAdaptor( forward.cursor( key ), true );
     }
@@ -262,7 +261,7 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public boolean forwardGreaterOrEq( K attrVal, UUID id ) throws Exception
+    public boolean forwardGreaterOrEq( K attrVal, String id ) throws Exception
     {
         return forward.hasGreaterOrEqual( attrVal, id );
     }
@@ -280,7 +279,7 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public boolean forwardLessOrEq( K attrVal, UUID id ) throws Exception
+    public boolean forwardLessOrEq( K attrVal, String id ) throws Exception
     {
         return forward.hasLessOrEqual( attrVal, id );
     }
@@ -289,7 +288,7 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public UUID forwardLookup( K attrVal ) throws Exception
+    public String forwardLookup( K attrVal ) throws Exception
     {
         return forward.get( attrVal );
     }
@@ -298,7 +297,7 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public Cursor<UUID> forwardValueCursor( K key ) throws Exception
+    public Cursor<String> forwardValueCursor( K key ) throws Exception
     {
         return forward.valueCursor( key );
     }
@@ -325,7 +324,7 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public boolean reverse( UUID id ) throws Exception
+    public boolean reverse( String id ) throws Exception
     {
         if ( withReverse )
         {
@@ -341,7 +340,7 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public boolean reverse( UUID id, K attrVal ) throws Exception
+    public boolean reverse( String id, K attrVal ) throws Exception
     {
         if ( withReverse )
         {
@@ -358,7 +357,7 @@ public class AvlIndex<K, O> extends Abst
      * {@inheritDoc}
      */
     @SuppressWarnings("unchecked")
-    public Cursor<IndexEntry<K, UUID>> reverseCursor() throws Exception
+    public Cursor<IndexEntry<K, String>> reverseCursor() throws Exception
     {
         if ( withReverse )
         {
@@ -375,7 +374,7 @@ public class AvlIndex<K, O> extends Abst
      * {@inheritDoc}
      */
     @SuppressWarnings("unchecked")
-    public Cursor<IndexEntry<K, UUID>> reverseCursor( UUID id ) throws Exception
+    public Cursor<IndexEntry<K, String>> reverseCursor( String id ) throws Exception
     {
         if ( withReverse )
         {
@@ -391,7 +390,7 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public boolean reverseGreaterOrEq( UUID id ) throws Exception
+    public boolean reverseGreaterOrEq( String id ) throws Exception
     {
         if ( withReverse )
         {
@@ -407,7 +406,7 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public boolean reverseGreaterOrEq( UUID id, K attrVal ) throws Exception
+    public boolean reverseGreaterOrEq( String id, K attrVal ) throws Exception
     {
         if ( withReverse )
         {
@@ -423,7 +422,7 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public boolean reverseLessOrEq( UUID id ) throws Exception
+    public boolean reverseLessOrEq( String id ) throws Exception
     {
         if ( withReverse )
         {
@@ -439,7 +438,7 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public boolean reverseLessOrEq( UUID id, K attrVal ) throws Exception
+    public boolean reverseLessOrEq( String id, K attrVal ) throws Exception
     {
         if ( withReverse )
         {
@@ -455,7 +454,7 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public K reverseLookup( UUID id ) throws Exception
+    public K reverseLookup( String id ) throws Exception
     {
         if ( withReverse )
         {
@@ -471,7 +470,7 @@ public class AvlIndex<K, O> extends Abst
     /**
      * {@inheritDoc}
      */
-    public Cursor<K> reverseValueCursor( UUID id ) throws Exception
+    public Cursor<K> reverseValueCursor( String id ) throws Exception
     {
         if ( withReverse )
         {

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlMasterTable.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlMasterTable.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlMasterTable.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlMasterTable.java Wed Aug 29 17:13:56 2012
@@ -32,9 +32,9 @@ import org.apache.directory.server.xdbm.
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class AvlMasterTable<E> extends AvlTable<UUID, E> implements MasterTable<E>
+public class AvlMasterTable<E> extends AvlTable<String, E> implements MasterTable<E>
 {
-    public AvlMasterTable( String name, Comparator<UUID> keyComparator, Comparator<E> valComparator,
+    public AvlMasterTable( String name, Comparator<String> keyComparator, Comparator<E> valComparator,
         boolean dupsEnabled )
     {
         super( name, keyComparator, valComparator, dupsEnabled );
@@ -44,8 +44,8 @@ public class AvlMasterTable<E> extends A
     /**
      * {@inheritDoc}
      */
-    public UUID getNextId( E entry ) throws Exception
+    public String getNextId( E entry ) throws Exception
     {
-        return UUID.randomUUID();
+        return UUID.randomUUID().toString();
     }
 }

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlRdnIndex.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlRdnIndex.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlRdnIndex.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/impl/avl/AvlRdnIndex.java Wed Aug 29 17:13:56 2012
@@ -21,8 +21,6 @@
 package org.apache.directory.server.xdbm.impl.avl;
 
 
-import java.util.UUID;
-
 import org.apache.directory.server.i18n.I18n;
 import org.apache.directory.server.xdbm.ParentIdAndRdn;
 import org.apache.directory.server.xdbm.ParentIdAndRdnComparator;
@@ -75,7 +73,7 @@ public class AvlRdnIndex extends AvlInde
             throw new Exception( I18n.err( I18n.ERR_212, attributeType ) );
         }
 
-        ParentIdAndRdnComparator<UUID> comp = new ParentIdAndRdnComparator<UUID>( mr.getOid() );
+        ParentIdAndRdnComparator<String> comp = new ParentIdAndRdnComparator<String>( mr.getOid() );
 
         UuidComparator.INSTANCE.setSchemaManager( schemaManager );
 
@@ -84,9 +82,9 @@ public class AvlRdnIndex extends AvlInde
          * primary keys.  A value for an attribute can occur several times in
          * different entries so the forward map can have more than one value.
          */
-        forward = new AvlTable<ParentIdAndRdn, UUID>( attributeType.getName(), comp, UuidComparator.INSTANCE,
+        forward = new AvlTable<ParentIdAndRdn, String>( attributeType.getName(), comp, UuidComparator.INSTANCE,
             false );
-        reverse = new AvlTable<UUID, ParentIdAndRdn>( attributeType.getName(), UuidComparator.INSTANCE, comp,
+        reverse = new AvlTable<String, ParentIdAndRdn>( attributeType.getName(), UuidComparator.INSTANCE, comp,
             false );
     }
 }

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/Evaluator.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/Evaluator.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/Evaluator.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/Evaluator.java Wed Aug 29 17:13:56 2012
@@ -20,8 +20,6 @@
 package org.apache.directory.server.xdbm.search;
 
 
-import java.util.UUID;
-
 import org.apache.directory.server.xdbm.IndexEntry;
 import org.apache.directory.shared.ldap.model.entry.Entry;
 import org.apache.directory.shared.ldap.model.filter.ExprNode;
@@ -65,7 +63,7 @@ public interface Evaluator<N extends Exp
      * @return true if filter selects the candidate false otherwise
      * @throws Exception if there are faults during evaluation
      */
-    boolean evaluate( IndexEntry<?, UUID> entry ) throws Exception;
+    boolean evaluate( IndexEntry<?, String> entry ) throws Exception;
 
 
     /**

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/SearchEngine.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/SearchEngine.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/SearchEngine.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/SearchEngine.java Wed Aug 29 17:13:56 2012
@@ -20,8 +20,6 @@
 package org.apache.directory.server.xdbm.search;
 
 
-import java.util.UUID;
-
 import org.apache.directory.server.xdbm.IndexEntry;
 import org.apache.directory.shared.ldap.model.constants.JndiPropertyConstants;
 import org.apache.directory.shared.ldap.model.cursor.Cursor;
@@ -84,7 +82,7 @@ public interface SearchEngine<E>
      * @return enumeration over SearchResults
      * @throws Exception if the search fails
      */
-    Cursor<IndexEntry<UUID, UUID>> cursor( Dn base, AliasDerefMode aliasDerefMode, ExprNode filter,
+    Cursor<IndexEntry<String, String>> cursor( Dn base, AliasDerefMode aliasDerefMode, ExprNode filter,
         SearchScope scope ) throws Exception;
 
 

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/cursor/AllEntriesCursor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/cursor/AllEntriesCursor.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/cursor/AllEntriesCursor.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/cursor/AllEntriesCursor.java Wed Aug 29 17:13:56 2012
@@ -20,8 +20,6 @@
 package org.apache.directory.server.xdbm.search.cursor;
 
 
-import java.util.UUID;
-
 import org.apache.directory.server.core.partition.impl.btree.IndexCursorAdaptor;
 import org.apache.directory.server.xdbm.AbstractIndexCursor;
 import org.apache.directory.server.xdbm.ForwardIndexEntry;
@@ -38,16 +36,16 @@ import org.slf4j.LoggerFactory;
  *
  * @author <a href="mailto:dev@directory.apache.org">Apache Directory Project</a>
  */
-public class AllEntriesCursor extends AbstractIndexCursor<UUID>
+public class AllEntriesCursor extends AbstractIndexCursor<String>
 {
     /** A dedicated log for cursors */
     private static final Logger LOG_CURSOR = LoggerFactory.getLogger( "CURSOR" );
 
     /** The index entry we use to return entries one by one.  */
-    private IndexEntry<UUID, UUID> indexEntry = new ForwardIndexEntry<UUID, UUID>();
+    private IndexEntry<String, String> indexEntry = new ForwardIndexEntry<String, String>();
 
     /** The cursor on the EntryUUID index */
-    private final Cursor<IndexEntry<String, UUID>> wrapped;
+    private final Cursor<IndexEntry<String, String>> wrapped;
 
 
     /**
@@ -75,7 +73,7 @@ public class AllEntriesCursor extends Ab
     /**
      * {@inheritDoc}
      */
-    public void after( IndexEntry<UUID, UUID> indexEntry ) throws Exception
+    public void after( IndexEntry<String, String> indexEntry ) throws Exception
     {
         checkNotClosed( "after()" );
     }
@@ -104,7 +102,7 @@ public class AllEntriesCursor extends Ab
     /**
      * {@inheritDoc}
      */
-    public void before( IndexEntry<UUID, UUID> indexEntry ) throws Exception
+    public void before( IndexEntry<String, String> indexEntry ) throws Exception
     {
         checkNotClosed( "before()" );
     }
@@ -135,14 +133,14 @@ public class AllEntriesCursor extends Ab
     /**
      * {@inheritDoc}
      */
-    public IndexEntry<UUID, UUID> get() throws Exception
+    public IndexEntry<String, String> get() throws Exception
     {
         checkNotClosed( "get()" );
 
         // Create the returned IndexEntry, copying what we get from the wrapped cursor
-        IndexEntry<?, UUID> wrappedEntry = wrapped.get();
-        indexEntry.setId( ( UUID ) wrappedEntry.getKey() );
-        indexEntry.setKey( ( UUID ) wrappedEntry.getKey() );
+        IndexEntry<?, String> wrappedEntry = wrapped.get();
+        indexEntry.setId( ( String ) wrappedEntry.getKey() );
+        indexEntry.setKey( ( String ) wrappedEntry.getKey() );
         indexEntry.setEntry( ( Entry ) wrappedEntry.getTuple().getValue() );
 
         return indexEntry;

Modified: directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/cursor/AndCursor.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/cursor/AndCursor.java?rev=1378653&r1=1378652&r2=1378653&view=diff
==============================================================================
--- directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/cursor/AndCursor.java (original)
+++ directory/apacheds/branches/apacheds-mvbt/xdbm-partition/src/main/java/org/apache/directory/server/xdbm/search/cursor/AndCursor.java Wed Aug 29 17:13:56 2012
@@ -23,7 +23,6 @@ package org.apache.directory.server.xdbm
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.List;
-import java.util.UUID;
 
 import org.apache.directory.server.i18n.I18n;
 import org.apache.directory.server.xdbm.AbstractIndexCursor;
@@ -51,7 +50,7 @@ public class AndCursor<V> extends Abstra
     private static final String UNSUPPORTED_MSG = I18n.err( I18n.ERR_707 );
 
     /** */
-    private final Cursor<IndexEntry<V, UUID>> wrapped;
+    private final Cursor<IndexEntry<V, String>> wrapped;
 
     /** The evaluators used for the members of the And filter */
     private final List<Evaluator<? extends ExprNode>> evaluators;
@@ -64,7 +63,7 @@ public class AndCursor<V> extends Abstra
      * @param wrapped The encapsulated IndexCursor
      * @param evaluators The list of evaluators associated wth the elements
      */
-    public AndCursor( Cursor<IndexEntry<V, UUID>> wrapped,
+    public AndCursor( Cursor<IndexEntry<V, String>> wrapped,
         List<Evaluator<? extends ExprNode>> evaluators )
     {
         LOG_CURSOR.debug( "Creating AndCursor {}", this );
@@ -135,7 +134,7 @@ public class AndCursor<V> extends Abstra
         {
             checkNotClosed( "previous()" );
 
-            IndexEntry<V, UUID> candidate = wrapped.get();
+            IndexEntry<V, String> candidate = wrapped.get();
 
             if ( matches( candidate ) )
             {
@@ -155,7 +154,7 @@ public class AndCursor<V> extends Abstra
         while ( wrapped.next() )
         {
             checkNotClosed( "next()" );
-            IndexEntry<V, UUID> candidate = wrapped.get();
+            IndexEntry<V, String> candidate = wrapped.get();
 
             if ( matches( candidate ) )
             {
@@ -170,7 +169,7 @@ public class AndCursor<V> extends Abstra
     /**
      * {@inheritDoc}
      */
-    public IndexEntry<V, UUID> get() throws Exception
+    public IndexEntry<V, String> get() throws Exception
     {
         checkNotClosed( "get()" );
 
@@ -232,7 +231,7 @@ public class AndCursor<V> extends Abstra
     /**
      * Checks if the entry is a valid candidate by using the evaluators.
      */
-    private boolean matches( IndexEntry<V, UUID> indexEntry ) throws Exception
+    private boolean matches( IndexEntry<V, String> indexEntry ) throws Exception
     {
         for ( Evaluator<?> evaluator : evaluators )
         {



Mime
View raw message