[ https://issues.apache.org/jira/browse/SOLR-10836?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
David Smiley resolved SOLR-10836. --------------------------------- Resolution: Fixed > 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