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

Prevent CompleteableFuture$UniApply from being contextualized #247

Merged
merged 1 commit into from
Jan 15, 2021

Conversation

geoand
Copy link
Contributor

@geoand geoand commented Jan 15, 2021

This class cannot be created by user code (it is package private in the JDK)
and therefore will never need to be contextualized.
This class is created by the JDK when completeableFuture.thenApplyAsync is used
and without this PR, context propagation came into place twice:
once for the function passed to the thenApplyAsync and once for the UniApply Runnable

manovotn
manovotn previously approved these changes Jan 15, 2021
Copy link
Contributor

@manovotn manovotn left a comment

Choose a reason for hiding this comment

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

Looks like good catch!

This class cannot be created by user core (it is package private in the JDK)
and therefore will never need to be contextualized.
This class is created by the JDK when completeableFuture.thenApplyAsync is used
and without this PR, context propagation came into place twice:
once for the function passed to the thenApplyAsync and once for the UniApply Runnable
@geoand geoand force-pushed the uniapply-runnable branch from 1b83d22 to 756e463 Compare January 15, 2021 16:22
@manovotn manovotn merged commit 76fbda7 into smallrye:master Jan 15, 2021
@FroMage FroMage added this to the 1.1.0 milestone Jan 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants