You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@directory.apache.org by "Carlo Accorsi (JIRA)" <ji...@apache.org> on 2012/05/11 15:44:51 UTC

[jira] [Created] (DIRSERVER-1724) Attribute indexes not updated after entry modification

Carlo Accorsi created DIRSERVER-1724:
----------------------------------------

             Summary: Attribute indexes not updated after entry modification
                 Key: DIRSERVER-1724
                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1724
             Project: Directory ApacheDS
          Issue Type: Bug
          Components: core
    Affects Versions: 2.0.0-M7
         Environment: Win x64
            Reporter: Carlo Accorsi
            Priority: Minor


We setup a partition and configure the attributes we want to index. Import all our users via LDIF and ApacheDS studio and everything works great. 
If a modification is made to an indexed attribute, for example displayName, that entry cannot be found either with an exact or substring match. 

Consider this:
diaplayName: Test User1
After initial import of LDIF import, the following searches will return a result. 
displayName=Test User1
displayName=Test*

If the attribute is modified, to Test User2, neither of the searches below yield any result. 
displayName=Test User2
displayName=Test*



--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (DIRSERVER-1724) Attribute indexes not updated after entry modification

Posted by "Carlo Accorsi (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DIRSERVER-1724?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13274729#comment-13274729 ] 

Carlo Accorsi commented on DIRSERVER-1724:
------------------------------------------

To clarify 'modification' this was done two ways. Manually editing the value in the using the Apache Studio and programatically with the JNDI  javax.naming.ldap.LdapContext interface.
Subsequent searches for the new value return no result. 


                
> Attribute indexes not updated after entry modification
> ------------------------------------------------------
>
>                 Key: DIRSERVER-1724
>                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1724
>             Project: Directory ApacheDS
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 2.0.0-M7
>         Environment: Win x64
>            Reporter: Carlo Accorsi
>            Priority: Minor
>
> We setup a partition and configure the attributes we want to index. Import all our users via LDIF and ApacheDS studio and everything works great. 
> If a modification is made to an indexed attribute, for example displayName, that entry cannot be found either with an exact or substring match. 
> Consider this:
> diaplayName: Test User1
> After initial import of LDIF import, the following searches will return a result. 
> displayName=Test User1
> displayName=Test*
> If the attribute is modified, to Test User2, neither of the searches below yield any result. 
> displayName=Test User2
> displayName=Test*

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (DIRSERVER-1724) Attribute indexes not updated after entry modification

Posted by "Carlo Accorsi (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DIRSERVER-1724?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13275907#comment-13275907 ] 

Carlo Accorsi commented on DIRSERVER-1724:
------------------------------------------

BTW, displayName is an indexed attribute.
                
> Attribute indexes not updated after entry modification
> ------------------------------------------------------
>
>                 Key: DIRSERVER-1724
>                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1724
>             Project: Directory ApacheDS
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 2.0.0-M7
>         Environment: Win x64
>            Reporter: Carlo Accorsi
>            Priority: Minor
>
> We setup a partition and configure the attributes we want to index. Import all our users via LDIF and ApacheDS studio and everything works great. 
> If a modification is made to an indexed attribute, for example displayName, that entry cannot be found either with an exact or substring match. 
> Consider this:
> diaplayName: Test User1
> After initial import of LDIF import, the following searches will return a result. 
> displayName=Test User1
> displayName=Test*
> If the attribute is modified, to Test User2, neither of the searches below yield any result. 
> displayName=Test User2
> displayName=Test*

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (DIRSERVER-1724) Attribute indexes not updated after entry modification

Posted by "Carlo Accorsi (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DIRSERVER-1724?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13275900#comment-13275900 ] 

Carlo Accorsi commented on DIRSERVER-1724:
------------------------------------------

Hi, yes I rebuilt everything from scratch from the trunk yesterday. Still cannot search after modification. 
I'm limiting my testing to Apache Directory Studio. Version: 1.5.3.v20100330

Here is the log of my modification. 
#!RESULT OK
#!CONNECTION ldap://10.1.2.112:10389
#!DATE 2012-05-15T11:23:51.400
dn: uid=1337085976640,ou=users,ou=int,o=cpro
changetype: modify
replace: displayName
displayName: CATest User New

A couple mins later, I try and search for 'CATest*' and there are no results.
Is there an internal timeout for searching? Is there a parameter for this?  If I dump the user out (ldif) and re-import, I can find it via search. 

#!SEARCH REQUEST (146) OK
#!CONNECTION ldap://10.1.2.112:10389
#!DATE 2012-05-15T11:26:23.495
# LDAP URL     : ldap://10.1.2.112:10389/ou=users,ou=int,o=cpro?hasSubordinates,objectClass?one?(displayName=CATest*)
# command line : ldapsearch -H ldap://10.1.2.112:10389 -x -D "uid=admin,ou=system" -W -b "ou=users,ou=int,o=cpro" -s one -a always -z 1000 "(displayName=CATest*)" "hasSubordinates" "objectClass"
# baseObject   : ou=users,ou=int,o=cpro
# scope        : singleLevel (1)
# derefAliases : derefAlways (3)
# sizeLimit    : 1000
# timeLimit    : 0
# typesOnly    : False
# filter       : (displayName=CATest*)
# attributes   : hasSubordinates objectClass

#!SEARCH RESULT DONE (146) OK
#!CONNECTION ldap://10.1.2.112:10389
#!DATE 2012-05-15T11:26:23.495
# numEntries : 0

                
> Attribute indexes not updated after entry modification
> ------------------------------------------------------
>
>                 Key: DIRSERVER-1724
>                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1724
>             Project: Directory ApacheDS
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 2.0.0-M7
>         Environment: Win x64
>            Reporter: Carlo Accorsi
>            Priority: Minor
>
> We setup a partition and configure the attributes we want to index. Import all our users via LDIF and ApacheDS studio and everything works great. 
> If a modification is made to an indexed attribute, for example displayName, that entry cannot be found either with an exact or substring match. 
> Consider this:
> diaplayName: Test User1
> After initial import of LDIF import, the following searches will return a result. 
> displayName=Test User1
> displayName=Test*
> If the attribute is modified, to Test User2, neither of the searches below yield any result. 
> displayName=Test User2
> displayName=Test*

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Resolved] (DIRSERVER-1724) Attribute indexes not updated after entry modification

Posted by "Emmanuel Lecharny (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DIRSERVER-1724?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Emmanuel Lecharny resolved DIRSERVER-1724.
------------------------------------------

    Resolution: Fixed

Fixed with http://svn.apache.org/viewvc?rev=1353518&view=rev
                
> Attribute indexes not updated after entry modification
> ------------------------------------------------------
>
>                 Key: DIRSERVER-1724
>                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1724
>             Project: Directory ApacheDS
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 2.0.0-M7
>         Environment: Win x64
>            Reporter: Carlo Accorsi
>            Priority: Minor
>
> We setup a partition and configure the attributes we want to index. Import all our users via LDIF and ApacheDS studio and everything works great. 
> If a modification is made to an indexed attribute, for example displayName, that entry cannot be found either with an exact or substring match. 
> Consider this:
> diaplayName: Test User1
> After initial import of LDIF import, the following searches will return a result. 
> displayName=Test User1
> displayName=Test*
> If the attribute is modified, to Test User2, neither of the searches below yield any result. 
> displayName=Test User2
> displayName=Test*

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (DIRSERVER-1724) Attribute indexes not updated after entry modification

Posted by "Emmanuel Lecharny (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DIRSERVER-1724?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13274761#comment-13274761 ] 

Emmanuel Lecharny commented on DIRSERVER-1724:
----------------------------------------------

Is this against the trunk ? Have you tried against the latest released version (ie 2.0.0-M7, available here : http://people.apache.org/~elecharny/). ?

                
> Attribute indexes not updated after entry modification
> ------------------------------------------------------
>
>                 Key: DIRSERVER-1724
>                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1724
>             Project: Directory ApacheDS
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 2.0.0-M7
>         Environment: Win x64
>            Reporter: Carlo Accorsi
>            Priority: Minor
>
> We setup a partition and configure the attributes we want to index. Import all our users via LDIF and ApacheDS studio and everything works great. 
> If a modification is made to an indexed attribute, for example displayName, that entry cannot be found either with an exact or substring match. 
> Consider this:
> diaplayName: Test User1
> After initial import of LDIF import, the following searches will return a result. 
> displayName=Test User1
> displayName=Test*
> If the attribute is modified, to Test User2, neither of the searches below yield any result. 
> displayName=Test User2
> displayName=Test*

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (DIRSERVER-1724) Attribute indexes not updated after entry modification

Posted by "Emmanuel Lecharny (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DIRSERVER-1724?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13276745#comment-13276745 ] 

Emmanuel Lecharny commented on DIRSERVER-1724:
----------------------------------------------

What is strange is that the test I have added into the Ldap-client tests works, even for substring searches :

http://svn.apache.org/viewvc/directory/apacheds/trunk/ldap-client-test/src/test/java/org/apache/directory/shared/client/api/operations/search/OperationWithIndexTest.java?view=markup

Check the testModify() test, where you can find :


262 	connection.modify( dn, new DefaultModification( ModificationOperation.REPLACE_ATTRIBUTE, "displayName", "test" ) );
263 	
264 	results = connection.search("dc=example,dc=com", "(displayName=t*)", SearchScope.SUBTREE, "*" );
265 	
266 	while ( results.next() )
267 	{
268 	Entry result = results.get();
269 	assertTrue( result.contains( "displayName", "test" ) );
270 	}


                
> Attribute indexes not updated after entry modification
> ------------------------------------------------------
>
>                 Key: DIRSERVER-1724
>                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1724
>             Project: Directory ApacheDS
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 2.0.0-M7
>         Environment: Win x64
>            Reporter: Carlo Accorsi
>            Priority: Minor
>
> We setup a partition and configure the attributes we want to index. Import all our users via LDIF and ApacheDS studio and everything works great. 
> If a modification is made to an indexed attribute, for example displayName, that entry cannot be found either with an exact or substring match. 
> Consider this:
> diaplayName: Test User1
> After initial import of LDIF import, the following searches will return a result. 
> displayName=Test User1
> displayName=Test*
> If the attribute is modified, to Test User2, neither of the searches below yield any result. 
> displayName=Test User2
> displayName=Test*

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (DIRSERVER-1724) Attribute indexes not updated after entry modification

Posted by "Carlo Accorsi (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DIRSERVER-1724?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13400554#comment-13400554 ] 

Carlo Accorsi commented on DIRSERVER-1724:
------------------------------------------


Correction was tested and it works on revision 1353518 
http://svn.apache.org/viewvc/directory/apacheds/trunk/xdbm-partition/src/main/java/org/apache/directory/server/core/partition/impl/btree/AbstractBTreePartition.java?r1=1332268&r2=1353518&pathrev=1353518

Thanks!!
                
> Attribute indexes not updated after entry modification
> ------------------------------------------------------
>
>                 Key: DIRSERVER-1724
>                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1724
>             Project: Directory ApacheDS
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 2.0.0-M7
>         Environment: Win x64
>            Reporter: Carlo Accorsi
>            Priority: Minor
>
> We setup a partition and configure the attributes we want to index. Import all our users via LDIF and ApacheDS studio and everything works great. 
> If a modification is made to an indexed attribute, for example displayName, that entry cannot be found either with an exact or substring match. 
> Consider this:
> diaplayName: Test User1
> After initial import of LDIF import, the following searches will return a result. 
> displayName=Test User1
> displayName=Test*
> If the attribute is modified, to Test User2, neither of the searches below yield any result. 
> displayName=Test User2
> displayName=Test*

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (DIRSERVER-1724) Attribute indexes not updated after entry modification

Posted by "Carlo Accorsi (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DIRSERVER-1724?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13276714#comment-13276714 ] 

Carlo Accorsi commented on DIRSERVER-1724:
------------------------------------------

This issue is limited to a substring search. As you can see from the results below (displayName=Index, Test) yields a result, while (displayName=Index, Tes*) does not. 
Is there any way to explain this? Am i doing something wrong? 

#!SEARCH REQUEST (130) OK
#!CONNECTION ldap://10.1.2.112:10389
#!DATE 2012-05-16T08:56:25.248
# LDAP URL     : ldap://10.1.2.112:10389/ou=users,ou=int,o=cpro?hasSubordinates,objectClass?one?(displayName=Index,%20Test)
# command line : ldapsearch -H ldap://10.1.2.112:10389 -x -D "uid=admin,ou=system" -W -b "ou=users,ou=int,o=cpro" -s one -a always -z 1000 "(displayName=Index, Test)" "hasSubordinates" "objectClass"
# baseObject   : ou=users,ou=int,o=cpro
# scope        : singleLevel (1)
# derefAliases : derefAlways (3)
# sizeLimit    : 1000
# timeLimit    : 0
# typesOnly    : False
# filter       : (displayName=Index, Test)
# attributes   : hasSubordinates objectClass

#!SEARCH RESULT DONE (130) OK
#!CONNECTION ldap://10.1.2.112:10389
#!DATE 2012-05-16T08:56:25.248
# numEntries : 1


#!SEARCH REQUEST (134) OK
#!CONNECTION ldap://10.1.2.112:10389
#!DATE 2012-05-16T08:58:50.287
# LDAP URL     : ldap://10.1.2.112:10389/ou=users,ou=int,o=cpro?hasSubordinates,objectClass?one?(displayName=Index,%20Tes*)
# command line : ldapsearch -H ldap://10.1.2.112:10389 -x -D "uid=admin,ou=system" -W -b "ou=users,ou=int,o=cpro" -s one -a always -z 1000 "(displayName=Index, Tes*)" "hasSubordinates" "objectClass"
# baseObject   : ou=users,ou=int,o=cpro
# scope        : singleLevel (1)
# derefAliases : derefAlways (3)
# sizeLimit    : 1000
# timeLimit    : 0
# typesOnly    : False
# filter       : (displayName=Index, Tes*)
# attributes   : hasSubordinates objectClass

#!SEARCH RESULT DONE (134) OK
#!CONNECTION ldap://10.1.2.112:10389
#!DATE 2012-05-16T08:58:50.287
# numEntries : 0
                
> Attribute indexes not updated after entry modification
> ------------------------------------------------------
>
>                 Key: DIRSERVER-1724
>                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1724
>             Project: Directory ApacheDS
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 2.0.0-M7
>         Environment: Win x64
>            Reporter: Carlo Accorsi
>            Priority: Minor
>
> We setup a partition and configure the attributes we want to index. Import all our users via LDIF and ApacheDS studio and everything works great. 
> If a modification is made to an indexed attribute, for example displayName, that entry cannot be found either with an exact or substring match. 
> Consider this:
> diaplayName: Test User1
> After initial import of LDIF import, the following searches will return a result. 
> displayName=Test User1
> displayName=Test*
> If the attribute is modified, to Test User2, neither of the searches below yield any result. 
> displayName=Test User2
> displayName=Test*

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira