Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-3656

IndexReader's add/removeCloseListener should not use ConcurrentHashMap, just a synchronized set

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 3.5, 4.0-ALPHA
    • 3.6, 4.0-ALPHA
    • core/index
    • New

    Description

      The use-case for ConcurrentHashMap is when many threads are reading and less writing to the structure. Here this is just funny: The only reader is close(). Here you can just use a synchronized HashSet. The complexity of CHM is making this just a joke

      Attachments

        1. LUCENE-3656.patch
          5 kB
          Uwe Schindler
        2. LUCENE-3656.patch
          3 kB
          Uwe Schindler

        Activity

          People

            uschindler Uwe Schindler
            uschindler Uwe Schindler
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: