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

Facet counts in FacetsAccumulator.facetArrays are multiplied as many times as FacetsCollector.getFacetResults is called.

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 4.2
    • Fix Version/s: 4.3, 6.0
    • Component/s: modules/facet
    • Labels:
      None
    • Lucene Fields:
      New, Patch Available

      Description

      In lucene 4.1, only StandardFacetsAccumulator could be instantiated.
      And as of lucene 4.2, it became possible to instantiate FacetsAccumulator.

      I invoked FacetsCollector.getFacetResults twice, and I saw doubled facet counts.
      If I invoke it three times, I see facet counts multiplied three times.
      It all happens in FacetsAccumulator.accumulate.

      StandardFacetsAccumulator doesn't have this bug since it frees facetArrays whenever StandardFacetsAccumulator.accumulate is called.

      Is it a feature or a bug?

        Attachments

        1. LUCENE-4893.patch
          7 kB
          Shai Erera
        2. LUCENE-4893.patch
          10 kB
          Shai Erera
        3. LUCENE-4893.patch
          7 kB
          Shai Erera
        4. LUCENE-4893.patch
          6 kB
          Shai Erera

          Activity

            People

            • Assignee:
              shaie Shai Erera
              Reporter:
              crocket crocket
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: