lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Munendra S N (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (SOLR-8594) Impossible Cast: equals() method in ConstDoubleSource always returns false
Date Tue, 23 Jul 2019 15:30:00 GMT

     [ https://issues.apache.org/jira/browse/SOLR-8594?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Munendra S N resolved SOLR-8594.
--------------------------------
    Resolution: Not A Problem

AnalyticsComponent has rewritten in SOLR-10123, which doesn't have this problem

> Impossible Cast: equals() method in ConstDoubleSource always returns false
> --------------------------------------------------------------------------
>
>                 Key: SOLR-8594
>                 URL: https://issues.apache.org/jira/browse/SOLR-8594
>             Project: Solr
>          Issue Type: Bug
>            Reporter: Marc Breslow
>            Priority: Major
>         Attachments: SOLR-8594-fix-impossible-cast.patch
>
>
> The equals() method in org.apache.solr.analytics.util.valuesource.ConstDoubleSource is
written as
> {code:java}
>   public boolean equals(Object o) {
>     if (!(o instanceof ConstValueSource)) return false;
>     ConstDoubleSource other = (ConstDoubleSource)o;
>     return  this.constant == other.constant;
>   }
> {code}
> There is no common ancestor for ConstValueSource so the first conditional will always
return false. Attaching a patch to fix.



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)

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


Mime
View raw message