ExtendedStats with one document -> UnexpectedElasticsearchClientException
See original GitHub issueNEST/Elasticsearch.Net version: 7.9.0 Elasticsearch version: 7.9.1
Description of the problem including expected versus actual behavior: Using ExtendedStats on a numeric value on one document generates always an exception:
"message": "An error has occurred.",
"exceptionMessage": "expected:'Number Token', actual:'\"NaN\"', at offset:179002",
"exceptionType": "Elasticsearch.Net.UnexpectedElasticsearchClientException",
ps: I really don’t know if the issue was present before, actually we working usually with a lot of documents, so this is the first time we see only one document after filtering our index and the first time in years that we see this exception.
Expected behavior No exception but an empty result.
Issue Analytics
- State:
- Created 3 years ago
- Comments:13 (3 by maintainers)
Top Results From Across the Web
Unexpected exceptions | Elasticsearch.Net and NEST
Sometimes, an unexpected exception happens further down in the pipeline. In this scenario, we wrap them inside an UnexpectedElasticsearchClientException so that ...
Read more >Stack Overflow
I have a c# project which i want send a request to my elastic search server. this is my connection and elastic search...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I’ve opened https://github.com/elastic/elasticsearch-net/pull/5404 to address
Hi @meriturva
there’s no change in NEST for this yet. There’s been some discussion about whether Elasticsearch should be returning
NaN
at all, given the ambiguity of representing it in JSON. No conclusion has been reached yet though.@Mpdreamz, @stevejgordon perhaps we can check for
"NaN"
in the offending fields? I think it’s the addition of the sampling fields in extended stats, but would need double checking.