[
https://issues.apache.org/jira/browse/SOLR-3074?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Hoss Man updated SOLR-3074:
---------------------------
Summary: SolrPluginUtils.docListToSolrDocumentList is broken, existing test
is also broken (was: Bug in SolrPluginUtilsTest)
Ahmet: thanks for raising this issue, and for your patch.
you didn't mention it in jira, but in your linked email you suggested that the
method being tested (docListToSolrDocumentList) isn't actually doing what it's
suppose to...
{quote}
Regardless of Set<String> fields parameter,
SolrPluginUtils#docListToSolrDocumentList method loads all of the stored
fields. Shouldn't it just load the fields given in the set? Should I file a
jira ticket?
{quote}
Digging deeper, i found two problems...
* docListToSolrDocumentList is delegating the field list to
SolrIndexSearcher.doc, which means those fields are read immediately, but the
rest of the fields will be lazy loaded
* docListToSolrDocumentList is calling DocumentBuilder.loadStoredFields which
loads all of the fields -- regardless of which field list was passed to
docListToSolrDocumentList
* docListToSolrDocumentList has some really bizare code in it, preventing
stored fields from being returned if they are the result of a copyField.
Since there are no other usages of DocumentBuilder.loadStoredFields in Solr,
it's not clear to me what the intended point of it's crazy logic was
> SolrPluginUtils.docListToSolrDocumentList is broken, existing test is also
> broken
> ---------------------------------------------------------------------------------
>
> Key: SOLR-3074
> URL: https://issues.apache.org/jira/browse/SOLR-3074
> Project: Solr
> Issue Type: Bug
> Components: search
> Affects Versions: 4.0
> Reporter: Ahmet Arslan
> Priority: Minor
> Fix For: 4.0
>
> Attachments: SOLR-3074.patch
>
>
> testDocListConversion() is not testing what it's suppossed to test. Because
> added test documents are not committed.
> http://search-lucene.com/m/uwh9l2SHH4e
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]