Skip to content

Conversation

@idegtiarenko
Copy link
Contributor

This test was silently skipping assertion.
Please see inline comments for more details.

@idegtiarenko idegtiarenko added >test Issues or PRs that are addressing/adding tests Team:Analytics Meta label for analytical engine team (ESQL/Aggs/Geo) :Analytics/ES|QL AKA ESQL v9.1.0 labels Mar 14, 2025
@idegtiarenko idegtiarenko requested a review from nik9000 March 14, 2025 10:06
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-analytical-engine (Team:Analytics)

Comment on lines -287 to -296
} catch (AssertionError e) {
client().admin().indices().stats(new IndicesStatsRequest()).actionGet().asMap().forEach((shard, stats) -> {
logger.info(
"Shard {} node {} status {} docs {}",
shard.shardId(),
shard.currentNodeId(),
shard.state(),
stats.getStats().getDocs().getCount()
);
});
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was not bubbling up exception if/when that happens

stats.getStats().getDocs().getCount()
);
});
assertThat(exchanges.get(), lessThanOrEqualTo(2));
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Once above was fixed I noticed that 1-8% depending on the load of the times the test was failing.

Since processing pages and sending more requests happens on different threads of different threadpools, we can not guarantee that incoming page is processed before the next request is sent.

It looks like in practice we accumulate enough results (1 row) before the third request is sent.
This still shows that we do not send request to every node (there are at minimum 3 data nodes in this test).

@idegtiarenko idegtiarenko merged commit edc36aa into elastic:main Mar 19, 2025
17 checks passed
@idegtiarenko idegtiarenko deleted the fix_testCancelUnnecessaryRequests branch March 19, 2025 15:48
smalyshev pushed a commit to smalyshev/elasticsearch that referenced this pull request Mar 21, 2025
omricohenn pushed a commit to omricohenn/elasticsearch that referenced this pull request Mar 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

:Analytics/ES|QL AKA ESQL Team:Analytics Meta label for analytical engine team (ESQL/Aggs/Geo) >test Issues or PRs that are addressing/adding tests v9.1.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants