lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yuki Yano (JIRA)" <>
Subject [jira] [Commented] (SOLR-11164) OriginalScoreFeature causes NullPointerException during feature logging with SolrCloud mode.
Date Tue, 08 Aug 2017 01:30:01 GMT


Yuki Yano commented on SOLR-11164:

[~Jonathan GV]
Thank you for testing the patch! As you say, it will return the calculation of the 2nd phase
query. However, in my understanding, this query is built from the parameter of "q" and thus
it should be same as 1st phase query.

Details are as below. In short, both 1st phase request and 2nd phase request have same "q"
parameter and it will be set to {{ResultContext}}.

1. {{OriginalScoreFeature}} uses {{rb.getQuery()}} for calculating the original score, which
is given by {{RankQuery#wrap}}.

2. As following codes, {{ResultContext}} is built from {{ResponseBuilder}} and it use {{rb.getQuery()}}
as the query.

3. {{Query}} parsed from "q" is set the query of {{ResponseBuilder}} during preparing phase,
which is executed in both 1st and 2nd phase.

4. In distributed process, {{QueryComponent}} sets original parameters when builds the 2nd
phase request as following codes (i.e., same "q" parameter as 1st phase).

> OriginalScoreFeature causes NullPointerException during feature logging with SolrCloud
> --------------------------------------------------------------------------------------------
>                 Key: SOLR-11164
>                 URL:
>             Project: Solr
>          Issue Type: Bug
>      Security Level: Public(Default Security Level. Issues are Public) 
>          Components: contrib - LTR
>    Affects Versions: 6.6
>            Reporter: Yuki Yano
>         Attachments: SOLR-11164.patch
> In FeatureTransfer, OriginalScoreFeature uses original Query instance preserved in LTRScoringQuery
for the evaluation.
> This query is set in RankQuery#wrap during QueryComponent#process.
> With SolrCloud mode, document searches take two steps: finding top-N document ids, and
filling documents of found ids.
> In this case, FeatureTransformer works in the second step and tries to extract features
with LTRScoringQuery built in QueryComponent#prepare.
> However, because the second step doesn't call QueryComponent#process, the original query
of LTRScoringQuery remains null and this causes NullPointerException while evaluating OriginalScoreFeature.
> We can get the original query from ResultContext which is an argument of DocTransformer#setContext,
thus this problem can solve by using it if LTRScoringQuery doesn't have correct original query.

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message