-
Notifications
You must be signed in to change notification settings - Fork 2.3k
[WLM] add WLM header propagator #18571
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
base: main
Are you sure you want to change the base?
[WLM] add WLM header propagator #18571
Conversation
Signed-off-by: Kaushal Kumar <ravi.kaushal97@gmail.com>
❌ Gradle check result for 6d5e32a: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
Signed-off-by: Kaushal Kumar <ravi.kaushal97@gmail.com>
Signed-off-by: Kaushal Kumar <ravi.kaushal97@gmail.com>
@@ -595,6 +596,7 @@ protected Node(final Environment initialEnvironment, Collection<PluginInfo> clas | |||
|
|||
runnableTaskListener = new AtomicReference<>(); | |||
final ThreadPool threadPool = new ThreadPool(settings, runnableTaskListener, executorBuilders.toArray(new ExecutorBuilder[0])); | |||
threadPool.getThreadContext().registerThreadContextStatePropagator(new WorkloadGroupThreadContextStatePropagator()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think a better way would be to do this inside WorkloadGroupThreadContextStatePropagator
?
WorkloadGroupThreadContextStatePropagator(ThreadContext threadContext) {
threadContext. registerThreadContextStatePropagator(this);
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we also add a basic test to verify this functionality?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will add a UT which will confirm the behavior
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think a better way would be to do this inside WorkloadGroupThreadContextStatePropagator?
Why do we think that is a better way, In the end we will still have to init the WorkloadGroupThreadContextStatePropagator
somewhere
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #18571 +/- ##
============================================
+ Coverage 72.68% 72.73% +0.04%
- Complexity 68130 68154 +24
============================================
Files 5540 5540
Lines 313379 313380 +1
Branches 45472 45472
============================================
+ Hits 227785 227922 +137
+ Misses 67070 66979 -91
+ Partials 18524 18479 -45 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Description
This will make the workloadGroupId header propagable by adding the
WorkloadGroupThreadContextStatePropagator
to list ofThreadContext#propagators
.Check List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.