directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kayyag...@apache.org
Subject svn commit: r1561717 - in /directory/apacheds/trunk: core-api/src/main/java/org/apache/directory/server/core/api/entry/ServerEntryUtils.java server-integ/src/test/java/org/apache/directory/server/operations/search/SortedSearchIT.java
Date Mon, 27 Jan 2014 16:06:16 GMT
Author: kayyagari
Date: Mon Jan 27 16:06:16 2014
New Revision: 1561717

URL: http://svn.apache.org/r1561717
Log:
preverve 'entryDn' attribute if requested DIRSERVER-1953

Modified:
    directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/api/entry/ServerEntryUtils.java
    directory/apacheds/trunk/server-integ/src/test/java/org/apache/directory/server/operations/search/SortedSearchIT.java

Modified: directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/api/entry/ServerEntryUtils.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/api/entry/ServerEntryUtils.java?rev=1561717&r1=1561716&r2=1561717&view=diff
==============================================================================
--- directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/api/entry/ServerEntryUtils.java
(original)
+++ directory/apacheds/trunk/core-api/src/main/java/org/apache/directory/server/core/api/entry/ServerEntryUtils.java
Mon Jan 27 16:06:16 2014
@@ -794,7 +794,11 @@ public class ServerEntryUtils
                 }
             }
 
-            entry.removeAttributes( entryDnType );
+            // DIRSERVER-1953
+            if ( !operationContext.contains( schemaManager, entryDnType ) )
+            {
+                entry.removeAttributes( entryDnType );
+            }
             
             return;
         }

Modified: directory/apacheds/trunk/server-integ/src/test/java/org/apache/directory/server/operations/search/SortedSearchIT.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/server-integ/src/test/java/org/apache/directory/server/operations/search/SortedSearchIT.java?rev=1561717&r1=1561716&r2=1561717&view=diff
==============================================================================
--- directory/apacheds/trunk/server-integ/src/test/java/org/apache/directory/server/operations/search/SortedSearchIT.java
(original)
+++ directory/apacheds/trunk/server-integ/src/test/java/org/apache/directory/server/operations/search/SortedSearchIT.java
Mon Jan 27 16:06:16 2014
@@ -100,8 +100,11 @@ public class SortedSearchIT extends Abst
         req.setBase( baseDn );
         req.setFilter( filter );
         req.setScope( SearchScope.SUBTREE );
-        req.addAttributes( SchemaConstants.ALL_ATTRIBUTES_ARRAY );
-
+        
+        // let the tests also test for DIRSERVER-1953
+        req.addAttributes( SchemaConstants.ALL_USER_ATTRIBUTES_ARRAY );
+        req.addAttributes( SchemaConstants.ENTRY_DN_AT );
+        
         // tests may overwrite the fields of the below SortKey instance
         sk = new SortKey( "entryDn" );
         ctrl = new SortRequestControlImpl();



Mime
View raw message