Skip to content

[8.14] Fix IOOBE in TTest aggregation when using filters #109051

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

Merged
merged 3 commits into from
May 27, 2024

Conversation

iverase
Copy link
Contributor

@iverase iverase commented May 27, 2024

There is a corner case in the TTEst aggregation where we are throwing an IOOBE becuase we are not checking properly the bounds of the arrays. It happens when using filters on the aggregation and the aggregation is a sub-aggregation. Then one of the TTestStats can be empty which my mean that the array might have not been grown. When reading it, we don't check the current range.

This commit makes sure we only read the state if it exist in the array.

Backport #109034

iverase added 2 commits May 27, 2024 07:40
There is a corner case in the TTEst aggregation where we are throwing an IOOBE becuase we are not checking properly 
the bounds of the arrays. It happens when using filters on the aggregation and the aggregation is a sub-aggregation. 
Then one of the TTestStats can be empty which my mean that the array might have not been grown. When reading it,
 we don't check the current range.

This commit makes sure we only read the state if it exist in the array.
@iverase iverase added the auto-merge-without-approval Automatically merge pull request when CI checks pass (NB doesn't wait for reviews!) label May 27, 2024
@elasticsearchmachine elasticsearchmachine merged commit b777b3b into elastic:8.14 May 27, 2024
15 checks passed
@iverase iverase deleted the backport109034v2 branch May 27, 2024 06:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Analytics/Aggregations Aggregations auto-merge-without-approval Automatically merge pull request when CI checks pass (NB doesn't wait for reviews!) backport >bug v8.14.1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants