Skip to content

Ensure sendBatch not called recursively#39988

Merged
dnhatn merged 3 commits intoelastic:masterfrom
dnhatn:test-async-target
Mar 13, 2019
Merged

Ensure sendBatch not called recursively#39988
dnhatn merged 3 commits intoelastic:masterfrom
dnhatn:test-async-target

Conversation

@dnhatn
Copy link
Copy Markdown
Member

@dnhatn dnhatn commented Mar 13, 2019

This PR introduces AsyncRecoveryTarget which executes remote calls of peer recovery asynchronously. In this change, we also add a new assertion to ensure that method sendBatch, which sends a batch of history operations in phase2, is never called recursively on the same thread. This new assertion will also be used in method sendFileChunks.

Relates #39769 (comment)

@dnhatn dnhatn added >test Issues or PRs that are addressing/adding tests :Distributed/Recovery Anything around constructing a new shard, either from a local or a remote source. v8.0.0 v7.2.0 labels Mar 13, 2019
@dnhatn dnhatn requested review from s1monw and ywelsch March 13, 2019 09:33
@elasticmachine
Copy link
Copy Markdown
Collaborator

Pinging @elastic/es-distributed

@dnhatn dnhatn changed the title Introduce AsyncRecoveryTarget for testing Ensure sendBatch not called recursively Mar 13, 2019
@dnhatn dnhatn added >enhancement and removed >test Issues or PRs that are addressing/adding tests labels Mar 13, 2019
Copy link
Copy Markdown
Contributor

@s1monw s1monw left a comment

Choose a reason for hiding this comment

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

Left one comment

@dnhatn
Copy link
Copy Markdown
Member Author

dnhatn commented Mar 13, 2019

Thanks @s1monw.

@dnhatn dnhatn merged commit 0ada3e2 into elastic:master Mar 13, 2019
@dnhatn dnhatn deleted the test-async-target branch March 13, 2019 16:10
dnhatn added a commit that referenced this pull request Mar 18, 2019
This PR introduces AsyncRecoveryTarget which executes remote calls of
peer recovery asynchronously. In this change, we also add a new
assertion to ensure that method sendBatch, which sends a batch of
history operations in phase2, is never called recursively on the same
thread. This new assertion will also be used in method sendFileChunks.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

:Distributed/Recovery Anything around constructing a new shard, either from a local or a remote source. >enhancement v7.2.0 v8.0.0-alpha1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants