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

FieldCache keeps hard references to readers, doesn't prevent multiple threads from creating same instance

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Lucene Fields:
      New
    1. FieldCache.patch
      0.5 kB
      Yonik Seeley

      Activity

      Hide
      yseeley@gmail.com Yonik Seeley added a comment -

      typo in original (used reader instead of key)

      Show
      yseeley@gmail.com Yonik Seeley added a comment - typo in original (used reader instead of key)
      Hide
      manawiz Chuck Williams added a comment -

      Cool! This should solve at least part of my problem. Trying this now (along with finalizer removal patch that is already installed here). Will report back results.

      Thanks!

      Show
      manawiz Chuck Williams added a comment - Cool! This should solve at least part of my problem. Trying this now (along with finalizer removal patch that is already installed here). Will report back results. Thanks!
      Hide
      manawiz Chuck Williams added a comment -

      This patch, together with LUCENE-750 (already committed) solved our problem completely. It sped up simultaneous multi-threaded searches with a new ParallelReader against a 1 million item investigation that has a unique id sort field (i.e., 1 million entry FIeldCache must be created) by a factor of 15x.

      Thanks Yonik! +1 to commit this.

      Show
      manawiz Chuck Williams added a comment - This patch, together with LUCENE-750 (already committed) solved our problem completely. It sped up simultaneous multi-threaded searches with a new ParallelReader against a 1 million item investigation that has a unique id sort field (i.e., 1 million entry FIeldCache must be created) by a factor of 15x. Thanks Yonik! +1 to commit this.
      Hide
      yseeley@gmail.com Yonik Seeley added a comment -

      patch committed.

      Show
      yseeley@gmail.com Yonik Seeley added a comment - patch committed.
      Hide
      ohutchison Oliver Hutchison added a comment -

      Chuck and whoever else got burned by this - really big apology for letting that typo slip into my patch Unfortunately because I was constrained to use a release version of Lucene I ended up implementing a different solution in our production system and obviously I didn't pick up the mistake I'd made in the patch.

      Show
      ohutchison Oliver Hutchison added a comment - Chuck and whoever else got burned by this - really big apology for letting that typo slip into my patch Unfortunately because I was constrained to use a release version of Lucene I ended up implementing a different solution in our production system and obviously I didn't pick up the mistake I'd made in the patch.
      Hide
      otis Otis Gospodnetic added a comment -

      Since I was the one who first whined about this leak, I'm just following up to report that this change indeed eliminated the leak.

      Show
      otis Otis Gospodnetic added a comment - Since I was the one who first whined about this leak, I'm just following up to report that this change indeed eliminated the leak.

        People

        • Assignee:
          yseeley@gmail.com Yonik Seeley
          Reporter:
          yseeley@gmail.com Yonik Seeley
        • Votes:
          0 Vote for this issue
          Watchers:
          1 Start watching this issue

          Dates

          • Created:
            Updated:
            Resolved:

            Development