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

Missing entry due to timing issue with persistent LDAP search

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 2.0.0.AM25
    • None
    • control
    • None

    Description

      LDAP search using PersistentSearchControl with changesOnly=false must return all existing entries followed by any changes so that the client sees all entries (https://tools.ietf.org/html/draft-ietf-ldapext-psearch-03). The current implementation processes all existing entries and then sets up a listener to process entry changes. This leaves a small timing window where entries created while the existing entries are being processed, but before the persistent listener is created are never returned to the client. We see intermittent test failures as a result of this timing window in tests which start a persistent search and create entries immediately after that.

      The relevant code is here: https://github.com/apache/directory-server/blob/master/protocol-ldap/src/main/java/org/apache/directory/server/ldap/handlers/request/SearchRequestHandler.java#L141

      It is hard to add a workaround for persistent search if all entries are not guaranteed to be returned.

      Attachments

        Activity

          People

            Unassigned Unassigned
            rsivaram Rajini Sivaram
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: