You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@directory.apache.org by Stefan Seelmann <ma...@stefan-seelmann.de> on 2021/06/19 14:46:44 UTC

Re: [directory-ldap-api] branch master updated: Fixed root DSE access (abandon requests after wrong handling of search cursor)

Hi Radovan,

was this change in getRootDse() on purpose?

I noticed it because of a test failure in the server's test [1] when I
switch the API version to 2.0.3-SNAPSHOT.

But I agree with the change, it's the operational attributes that are of
interest when fetching it :-)

Kind Regards,
Stefan

[1]
https://github.com/apache/directory-server/blob/master/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/GetRootDseTest.java#L80


> diff --git a/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java b/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
> index 0d425a3..26c4db2 100644
> --- a/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
> +++ b/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
> @@ -4301,7 +4301,7 @@ public class LdapNetworkConnection extends AbstractLdapConnection implements Lda
>      @Override
>      public Entry getRootDse() throws LdapException
>      {
> -        return lookup( Dn.ROOT_DSE, SchemaConstants.ALL_USER_ATTRIBUTES_ARRAY );
> +        return lookup( Dn.ROOT_DSE, SchemaConstants.ALL_ATTRIBUTES_ARRAY );
>      }

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@directory.apache.org
For additional commands, e-mail: dev-help@directory.apache.org


Re: [directory-ldap-api] branch master updated: Fixed root DSE access (abandon requests after wrong handling of search cursor)

Posted by Radovan Semancik <ra...@evolveum.com.INVALID>.
Hi,

Yes, it was on purpose. I have discussed a similar problem with Emmanuel 
few years ago. In practice, all interesting information in root DSE are 
operational attributes. Therefore there is almost no sense in fetching 
root DSE with "*" and without "+". I was fixing the code at several 
places back than, but I have obviously missed this one.

Sorry for that test failure. I have built the API with the usual "mvn 
clean install" and the build was successful, before I made a commit. I'm 
always forgetting that there is a second test suite for the API in the 
server code.

-- 
Radovan Semancik
Software Architect
evolveum.com

On 19. 6. 2021 16:46, Stefan Seelmann wrote:
> Hi Radovan,
>
> was this change in getRootDse() on purpose?
>
> I noticed it because of a test failure in the server's test [1] when I
> switch the API version to 2.0.3-SNAPSHOT.
>
> But I agree with the change, it's the operational attributes that are of
> interest when fetching it :-)
>
> Kind Regards,
> Stefan
>
> [1]
> https://github.com/apache/directory-server/blob/master/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/GetRootDseTest.java#L80
>
>
>> diff --git a/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java b/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
>> index 0d425a3..26c4db2 100644
>> --- a/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
>> +++ b/ldap/client/api/src/main/java/org/apache/directory/ldap/client/api/LdapNetworkConnection.java
>> @@ -4301,7 +4301,7 @@ public class LdapNetworkConnection extends AbstractLdapConnection implements Lda
>>       @Override
>>       public Entry getRootDse() throws LdapException
>>       {
>> -        return lookup( Dn.ROOT_DSE, SchemaConstants.ALL_USER_ATTRIBUTES_ARRAY );
>> +        return lookup( Dn.ROOT_DSE, SchemaConstants.ALL_ATTRIBUTES_ARRAY );
>>       }
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@directory.apache.org
> For additional commands, e-mail: dev-help@directory.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@directory.apache.org
For additional commands, e-mail: dev-help@directory.apache.org