Uploaded image for project: 'Directory ApacheDS'
  1. Directory ApacheDS
  2. DIRSERVER-1058

context.search errors on embedded apacheds 1.5.1

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Won't Fix
    • 1.5.1
    • 1.5.2
    • ldap
    • None

    Description

      I have talked to elecharny on this on irc but I have it isolated into a single artifact and have it manifesting on 1.5.1 now.

      https://svn.codehaus.org/plexus/plexus-sandbox/trunk/plexus-apacheds

      just running 'mvn test' will show the error.

      Two things are in play here

      1) the search filter should be (&(objectClass=inetOrgPerson)(cn=trygvis)) but this doesn't return anything...changing it to just the (cn=trygvis) will return a record though.

      2) that record looks to have the following attributes which would explain why the objectClass=inetOrgPerson check would fail, its not in here.

      Attributes
      Attribute id : 'objectClass', Values : ['javaObject', 'javaContainer', 'javaSerializedObject', 'top']
      Attribute id : 'cn', Values : ['trygvis']
      Attribute id : 'javaSerializedData', Values : [0xAC 0xED 0x00 0x05 0x73 0x72 0x00 0x26 0x6A 0x61 0x76 0x61 0x78 0x2E 0x6E 0x61 0x6D 0x69 0x6E 0x67 0x2E 0x64 0x69 0x72 0x65 0x63 0x74 0x6F 0x72 0x79 0x2E 0x42 0x61 0x73 0x69 0x63 0x41 0x74 0x74 0x72 0x69 0x62 0x75 0x74 0x65 0x73 0x45 0x1D 0x18 0xD6 0xA9 0x55 0x39 0xD8 0x03 0x00 0x01 0x5A 0x00 0x0A 0x69 0x67 0x6E 0x6F 0x72 0x65 0x43 0x61 0x73 0x65 0x78 0x70 0x00 0x77 0x04 0x00 0x00 0x00 0x03 0x73 0x72 0x00 0x25 0x6A 0x61 0x76 0x61 0x78 0x2E 0x6E 0x61 0x6D 0x69 0x6E 0x67 0x2E 0x64 0x69 0x72 0x65 0x63 0x74 0x6F 0x72 0x79 0x2E 0x42 0x61 0x73 0x69 0x63 0x41 0x74 0x74 0x72 0x69 0x62 0x75 0x74 0x65 0x5D 0x95 0xD3 0x2A 0x66 0x85 0x65 0xBE 0x03 0x00 0x02 0x5A 0x00 0x07 0x6F 0x72 0x64 0x65 0x72 0x65 0x64 0x4C 0x00 0x06 0x61 0x74 0x74 0x72 0x49 0x44 0x74 0x00 0x12 0x4C 0x6A 0x61 0x76 0x61 0x2F 0x6C 0x61 0x6E 0x67 0x2F 0x53 0x74 0x72 0x69 0x6E 0x67 0x3B 0x78 0x70 0x00 0x74 0x00 0x0B 0x6F 0x62 0x6A 0x65 0x63 0x74 0x43 0x6C 0x61 0x73 0x73 0x77 0x04 0x00 0x00 0x00 0x02 0x74 0x00 0x03 0x74 0x6F 0x70 0x74 0x00 0x0D 0x69 0x6E 0x65 0x74 0x4F 0x72 0x67 0x50 0x65 0x72 0x73 0x6F 0x6E 0x78 0x73 0x71 0x00 0x7E 0x00 0x02 0x00 0x74 0x00 0x08 0x74 0x65 0x73 0x74 0x41 0x74 0x74 0x72 0x77 0x04 0x00 0x00 0x00 0x01 0x74 0x00 0x04 0x74 0x65 0x73 0x74 0x78 0x73 0x71 0x00 0x7E 0x00 0x02 0x00 0x74 0x00 0x02 0x63 0x6E 0x77 0x04 0x00 0x00 0x00 0x01 0x74 0x00 0x07 0x74 0x72 0x79 0x67 0x76 0x69 0x73 0x78 0x78 ]
      Attribute id : 'javaClassName', Values : ['javax.naming.directory.BasicAttributes']
      Attribute id : 'javaClassNames', Values : []

      Now, if you look at the test case, doing a straight forward Object o = context.lookup( dn ); will return an Attributes object that is coherent and contains the objects I am interested in getting, but the Attributes in the SearchResult are messed up or something.

      Another interesting thing is that the context.search will work successfully with this code if I connect to apacheds running standalone, it seems to manifest this way when its embedded like this.

      Attachments

        Activity

          People

            elecharny Emmanuel Lécharny
            jmcconnell Jesse McConnell
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: