You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-dev@lucene.apache.org by "Mark Miller (JIRA)" <ji...@apache.org> on 2009/06/16 19:09:07 UTC

[jira] Created: (SOLR-1221) Change Solr to use the SpanScorer with MultiTerm expansion by default

Change Solr to use the SpanScorer with MultiTerm expansion by default
---------------------------------------------------------------------

                 Key: SOLR-1221
                 URL: https://issues.apache.org/jira/browse/SOLR-1221
             Project: Solr
          Issue Type: Improvement
            Reporter: Mark Miller
            Assignee: Mark Miller
             Fix For: 1.4


To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.

Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Yonik Seeley (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760079#action_12760079 ] 

Yonik Seeley commented on SOLR-1221:
------------------------------------

bq. What do people thing about putting in an updated Highlighter jar with a fix? 

+1, If there's not an easy way to work around it in Solr.


> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12761757#action_12761757 ] 

Mark Miller commented on SOLR-1221:
-----------------------------------

On first blush, I've got to think the wrapper is better.

We don't lose the few terms -> faster booleanquery that way, and I'm not sure I see any advantage to using CSQ. So its not a huge weight towards the wrapper, but we now have it, and it does weigh that way it would seem to me ...

Uwe?

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Miller updated SOLR-1221:
------------------------------

    Attachment: SOLR-1221.patch

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Miller updated SOLR-1221:
------------------------------

    Attachment: SOLR-1221.patch

fix a compile issue in last patch - param needs to be "true" rather than true.
also adds changes entry.

will commit very soon.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760083#action_12760083 ] 

Mark Miller edited comment on SOLR-1221 at 9/27/09 11:54 AM:
-------------------------------------------------------------

Sorry - should have been more clear.

The bug is hidden on trunk at the moment - Koji pointed out that I missed a spot, and on trunk right now, queries are being rewritten by default when they shouldnt be.

Now that you mention it though, the issue is not just with NumericRange (I just assumed that was being gen'd cause I saw the problem with it), but its also going to be with the
deprecated RangeQuery it looks.

*edit*

which really argues for a jar update - I can fix all causes with one simple fix - checking if getTerm returns null.

      was (Author: markrmiller@gmail.com):
    Sorry - should have been more clear.

The bug is hidden on trunk at the moment - Koji pointed out that I missed a spot, and on trunk right now, queries are being rewritten by default when they shouldnt be.

Now that you mention it though, the issue is not just with NumericRange (I just assumed that was being gen'd cause I saw the problem with it), but its also going to be with the
deprecated RangeQuery it looks.
  
> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Grant Ingersoll (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12753700#action_12753700 ] 

Grant Ingersoll commented on SOLR-1221:
---------------------------------------

Sounds good, Mark.  Please commit when you are ready.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760048#action_12760048 ] 

Mark Miller commented on SOLR-1221:
-----------------------------------

Grrr ... darn it. Its at the Lucene level. NumericQuery doesn't set the Term for getTerm(), so its not supported by the Span Highlighter. Grrr. Not sure what to do at the moment ...

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Uwe Schindler (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12761350#action_12761350 ] 

Uwe Schindler commented on SOLR-1221:
-------------------------------------

Does the highlighter rewrite before checking the query? In this is not the case the simpliest thing to do would be the following: Just wrap it into a Query subclass and rewrite it to NRQ.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Yonik Seeley (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12761749#action_12761749 ] 

Yonik Seeley commented on SOLR-1221:
------------------------------------

bq. Instead of using a NRQ, wrap a NRF with ConstantScoreQuery

Yep, that would work too.  Your call Mark ;-)

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760083#action_12760083 ] 

Mark Miller commented on SOLR-1221:
-----------------------------------

Sorry - should have been more clear.

The bug is hidden on trunk at the moment - Koji pointed out that I missed a spot, and on trunk right now, queries are being rewritten by default when they shouldnt be.

Now that you mention it though, the issue is not just with NumericRange (I just assumed that was being gen'd cause I saw the problem with it), but its also going to be with the
deprecated RangeQuery it looks.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760127#action_12760127 ] 

Mark Miller commented on SOLR-1221:
-----------------------------------

bq. In Lucene, the fix would only be needed for highlighting in 2.9.1, 3.0 will have no RangeQuery anymore.

You can have custom queryparsers in Solr, so you can't say definitely its not used.

Whether I'm concerned about it depends on if we a 2.9.1 - if we do, I'll fix it. If we don't I won't.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Yonik Seeley (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760082#action_12760082 ] 

Yonik Seeley commented on SOLR-1221:
------------------------------------

How can one reproduce this bug?  The query parser produces a normal term query for numeric queries.

Something like this does not cause an error on trunk:
http://localhost:8983/solr/select?q=popularity:6&hl=true&hl.fl=popularity



> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Miller resolved SOLR-1221.
-------------------------------

    Resolution: Fixed

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Yonik Seeley (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12720284#action_12720284 ] 

Yonik Seeley commented on SOLR-1221:
------------------------------------

Seems time to me... does this affect the HTTP API?

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Grant Ingersoll (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12748940#action_12748940 ] 

Grant Ingersoll commented on SOLR-1221:
---------------------------------------

Is this going to make it into 1.4?

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760087#action_12760087 ] 

Mark Miller commented on SOLR-1221:
-----------------------------------

bq. The query parser produces a normal term query for numeric queries.

Also, I shouldn't have said NumericQuery - NumericRangeQuery - sorry again.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Re: [jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by Mark Miller <ma...@gmail.com>.
Chris Hostetter wrote:
> : 3. use an overridden version of NumericQuery in Solr that returns a placeholder term from getTerm
>
> on the surface that doesn't sound too horrific.  just make it final and 
> deprecated and open an issue to remove it when upgrading to Lucene 3.0.
>
>
> -Hoss
>
>   
Yeah, your right - the ugliness factor blinded me a bit I suppose.

But there is also the issue of custom query parsers out there. If they
make the mistake
of generating Lucene NumericRangeQueries, they will be in the same boat.

-- 
- Mark

http://www.lucidimagination.com




Re: [jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by Chris Hostetter <ho...@fucit.org>.
: 3. use an overridden version of NumericQuery in Solr that returns a placeholder term from getTerm

on the surface that doesn't sound too horrific.  just make it final and 
deprecated and open an issue to remove it when upgrading to Lucene 3.0.


-Hoss


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760080#action_12760080 ] 

Mark Miller commented on SOLR-1221:
-----------------------------------

I don't see one -

ugly options I can think of -

1. extend highlighter and duplicate a ton of code with a fix - obviously not really an option
2. run through the query first and rebuild it without the numericrangequery part
3. use an overridden version of NumericQuery in Solr that returns a placeholder term from getTerm

None of these are really viable IMO though.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Uwe Schindler (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12761759#action_12761759 ] 

Uwe Schindler commented on SOLR-1221:
-------------------------------------

I have no preference...

But we fix the highlighter bug in lucene trunk, too?

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Yonik Seeley (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Yonik Seeley updated SOLR-1221:
-------------------------------

    Attachment: SOLR-1221.patch

missing "svn add" strikes again.... attaching new patch.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Uwe Schindler (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12761366#action_12761366 ] 

Uwe Schindler commented on SOLR-1221:
-------------------------------------

A even simplier workaround:
Instead of using a NRQ, wrap a NRF with ConstantScoreQuery (just change TrieField.getRangeQuery()). You will loose auto-rewrite if only few terms are affected, but for precSteps>4/6, MTQ default would also use ConstantScoreQuery.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Michael McCandless (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12720285#action_12720285 ] 

Michael McCandless commented on SOLR-1221:
------------------------------------------

+1 ;)  Solr's defaults are important, too.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Uwe Schindler (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760114#action_12760114 ] 

Uwe Schindler commented on SOLR-1221:
-------------------------------------

Does RangeQuery really need to be highlighted? It is not used anywhere in Solr (I removed all occurences in the issue about TermRangeQuery), so why handle it?

In Lucene, the fix would only be needed for highlighting in 2.9.1, 3.0 will have no RangeQuery anymore.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760078#action_12760078 ] 

Mark Miller commented on SOLR-1221:
-----------------------------------

What do people thing about putting in an updated Highlighter jar with a fix?

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Grant Ingersoll (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12753634#action_12753634 ] 

Grant Ingersoll commented on SOLR-1221:
---------------------------------------

Looks good to me, the only oddity is the name of the testPhraseHighlighter now tests the non-phrase highlighter.

Also, testing wise, do we now risk losing tests for the other highlighter?  I'm not that familiar with the phrase highlighter, so maybe all it does is subsume the functionality of the old one and add phrase support, in which case the existing tests are fine.  If it does not do that, though, it seems like we might want to duplicate the tests, with use phrase highlighter set to false for the dups.  Unless, of course, you think the existing single test that turns off the phrase highlighter is sufficient.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Miller updated SOLR-1221:
------------------------------

    Attachment: SOLR-1221.patch

to trunk


> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Miller resolved SOLR-1221.
-------------------------------

    Resolution: Fixed

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12761643#action_12761643 ] 

Mark Miller commented on SOLR-1221:
-----------------------------------

I was about to merge that last changed needed (rewrite fix) with Yoniks patch - but it looks like Yoniks patch is missing the SolrQueryWrapper class ...

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12753668#action_12753668 ] 

Mark Miller commented on SOLR-1221:
-----------------------------------

bq. the only oddity is the name of the testPhraseHighlighter now tests the non-phrase highlighter.

Okay, will address.

bq. Also, testing wise, do we now risk losing tests for the other highlighter?

Yeah - before the phrase highlighter was "undertested" and the default had more, and now
its the reverse. I suppose ideally, every test would hit both - that gets ugly though - its what
we do in Lucene. Thats why I am confident in the tests I suppose though - Lucene runs
both through every test - so the PhraseHighlighter matches the other highlighters functionality
and adds support for more query types. I think between Lucene and Solr, the tests are sufficient -
but I couldn't argue against more coverage here - hard to argue against testing in any form :)

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12720286#action_12720286 ] 

Mark Miller commented on SOLR-1221:
-----------------------------------

bq. does this affect the HTTP API? 

No, it won't. Just changes the default setting for two parameters.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760112#action_12760112 ] 

Mark Miller commented on SOLR-1221:
-----------------------------------

bq. deprec ConstantScoreRangeQuery (if ever used in Solr) would also have the problem... (but it extends TermRangeQuery, so should be catched before).

Right - anything that extends TermRangeQuery should be fine. It has special handling.

bq. would not work (final and no ctors).

Thanks - I actually saw that when I was messing with the Highlighter earlier today, but I didn't put 2 and 2 together.
Sounds like the updated Highlighter jar is the solution.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Miller updated SOLR-1221:
------------------------------

    Attachment: SOLR-1221.patch

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12755486#action_12755486 ] 

Mark Miller commented on SOLR-1221:
-----------------------------------

bq. the only oddity is the name of the testPhraseHighlighter now tests the non-phrase highlighter.

Thats actually not true - just looked at the test again - testPhraseHighlighter is the same as it was - it just used to default to off, so for the portion that expected it to be off, I now explicitly turn it off - thats the only change in testPhraseHighlighter.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Miller updated SOLR-1221:
------------------------------

    Component/s: highlighter
        Summary: Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default  (was: Change Solr to use the SpanScorer with MultiTerm expansion by default)

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Uwe Schindler (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760111#action_12760111 ] 

Uwe Schindler commented on SOLR-1221:
-------------------------------------

deprec ConstantScoreRangeQuery (if ever used in Solr) would also have the problem... (but it extends TermRangeQuery, so should be catched before).

bq. 3. use an overridden version of NumericQuery in Solr that returns a placeholder term from getTerm

would not work (final and no ctors).

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12761761#action_12761761 ] 

Mark Miller commented on SOLR-1221:
-----------------------------------

bq. But we fix the highlighter bug in lucene trunk, too?

Yup, def. The only reason we are trying to sidestep here is to avoid having to update the jar in Solr. Its just a hassle. What do we call it and how do we track it?
Back against the wall, I think it makes sense, but not if we can sidestep and go pure 2.9 release.

I'll commit a fix in Lucene over the weekend - super easy fix there anyway.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Miller updated SOLR-1221:
------------------------------

    Attachment: SOLR-1221.patch

this patch needs to be applied to finish the issue - but for now it will cause tests to fail.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760083#action_12760083 ] 

Mark Miller edited comment on SOLR-1221 at 9/27/09 12:36 PM:
-------------------------------------------------------------

Sorry - should have been more clear.

The bug is hidden on trunk at the moment - Koji pointed out that I missed a spot, and on trunk right now, queries are being rewritten by default when they shouldnt be.

Now that you mention it though, the issue is not just with NumericRange (I just assumed that was being gen'd cause I saw the problem with it), but its also going to be with the
deprecated RangeQuery it looks. *edit* actually - since RangeQuery no longer extends MultiTermQuery, it won't cause the error - it just won't highlight.

*edit*

which really argues for a jar update - I can fix all causes with one simple fix - checking if getTerm returns null.

      was (Author: markrmiller@gmail.com):
    Sorry - should have been more clear.

The bug is hidden on trunk at the moment - Koji pointed out that I missed a spot, and on trunk right now, queries are being rewritten by default when they shouldnt be.

Now that you mention it though, the issue is not just with NumericRange (I just assumed that was being gen'd cause I saw the problem with it), but its also going to be with the
deprecated RangeQuery it looks.

*edit*

which really argues for a jar update - I can fix all causes with one simple fix - checking if getTerm returns null.
  
> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Uwe Schindler (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12761763#action_12761763 ] 

Uwe Schindler commented on SOLR-1221:
-------------------------------------

I would also stay with 2.9 in Solr. Just mark the removal of the wrapper as a TODO item after the next lucene update.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Yonik Seeley (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Yonik Seeley updated SOLR-1221:
-------------------------------

    Attachment: SOLR-1221.patch

OK, here's a potential workaround... simply wraps the NumericRangeQuery in another query and delegates everything.  Since it won't be an instanceof MultiTermQuery, it shouldn't trigger any bugs in the highlighters.

I tried starting off with a MultiTermQuery that delegated to the contained NRQ, but it turned out to be impossible because MTQ.getEnum is protected - so can't delegate.

The easiest solution would have been just subclassing NRQ - Lucene shouldn't make stuff like this so hard... we should simply document that most of the classes are not meant to be overridden - and back compat does not extend to subclassing unless the class was specifically designed for it.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Reopened: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Mark Miller reopened SOLR-1221:
-------------------------------


There is a bug to take care of, and a missing piece that Koji pointed out.

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (SOLR-1221) Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default

Posted by "Mark Miller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SOLR-1221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12760057#action_12760057 ] 

Mark Miller commented on SOLR-1221:
-----------------------------------

Easy enough to side step this bug in Lucene for now - but if we release with pure Lucene 2.9, not sure what I'm going to do here...

> Change Solr Highlighting to use the SpanScorer with MultiTerm expansion by default
> ----------------------------------------------------------------------------------
>
>                 Key: SOLR-1221
>                 URL: https://issues.apache.org/jira/browse/SOLR-1221
>             Project: Solr
>          Issue Type: Improvement
>          Components: highlighter
>            Reporter: Mark Miller
>            Assignee: Mark Miller
>             Fix For: 1.4
>
>         Attachments: SOLR-1221.patch, SOLR-1221.patch, SOLR-1221.patch
>
>
> To improve the out of the box experience of Solr 1.4, I really think we should make this change. You will still be able to turn both off.
> Comments?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.