You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@lucene.apache.org by "Munendra S N (Jira)" <ji...@apache.org> on 2019/09/21 06:05:00 UTC

[jira] [Resolved] (SOLR-13318) JsonFacetingResponse classes should record provide access to count fields as longs

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

Munendra S N resolved SOLR-13318.
---------------------------------
    Resolution: Fixed

[~akachan]
This is fixed in SOLR-13780.

I'm marking this resolved. We can reopen if there is 7.7.3 release

> JsonFacetingResponse classes should record  provide access to count fields as longs
> -----------------------------------------------------------------------------------
>
>                 Key: SOLR-13318
>                 URL: https://issues.apache.org/jira/browse/SOLR-13318
>             Project: Solr
>          Issue Type: Bug
>          Components: SolrJ
>    Affects Versions: 7.7.1
>            Reporter: Jason Gerlowski
>            Assignee: Jason Gerlowski
>            Priority: Minor
>             Fix For: 8.1
>
>         Attachments: SOLR-13318-branch_8x.patch, SOLR-13318.patch, SOLR-13318.patch
>
>
> JsonFacetingResponse and its series of dependent classes hold a variety of count fields for bucket counts and various optional properties ({{allBuckets}}, {{numBuckets}}, etc.).  Currently, some of the code that parses these values out of the originating NamedList either stores or casts the values as ints.  When doc counts are low this works fine.  But when the doc counts become larger and stray into "long" territory, SolrJ is liable to blow up with ClassCastExceptions.
> A user on the list reported on of these with the partial stack trace:
> {code}
> Caused by: java.lang.ClassCastException: java.lang.Long cannot be cast to java.lang.Integer
>       at org.apache.solr.client.solrj.response.json.NestableJsonFacet.<init>(NestableJsonFacet.java:52)
>       at org.apache.solr.client.solrj.response.QueryResponse.extractJsonFacetingInfo(QueryResponse.java:200)
>       at org.apache.solr.client.solrj.response.QueryResponse.getJsonFacetingResponse(QueryResponse.java:571)
> {code}
> We should fix this so that these classes can be used without incident for any doc counts.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

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