Lucene - Core
  1. Lucene - Core
  2. LUCENE-4913

FacetResultNode.ordinal is always 0 when all facets are requested

    Details

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

      Description

      Silly bug ... we just fail to set the ordinal in IntFacetResultsHandler.

      1. LUCENE-4913.patch
        6 kB
        Shai Erera
      2. LUCENE-4913.patch
        2 kB
        Michael McCandless

        Activity

        Hide
        Michael McCandless added a comment -

        Patch.

        Show
        Michael McCandless added a comment - Patch.
        Hide
        Shai Erera added a comment -

        Good catch. Same fix should be applied to FloatFRH. Also, can you make sure that if StandardFA is used, the ordinal is set?

        Show
        Shai Erera added a comment - Good catch. Same fix should be applied to FloatFRH. Also, can you make sure that if StandardFA is used, the ordinal is set?
        Hide
        Michael McCandless added a comment -

        Same fix should be applied to FloatFRH.

        Ooh I'll fix that. But can you help w/ a testcase?

        Also, can you make sure that if StandardFA is used, the ordinal is set?

        Hmm and also a test case for this? Thanks!

        Show
        Michael McCandless added a comment - Same fix should be applied to FloatFRH. Ooh I'll fix that. But can you help w/ a testcase? Also, can you make sure that if StandardFA is used, the ordinal is set? Hmm and also a test case for this? Thanks!
        Hide
        Shai Erera added a comment -

        Added a test to TestFacetsCollector which asserts both Int and Float FacetResultHandler and alternates between FA and StandardFA.

        Mike, I think the CHANGES entry though is slightly incorrect - it's not related to ALL_PARENTS, but rather to when you ask for all children (or any numResults >= taxo.size())? I didn't fix it in the patch because I wasn't sure if you hit it with ALL_PARENTS too...

        Show
        Shai Erera added a comment - Added a test to TestFacetsCollector which asserts both Int and Float FacetResultHandler and alternates between FA and StandardFA. Mike, I think the CHANGES entry though is slightly incorrect - it's not related to ALL_PARENTS, but rather to when you ask for all children (or any numResults >= taxo.size())? I didn't fix it in the patch because I wasn't sure if you hit it with ALL_PARENTS too...
        Hide
        Michael McCandless added a comment -

        Thanks Shai!

        Mike, I think the CHANGES entry though is slightly incorrect - it's not related to ALL_PARENTS, but rather to when you ask for all children (or any numResults >= taxo.size())?

        Sorry, I had just seen it originally with ALL_PARENTS ... I'll fix the CHANGES and commit!

        Show
        Michael McCandless added a comment - Thanks Shai! Mike, I think the CHANGES entry though is slightly incorrect - it's not related to ALL_PARENTS, but rather to when you ask for all children (or any numResults >= taxo.size())? Sorry, I had just seen it originally with ALL_PARENTS ... I'll fix the CHANGES and commit!
        Hide
        Uwe Schindler added a comment -

        Closed after release.

        Show
        Uwe Schindler added a comment - Closed after release.

          People

          • Assignee:
            Michael McCandless
            Reporter:
            Michael McCandless
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development