Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BulkProcessor flush runnable preserves the thread context from creation time #26718

Merged
merged 1 commit into from Sep 20, 2017

Conversation

@jaymode
Copy link
Member

jaymode commented Sep 19, 2017

When using a bulk processor, the thread context was not preserved for the flush runnable which is
executed in another thread in the thread pool. This change wraps the flush runnable in a context
preserving runnable so that the headers and transients from the creation time of the bulk processor
are available during the execution of the flush.

Closes #26596

…on time

When using a bulk processor, the thread context was not preserved for the flush runnable which is
executed in another thread in the thread pool. This change wraps the flush runnable in a context
preserving runnable so that the headers and transients from the creation time of the bulk processor
are available during the execution of the flush.

Closes #26596
Copy link
Contributor

nik9000 left a comment

@javanna might want to have a look as well because he was just talking to me about this sort of thing.

@hexian55

This comment has been minimized.

Copy link

hexian55 commented Sep 20, 2017

thanks

@javanna

This comment has been minimized.

Copy link
Member

javanna commented Sep 20, 2017

thanks for the ping @nik9000 ! LGTM as well

@s1monw
s1monw approved these changes Sep 20, 2017
Copy link
Contributor

s1monw left a comment

LGTM

@jaymode jaymode merged commit c47f24d into elastic:master Sep 20, 2017
2 checks passed
2 checks passed
CLA Commit author has signed the CLA
Details
elasticsearch-ci Build finished.
Details
@jaymode jaymode deleted the jaymode:bulk_flush_threadcontext branch Sep 20, 2017
jaymode added a commit that referenced this pull request Sep 20, 2017
…on time (#26718)

When using a bulk processor, the thread context was not preserved for the flush runnable which is
executed in another thread in the thread pool. This change wraps the flush runnable in a context
preserving runnable so that the headers and transients from the creation time of the bulk processor
are available during the execution of the flush.

Closes #26596
jaymode added a commit that referenced this pull request Sep 20, 2017
…on time (#26718)

When using a bulk processor, the thread context was not preserved for the flush runnable which is
executed in another thread in the thread pool. This change wraps the flush runnable in a context
preserving runnable so that the headers and transients from the creation time of the bulk processor
are available during the execution of the flush.

Closes #26596
jaymode added a commit that referenced this pull request Sep 20, 2017
…on time (#26718)

When using a bulk processor, the thread context was not preserved for the flush runnable which is
executed in another thread in the thread pool. This change wraps the flush runnable in a context
preserving runnable so that the headers and transients from the creation time of the bulk processor
are available during the execution of the flush.

Closes #26596
jasontedor added a commit to jasontedor/elasticsearch that referenced this pull request Sep 20, 2017
* master:
  [DOCS] Added index-shared4 and index-shared5.asciidoc
  BulkProcessor flush runnable preserves the thread context from creation time (elastic#26718)
  Catch exceptions and inform handler in RemoteClusterConnection#collectNodes (elastic#26725)
  [Docs] Fix name of character filter in example. (elastic#26724)
  Remove parse field deprecations in query builders (elastic#26711)
  elastic#26720: Set the correct bwc version after backport to 6.0
  Remove deprecated type and slop field in MatchQueryBuilder (elastic#26720)
  Refactoring of Gateway*** classes (elastic#26706)
  Make RestHighLevelClient's Request class public (elastic#26627)
  Deguice ActionFilter (elastic#26691)
  aggs: Allow aggregation sorting via nested aggregation.
  Build: Set bwc builds to always set snapshot (elastic#26704)
  File Discovery: Remove fallback with zen discovery (elastic#26667)
@colings86 colings86 added v6.0.0-rc1 and removed v6.0.0 labels Sep 22, 2017
@lcawl lcawl removed the v6.1.0 label Dec 12, 2017
@colings86 colings86 added v7.0.0-beta1 and removed v7.0.0 labels Feb 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
7 participants
You can’t perform that action at this time.