From b5a2afccb261fe99da36e42ebf2581ac919d71dc Mon Sep 17 00:00:00 2001 From: Henning Andersen <33268011+henningandersen@users.noreply.github.com> Date: Wed, 2 Oct 2019 12:32:46 +0200 Subject: [PATCH] MockSearchService concurrency fix (#47139) Fixed MockSearchService concurrency, assertNoInFlightContext could have false negative result (rarely). Split out from #46060 Closes #47048 --- .../main/java/org/elasticsearch/search/MockSearchService.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/framework/src/main/java/org/elasticsearch/search/MockSearchService.java b/test/framework/src/main/java/org/elasticsearch/search/MockSearchService.java index b9d9ff3cfc9..c1ebb121349 100644 --- a/test/framework/src/main/java/org/elasticsearch/search/MockSearchService.java +++ b/test/framework/src/main/java/org/elasticsearch/search/MockSearchService.java @@ -74,8 +74,8 @@ public class MockSearchService extends SearchService { @Override protected void putContext(SearchContext context) { - super.putContext(context); addActiveContext(context); + super.putContext(context); } @Override