directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kiran Ayyagari (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (DIRSERVER-1921) Indexes dont work on distinguishedNameMatch attributeType
Date Sat, 30 Nov 2013 09:48:36 GMT

    [ https://issues.apache.org/jira/browse/DIRSERVER-1921?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13835648#comment-13835648
] 

Kiran Ayyagari commented on DIRSERVER-1921:
-------------------------------------------

I have recently implemented a DN comparator as shown below, which does not depend on the string
values:

    public int compare( Dn dn1, Dn dn2 )
    {
        if( dn1.isAncestorOf( dn2 ) )
        {
            return -1;
        }
        else if( dn2.isAncestorOf( dn1 ) )
        {
            return 1;
        }
        else if ( dn1.equals( dn2 ) )
        {
            return 0;
        }
        
        return 1;
    }


> Indexes dont work on distinguishedNameMatch attributeType
> ---------------------------------------------------------
>
>                 Key: DIRSERVER-1921
>                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1921
>             Project: Directory ApacheDS
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 2.0.0-M15
>            Reporter: lucas theisen
>            Priority: Critical
>              Labels: patch, test
>             Fix For: 2.0.0-RC1
>
>         Attachments: patch.txt
>
>
> When attempting to add an index for an attribute that uses distinguishedNameMatch, items
are not found.  I will attach a patch for the JdbmIndexTest that demonstrates the issue.



--
This message was sent by Atlassian JIRA
(v6.1#6144)

Mime
View raw message