HeaderPropagation: add support for hosted services#12170
Closed
alefranz wants to merge 1 commit intodotnet:masterfrom
Closed
HeaderPropagation: add support for hosted services#12170alefranz wants to merge 1 commit intodotnet:masterfrom
alefranz wants to merge 1 commit intodotnet:masterfrom
Conversation
fde063f to
8cca794
Compare
Contributor
Contributor
Author
|
Hi Andrew, This has been partially addressed with #12636, as now you get a proper exception when trying to consume this from a hosted service. Thank you. |
Contributor
|
@alefranz I don't think we necessarily need to close the issue, but I think I will close this PR since it's gotten pretty stale and would need significant rebasing anyway. If we come to an agreement on the issue that we do want this functionality and how we want to implement it, I don't see any problem with opening a new PR with this change. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is a possible solution to fix #12169, adding the ability to use a HttpClient with the
HeaderPropagationMessageHandleroutside of a http requests.It also adds the ability to reuse the functionality of the
HeaderPropagationMiddlewarein different scenarios, for example when consuming messages from a queue, however I guess this scenario is out of scope for a middleware.HttpContextThe main issue I see with this approach is that when the processor is used directly you must take extra care as you need a different async context per request.
Addresses #12169
/cc @rynowak