From users-return-4407-apmail-directory-users-archive=directory.apache.org@directory.apache.org Wed Feb 1 23:19:09 2012 Return-Path: X-Original-To: apmail-directory-users-archive@www.apache.org Delivered-To: apmail-directory-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 750F2964A for ; Wed, 1 Feb 2012 23:19:09 +0000 (UTC) Received: (qmail 85383 invoked by uid 500); 1 Feb 2012 23:19:09 -0000 Delivered-To: apmail-directory-users-archive@directory.apache.org Received: (qmail 85335 invoked by uid 500); 1 Feb 2012 23:19:08 -0000 Mailing-List: contact users-help@directory.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@directory.apache.org Delivered-To: mailing list users@directory.apache.org Received: (qmail 85327 invoked by uid 99); 1 Feb 2012 23:19:08 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Feb 2012 23:19:08 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of akarasulu@gmail.com designates 209.85.212.178 as permitted sender) Received: from [209.85.212.178] (HELO mail-wi0-f178.google.com) (209.85.212.178) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Feb 2012 23:19:00 +0000 Received: by wibhm14 with SMTP id hm14so1748233wib.37 for ; Wed, 01 Feb 2012 15:18:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:content-type; bh=vRTOzogWjkXAIcjjpKpFv9ttfn2WW2wlodHQO3NSVns=; b=E79yOW8rRYvEu7DMyxDqJgeg8+JUPZIJBOm1c82FCk7l/f+ENANQpaNQh9wgADp9QE 0wb/CYGI4B/73IVowB1GLNPP7OYRrSFZ+fSaxQc2+XEzG+dDsIvPp/ucmnW28hSxwYb8 zVYk7NoOrJqJBsVGoImjO1m99x5FUEmVJlTrY= MIME-Version: 1.0 Received: by 10.180.107.68 with SMTP id ha4mr854939wib.9.1328138320247; Wed, 01 Feb 2012 15:18:40 -0800 (PST) Sender: akarasulu@gmail.com Received: by 10.180.82.164 with HTTP; Wed, 1 Feb 2012 15:18:40 -0800 (PST) In-Reply-To: <4F29C76F.1000003@gmail.com> References: <4F28CAB5.5050808@gmail.com> <60C70C0D-8C23-4E39-B798-7B8227AC9F35@marcelot.net> <4F290874.5080702@gmail.com> <4F292163.5040807@gmail.com> <0F2831C9-13A5-4A8A-99FD-98E1C4F4DEDB@marcelot.net> <4F292E71.1060508@gmail.com> <427D2871-456D-4EBD-A5AF-DC2D8120819E@marcelot.net> <4F293331.1010108@gmail.com> <4F293ABA.9070901@gmail.com> <4F299E4B.8000409@gmail.com> <4F29C76F.1000003@gmail.com> Date: Thu, 2 Feb 2012 01:18:40 +0200 X-Google-Sender-Auth: vQ7yBBIyxgbhM4cqmrO7R-tElAg Message-ID: Subject: Re: connection.exists(Dn) is false although entry exists From: Alex Karasulu To: users@directory.apache.org Content-Type: multipart/alternative; boundary=e89a8f13ec34ca7d1b04b7ef4cf5 X-Virus-Checked: Checked by ClamAV on apache.org --e89a8f13ec34ca7d1b04b7ef4cf5 Content-Type: text/plain; charset=ISO-8859-1 On Thu, Feb 2, 2012 at 1:14 AM, Christoph Czurda wrote: > On 02/01/2012 11:58 PM, Alex Karasulu wrote: > > On Wed, Feb 1, 2012 at 10:19 PM, Christoph Czurda > > wrote: > > > >> Hi Pierre-Arnaud, > >> > >> The mistake was on my side. I used Rdn rdn = new Rdn("cn=a,ou=b"); and > >> passed this to a Dn constructor. I misinterpreted the description of > >> class Rdn where it says that any String with a '=' is treated as a full > >> Rdn. When I changed it, it worked as expected. > >> > >> > > Just curious can you show me the offending code? I really did not > > understand your description. > > > > I ask this because it might show which area of our API is weak in terms > of > > being intuitive. If the user understands the domain a good API shows > > exactly how it should be used by the object model and methods. > > > > > It was like this: > Dn parent = new Dn("ou=system"); > Dn somewhereBelow = new Dn(new Rdn("cn=a,cn=b"),parent); //the problem > was the rdn > > I thought that in this constructor everything before the parent is > simply prepended. So if understand correctly you thought Rdn is not a single name component but one that can have 1 or more name components like for example a relative path in the fs namespace? > The interesting thing is that dn.getName() did what I > actually intended, ie it returns "cn=a,cn=b,ou=system". > > Odd. Thanks for the feedback. -- Best Regards, -- Alex --e89a8f13ec34ca7d1b04b7ef4cf5--