[ 
https://issues.apache.org/jira/browse/SOLR-10836?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16045361#comment-16045361
 ] 

ASF subversion and git services commented on SOLR-10836:
--------------------------------------------------------

Commit 5c781d5679716dc46a28015c03ef9bcae824e58c in lucene-solr's branch 
refs/heads/master from [~dsmiley]
[ https://git-wip-us.apache.org/repos/asf?p=lucene-solr.git;h=5c781d5 ]

SOLR-10836: igain, significantTerms, and tlogit assumed existing terms


> TextLogisticRegression parser (and others) assume non-empty index.
> ------------------------------------------------------------------
>
>                 Key: SOLR-10836
>                 URL: https://issues.apache.org/jira/browse/SOLR-10836
>             Project: Solr
>          Issue Type: Bug
>      Security Level: Public(Default Security Level. Issues are Public) 
>            Reporter: David Smiley
>            Assignee: David Smiley
>            Priority: Minor
>             Fix For: master (7.0), 6.7
>
>         Attachments: SOLR-10836.patch, 
> SOLR_10836_use_SolrIndexSearcher_cached_MultiFields_instead_of_recreating.patch
>
>
> TextLogisticRegressionQParserPlugin, IGainTermsQParserPlugin and 
> SignificantTermsQParserPlugin are similarly affected:
> finish() contains this line of code:
> {code:java}
> Terms terms = 
> MultiFields.getFields(searcher.getIndexReader()).terms(trainingParams.feature);
> {code}
> Instead I think it should be this:
> {code:java}
> Terms terms = 
> ((SolrIndexSearcher)searcher).getSlowAtomicReader().terms(trainingParams.feature);
> {code}
> MultiFields can take some time to build and Solr (via SlowAtomicReader) has 
> already done this work.
> In addition, the code assumes Terms is non-null when in fact it will be null 
> if there's no data.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to