Fix testRunStateChangePolicyWithAsyncActionNextStep race condition#40707
Merged
dakrone merged 1 commit intoelastic:masterfrom Apr 2, 2019
Merged
Fix testRunStateChangePolicyWithAsyncActionNextStep race condition#40707dakrone merged 1 commit intoelastic:masterfrom
dakrone merged 1 commit intoelastic:masterfrom
Conversation
Previously we only set the latch countdown with `nextStep.setLatch` after the cluster state change has already been counted down. However, it's possible execution could have already started, causing the latch to be missed when the `MockAsyncActionStep` is being executed. This moves the latch setting to be before the call to `runPolicyAfterStateChange`, which means it is always available when the `MockAsyncActionStep` is executed. I was able to reproduce the failure every 30-40 runs before this change. With this change, running 2000+ times the test passes. Resolves elastic#40018
Collaborator
|
Pinging @elastic/es-core-features |
dakrone
added a commit
that referenced
this pull request
Apr 2, 2019
…40707) Previously we only set the latch countdown with `nextStep.setLatch` after the cluster state change has already been counted down. However, it's possible execution could have already started, causing the latch to be missed when the `MockAsyncActionStep` is being executed. This moves the latch setting to be before the call to `runPolicyAfterStateChange`, which means it is always available when the `MockAsyncActionStep` is executed. I was able to reproduce the failure every 30-40 runs before this change. With this change, running 2000+ times the test passes. Resolves #40018
dakrone
added a commit
that referenced
this pull request
Apr 2, 2019
…40707) Previously we only set the latch countdown with `nextStep.setLatch` after the cluster state change has already been counted down. However, it's possible execution could have already started, causing the latch to be missed when the `MockAsyncActionStep` is being executed. This moves the latch setting to be before the call to `runPolicyAfterStateChange`, which means it is always available when the `MockAsyncActionStep` is executed. I was able to reproduce the failure every 30-40 runs before this change. With this change, running 2000+ times the test passes. Resolves #40018
dakrone
added a commit
that referenced
this pull request
Apr 2, 2019
…40707) Previously we only set the latch countdown with `nextStep.setLatch` after the cluster state change has already been counted down. However, it's possible execution could have already started, causing the latch to be missed when the `MockAsyncActionStep` is being executed. This moves the latch setting to be before the call to `runPolicyAfterStateChange`, which means it is always available when the `MockAsyncActionStep` is executed. I was able to reproduce the failure every 30-40 runs before this change. With this change, running 2000+ times the test passes. Resolves #40018
dakrone
added a commit
that referenced
this pull request
Apr 2, 2019
…40707) Previously we only set the latch countdown with `nextStep.setLatch` after the cluster state change has already been counted down. However, it's possible execution could have already started, causing the latch to be missed when the `MockAsyncActionStep` is being executed. This moves the latch setting to be before the call to `runPolicyAfterStateChange`, which means it is always available when the `MockAsyncActionStep` is executed. I was able to reproduce the failure every 30-40 runs before this change. With this change, running 2000+ times the test passes. Resolves #40018
jasontedor
added a commit
to jasontedor/elasticsearch
that referenced
this pull request
Apr 2, 2019
* master: add reason to DataFrameTransformState and add hlrc protocol tests (elastic#40736) Remove timezone validation on rollup range queries (elastic#40647) Fix testRunStateChangePolicyWithAsyncActionNextStep race condition (elastic#40707) Don't mark shard as refreshPending on stats fetching (elastic#40458) Name Snapshot Data Blobs by UUID (elastic#40652) SQL: [TEST] Mute TIME related failing tests [TEST] RecoveryWithConcurrentIndexing test (elastic#40733)
gurkankaymak
pushed a commit
to gurkankaymak/elasticsearch
that referenced
this pull request
May 27, 2019
…lastic#40707) Previously we only set the latch countdown with `nextStep.setLatch` after the cluster state change has already been counted down. However, it's possible execution could have already started, causing the latch to be missed when the `MockAsyncActionStep` is being executed. This moves the latch setting to be before the call to `runPolicyAfterStateChange`, which means it is always available when the `MockAsyncActionStep` is executed. I was able to reproduce the failure every 30-40 runs before this change. With this change, running 2000+ times the test passes. Resolves elastic#40018
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Previously we only set the latch countdown with
nextStep.setLatchafter thecluster state change has already been counted down. However, it's possible
execution could have already started, causing the latch to be missed when the
MockAsyncActionStepis being executed.This moves the latch setting to be before the call to
runPolicyAfterStateChange, which means it is always available when theMockAsyncActionStepis executed.I was able to reproduce the failure every 30-40 runs before this change. With
this change, running 2000+ times the test passes.
Resolves #40018