What is the bug?
It cause the results non-deterministic and IT flaky.
How can one reproduce the bug?
./gradlew ':integ-test:yamlRestTest' --tests 'org.opensearch.sql.rest.RestHandlerClientYamlTestSuiteIT.test {yaml=issues/4866/Patterns with specified max_sample_count should return correct result}' -Dtests.seed=7EA1C8BFFB4E312E
What is the expected behavior?
The above IT could pass
What is your host/environment?