[
https://issues.apache.org/jira/browse/LUCENE-5790?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Hoss Man updated LUCENE-5790:
-----------------------------
Attachment: LUCENE-5790.patch
bq. If you give free reign for anyone to set the values independently, yes.
that is, in fact, exactly what the API currently does.
bq. Value setters currently ensure that the default value (0 for numerics) is
set if exists == false.
if we're going to have that expectation on the callers it should be documented
and there should be some asserts in the code to ensure it.
----
Updated patch with yonik's suggested fix + some class level docs explaining
the requirements on the callers + some assertions in key methods that it's
pre-conditions aren't violated.
If folks think this is a better way to go then accounting for the possibility
that "value!=0" when "exists==false" in hashCode/equals/compareTo i'm fine with
that -- but we still need to audit the other impls & add tests for them as well.
> MutableValue compareTo impls seem to be broken for exists==false
> ----------------------------------------------------------------
>
> Key: LUCENE-5790
> URL: https://issues.apache.org/jira/browse/LUCENE-5790
> Project: Lucene - Core
> Issue Type: Bug
> Reporter: Hoss Man
> Attachments: LUCENE-5790.patch, LUCENE-5790.patch
>
>
> On the solr-user mailing list, Ebisawa & Alex both commented that they've
> noticed bugs in the grouping code when some documents don't have values in
> the grouping field.
> In Ebisawa's case, he tracked this down to what appears to be some bugs in
> the logic of the "compareSameType" method of some of the MutableValue
> implementations.
> Thread:
> https://mail-archives.apache.org/mod_mbox/lucene-solr-user/201406.mbox/%3c84f86fce4b8f42268048aecfb2806...@sixpr04mb045.apcprd04.prod.outlook.com%3E
--
This message was sent by Atlassian JIRA
(v6.2#6252)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]