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
Adding accept header to callsites within SignalR #55271
base: main
Are you sure you want to change the base?
Adding accept header to callsites within SignalR #55271
Conversation
…reateHttpClient()
…value on relevant call sites
…pt header in NegotiateAsync()
Are you actually changing anything, or just kicking the build? If it's kicking the build please stop.
|
Looks like you're missing negotiate? Otherwise I think that covers all the spots. |
I'm sorry to see this closed, anything I can help with? It looked really close to finished. |
…t testing. Adding an optional HttpMessageHandler parameter for CreateHttpClient.
…t header to the Http Request
Hello @BrennanConroy, I've reopened the PR and pushed some new commits. I'm encountering a couple of challenges that I'm currently addressing:
To better test the I welcome any constructive feedback on the testing approach I've implemented for the various call sites. I'm actively working to resolve the issues mentioned above. |
Why not use aspnetcore/src/SignalR/common/Http.Connections/test/HttpConnectionDispatcherTests.cs Line 3272 in 0bae45e
|
Adding accept header to callsites within SignalR
Summary of the changes
As mentioned in #47398, many of the
HttpClient
call sites within the SignalR library were missing their appropriate accept headers. This change aims to address that issue.Description
Changes made include:
Negotiate()
withinHttpConnection
to ensure header is present for negotiation requests.SendMessage()
withinSendUtils
for thesend
requests.Poll()
withinLongPollingTransport
for theget
request.LongPollingTransport
have the correct accept headerServerSentEventsTransport
has the correct accept headerHttpConnection
has the correct accept header.Fixes #47398 by ensuring the negotiation requests and other HttpClient call sites of SignalR are made with the relevant accept header.