New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
multiple 'children' aggregations interfere with each other #9958
Comments
Hi @perryn on what version of ES are experiencing this interference issue? Also are you able to reproduce on a smaller scale? |
Hi @martijnvg The above was seen on 1.4.4 but I was also able to reproduce the issue on a smaller scale on 1.4.2. I ran the same query as above and got the following result
cheers |
Can reproduce in 1.5. That's actually how I came here, by trying to find a solution. If I specify children aggregation first and then would do different sub aggregations under it - they seem to work as expected. So the example below returns two identical histograms as requested for this example. The following request, however, doesn't work. If I put children aggregation under different filters and then try to use the same histogram, the second histogram returns values n^2, the third one - n^3 and so on. I didn't debug what would happen if filters above "children would have different criteria s". Example: query: { And the results are: { I hope it will help. |
@AlexKovalevich Thanks for sharing. It think this was fixed via #10263 (since it looks similar to the issue you describe). This will be included in 1.5.1. I can't be sure if this really fixed your issue, because there is no reproduction. If you like you can build from the 1.5 branch and see if the issue still occurs. This would help a lot. |
@AlexKovalevich Now that 1.5.1 has been released can you check if the issue still occurs in your environment? |
@martijnvg I was running into the same issue and I can verify that 1.5.1 fixed it for me. |
awesome. @fozzylyon thanks for letting us know. closing |
Fixed for me too in 1.5.1 ! |
If you have two sibling aggregations that make use of the 'children' aggregation, then the second aggregation seems to count each document twice.
Here is a cut-down example
I have a mapping that has parent documents of type 'datastreams' with child documents of type 'readings'
I ran this, which has two identical sibling aggregations:
and got the response
Although aggregation 'one' and 'two' are identical Elasticsearch seems to have double counted the documents for aggregation 'two'
The text was updated successfully, but these errors were encountered: