Hi!
I'm in the middle of an upgrade process to the 7.10.0 Elasticsearch (changing the client from TransportClient to JavaRestHighLevelClient also) and I've noticed a strange behavior of Date Histogram Aggregation when it is inside a Nested Aggregation.
I have two Junits tests that cover, each, the scenarios inside a nested and not.
Without the nested, with a interval of 1d, it works as expected:
Though I have no impression that this would be at fault, it may be worth trying fixed_interval or calendar_interval as a sanity check since interval is deprecated. I can't imagine that would cause this though ¯\_(ツ)_/¯
Have you examined the generated query? I assumed so from your screenshots but just a sanity check to verify that the JSON query produced by the new client matches the old client's query. I personally don't know how the results could occur given the input interval, but very curious to know the answer too.
@egalpin, I suppose it has something to do with my data (although I have no idea why this is happening).
I've checked the requests and they look ok. After that, I took the relevant requests (since the index creation to the search) and created a Dockerfile to simulate the problem. When I did that (with an empty container), the problem didn't occur.
So, I can only imagine this is because some data my Elasticsearch has that an empty container wouldn't have.
But, again, it makes no sense to me at all.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.