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

Highlighter doesn't support ConstantScoreQuery

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.6.1, 4.0
    • Fix Version/s: 4.1, 6.0
    • Component/s: modules/highlighter
    • Labels:
      None
    • Lucene Fields:
      New, Patch Available

      Description

      if you wrap a query into a constant score the highlighter fails to highlight since ConstantScoreQuery is not recognized in WeightedSpanTermExtractor

      1. LUCENE-4486.patch
        3 kB
        Simon Willnauer

        Activity

        Hide
        simonw Simon Willnauer added a comment -

        here is a patch incl. test & changes entry

        Show
        simonw Simon Willnauer added a comment - here is a patch incl. test & changes entry
        Hide
        mikemccand Michael McCandless added a comment -

        +1

        Show
        mikemccand Michael McCandless added a comment - +1
        Hide
        simonw Simon Willnauer added a comment -

        committed to trunk in revision 1399205.
        backported to 4.x in revision 1399207.

        Show
        simonw Simon Willnauer added a comment - committed to trunk in revision 1399205. backported to 4.x in revision 1399207.
        Hide
        iorixxx Ahmet Arslan added a comment -

        I am wondering about if it is possible to enable highlighter support for SrndQuery and ComplexPhraseQuery by using this patch's solution?

        Show
        iorixxx Ahmet Arslan added a comment - I am wondering about if it is possible to enable highlighter support for SrndQuery and ComplexPhraseQuery by using this patch's solution?
        Hide
        simonw Simon Willnauer added a comment -

        I am wondering about if it is possible to enable highlighter support for SrndQuery and ComplexPhraseQuery by using this patch's solution?

        I'd think so. I'm just not sure if those should be added really. It seems they should be translated to other/more core queries first?

        Show
        simonw Simon Willnauer added a comment - I am wondering about if it is possible to enable highlighter support for SrndQuery and ComplexPhraseQuery by using this patch's solution? I'd think so. I'm just not sure if those should be added really. It seems they should be translated to other/more core queries first?
        Hide
        commit-tag-bot Commit Tag Bot added a comment -

        [branch_4x commit] Simon Willnauer
        http://svn.apache.org/viewvc?view=revision&revision=1399207

        LUCENE-4486: Add support for ConstantScoreQuery in Highlighter.

        Show
        commit-tag-bot Commit Tag Bot added a comment - [branch_4x commit] Simon Willnauer http://svn.apache.org/viewvc?view=revision&revision=1399207 LUCENE-4486 : Add support for ConstantScoreQuery in Highlighter.

          People

          • Assignee:
            simonw Simon Willnauer
            Reporter:
            simonw Simon Willnauer
          • Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development