-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Add ThreadContextPermission for stashAndMergeHeaders and stashWithOrigin #15039
Conversation
Signed-off-by: Craig Perkins <[email protected]>
Signed-off-by: Craig Perkins <[email protected]>
❌ Gradle check result for 3892188: 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? |
❌ Gradle check result for fccc486: 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? |
Looking into test failures |
Signed-off-by: Craig Perkins <[email protected]>
D'oh. I forgot to surround the invocations in |
❌ Gradle check result for c0324b4: 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? |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #15039 +/- ##
============================================
+ Coverage 71.77% 71.87% +0.09%
- Complexity 62689 62810 +121
============================================
Files 5163 5165 +2
Lines 294412 294446 +34
Branches 42582 42589 +7
============================================
+ Hits 211325 211636 +311
+ Misses 65689 65390 -299
- Partials 17398 17420 +22 ☔ View full report in Codecov by Sentry. |
…gin (#15039) * Add ThreadContextPermission for stashAndMergeHeaders and stashWithOrigin Signed-off-by: Craig Perkins <[email protected]> * Add to CHANGELOG Signed-off-by: Craig Perkins <[email protected]> * Use ThreadContextAccess Signed-off-by: Craig Perkins <[email protected]> --------- Signed-off-by: Craig Perkins <[email protected]> (cherry picked from commit e7ee950) Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
I'll open up a manual backport with the deprecationLogger |
…gin (opensearch-project#15039) * Add ThreadContextPermission for stashAndMergeHeaders and stashWithOrigin Signed-off-by: Craig Perkins <[email protected]> * Add to CHANGELOG Signed-off-by: Craig Perkins <[email protected]> * Use ThreadContextAccess Signed-off-by: Craig Perkins <[email protected]> --------- Signed-off-by: Craig Perkins <[email protected]>
Opened a manual backport with deprecationLogger changes: #15049 |
@@ -213,6 +215,10 @@ public Writeable captureAsWriteable() { | |||
* if it can't find the task in memory. | |||
*/ | |||
public StoredContext stashWithOrigin(String origin) { |
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.
@cwperks my apologies, I missed that, could you please add javadocs here the same way we did for markAsSystemContext
? Thank you.
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.
yes absolutely. That's my bad. I should have included that in the PR. Good catch.
…nd stashWithOrigin (#15049) * Add ThreadContextPermission for stashAndMergeHeaders and stashWithOrigin (#15039) * Add ThreadContextPermission for stashAndMergeHeaders and stashWithOrigin Signed-off-by: Craig Perkins <[email protected]> * Add to CHANGELOG Signed-off-by: Craig Perkins <[email protected]> * Use ThreadContextAccess Signed-off-by: Craig Perkins <[email protected]> --------- Signed-off-by: Craig Perkins <[email protected]> * Add deprecationLogger Signed-off-by: Craig Perkins <[email protected]> --------- Signed-off-by: Craig Perkins <[email protected]>
…gin (opensearch-project#15039) * Add ThreadContextPermission for stashAndMergeHeaders and stashWithOrigin Signed-off-by: Craig Perkins <[email protected]> * Add to CHANGELOG Signed-off-by: Craig Perkins <[email protected]> * Use ThreadContextAccess Signed-off-by: Craig Perkins <[email protected]> --------- Signed-off-by: Craig Perkins <[email protected]>
…gin (opensearch-project#15039) * Add ThreadContextPermission for stashAndMergeHeaders and stashWithOrigin Signed-off-by: Craig Perkins <[email protected]> * Add to CHANGELOG Signed-off-by: Craig Perkins <[email protected]> * Use ThreadContextAccess Signed-off-by: Craig Perkins <[email protected]> --------- Signed-off-by: Craig Perkins <[email protected]>
Description
Similar to #15016, but extends it to more methods in the ThreadContextClass. This PR introduces permissions for stashAndMergeHeaders (used in test context only) and stashWithOrigin.
Related Issues
Related to #14931
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.