[ https://issues.apache.org/jira/browse/SOLR-12698?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16675743#comment-16675743 ]
Christine Poerschke edited comment on SOLR-12698 at 11/5/18 8:58 PM: --------------------------------------------------------------------- Started to look at the initial SOLR-12698.patch in conjunction with the existing code; this is how far i got so far for today: * [SolrFeatureWeight.scorer|https://github.com/apache/lucene-solr/blob/releases/lucene-solr/7.5.0/solr/contrib/ltr/src/java/org/apache/solr/ltr/feature/SolrFeature.java#L218-L234] is the method being changed. * existing code: ** https://github.com/apache/lucene-solr/blob/releases/lucene-solr/7.5.0/solr/contrib/ltr/src/java/org/apache/solr/ltr/feature/SolrFeature.java#L175-L184 illustrates when/why {{SolrFeatureWeight.solrQueryWeight}} might be null. ** If {{SolrFeatureWeight.queryAndFilters}} is empty (because there was no {{fq}} and {{q}} (if present) resulted in a null {{solrQueryWeight}}) then {{getDocIdSetIteratorFromQueries}} will return null and {{SolrFeatureWeight.scorer}} will return null. ** If {{SolrFeatureWeight.queryAndFilters}} contains one element (because there was no {{fq}} but there was a {{q}} which resulted in a non-null {{solrQueryWeight}}) then ... \[to be continued\] was (Author: cpoerschke): Started to look at the initial SOLR-12698.patch in conjunction with the existing code; this is how far i got so far for today: * [SolrFeatureWeight.scorer|https://github.com/apache/lucene-solr/blob/releases/lucene-solr/7.5.0/solr/contrib/ltr/src/java/org/apache/solr/ltr/feature/SolrFeature.java#L218-L234] is the method being changed. * existing code: ** https://github.com/apache/lucene-solr/blob/releases/lucene-solr/7.5.0/solr/contrib/ltr/src/java/org/apache/solr/ltr/feature/SolrFeature.java#L175-L184 illustrates when/why {{SolrFeatureWeight.solrQueryWeight}} might be null. ** If {{SolrFeatureWeight.queryAndFilters}} is empty (because there was no {{fq}} and {{q}} (if present) resulted in a null {{solrQueryWeight}}) then {{getDocIdSetIteratorFromQueries}} will return null and {{SolrFeatureWeight.scorer}} will return null. ** If {{SolrFeatureWeight.queryAndFilters}} contains one element (because there was no {{fq}} but there was a {{q}} which resulted in a non-null {{solrQueryWeight}}) then ... \[to be continued\] > SolrFeature: no-fq optimisation > ------------------------------- > > Key: SOLR-12698 > URL: https://issues.apache.org/jira/browse/SOLR-12698 > Project: Solr > Issue Type: Sub-task > Security Level: Public(Default Security Level. Issues are Public) > Components: contrib - LTR > Reporter: Stanislav Livotov > Priority: Major > Attachments: SOLR-12698.patch > > > [~slivotov] wrote in SOLR-12688: > bq. ... SolrFeature was not optimally implemented for the case when no fq > parameter was passed. I'm not absolutely sure what was the intention to > introduce both q(which is supposed to be a function query) and fq parameter > for the same SolrFeature at all(Is there a case when they will be used > together ? ), so I decided not to change behavior but just optimize described > case ... > (Please see SOLR-12688 description for overall context and analysis results.) -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org