[
https://issues.apache.org/jira/browse/SOLR-4310?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
John Wooden updated SOLR-4310:
------------------------------
Attachment: SOLR-4310_4.patch
Added another test class to check a few more use cases, both single-core and
distributed. There are also test cases written that rely on SOLR-2894 which
are commented-out.
Fixed an issue where numFound (group count) would be 0 for a single-core edge
case.
Our tests suggest that distributed works just fine with 4310 unless Amit
recalls what he alluded to previously.
On a semi-related note....
When writing the additional tests, we noticed some inconsistent behavior around
rows. Not a result of the 4310 patch nor pertinent to 4310's purpose, just
something we discovered.
On a single core with group.limit > 1 and group.main, setting rows=10 will
return 10 _documents_. A distributed setup with the same params will return 10
_groups_. A commented-out failing testcase is included in the patch. If others
can confirm it, we can open a new JIRA ticket for it.
> If groups.ngroups is specified, the docList's numFound should be the number
> of groups
> -------------------------------------------------------------------------------------
>
> Key: SOLR-4310
> URL: https://issues.apache.org/jira/browse/SOLR-4310
> Project: Solr
> Issue Type: Improvement
> Components: search
> Affects Versions: 4.1
> Reporter: Amit Nithian
> Assignee: Hoss Man
> Priority: Minor
> Fix For: 4.4
>
> Attachments: SOLR-4310_2.patch, SOLR-4310_3.patch, SOLR-4310_4.patch,
> SOLR-4310.patch
>
>
> If you group by a field, the response may look like this:
> <lst name="grouped">
> <lst name="series">
> <int name="matches">138</int>
> <int name="ngroups">1</int>
> <result name="doclist" numFound="138" start="0">
> <doc>
> <int name="id">267038365</int>
> <str name="name">
> Larry's Grand Ole Garage Country Dance - Pure Country
> </str>
> </doc>
> </result>
> </lst>
> </lst>
> and if you specify group.main then the doclist becomes the result and you
> lose all context of the number of groups. If you want to keep your response
> format backwards compatible with clients (i.e. clients who don't know about
> the grouped format), setting group.main=true solves this BUT the numFound is
> the number of raw matches instead of the number of groups. This may have
> downstream consequences.
> I'd like to propose that if the user specifies ngroups=true then when
> creating the returning DocSlice, set the numFound to be the number of groups
> instead of the number of raw matches to keep the response consistent with
> what the user would expect.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
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]