-
Notifications
You must be signed in to change notification settings - Fork 194
fix: error propagation in http-connect mode #475
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
fix: error propagation in http-connect mode #475
Conversation
Hi @ipochi. Thanks for your PR. I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/ok-to-test |
@ipochi: Cannot trigger testing until a trusted user reviews the PR and leaves an In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/ok-to-test |
Thanks for sending this PR! Is it feasible to add a unit test around this propagation? |
c5d7120
to
6994a35
Compare
/ok-to-test |
6994a35
to
0e43f90
Compare
/ok-to-test |
/retest |
0e43f90
to
fd1de7e
Compare
/retest |
@cheftako Need some help in understanding why the test fails ?
|
fd1de7e
to
b911f64
Compare
never mind, figured it out. Added a unit test as well. |
b911f64
to
c37aed4
Compare
Seems like a good change. In answer to your earlier question, I think a 5xx series error makes more sense. |
@cheftako Thank you for the review. 400 was merely a placeholder. I agree with a 5XX range as the status code. |
If there is an error encountered by the proxy-server, such as DNS lookup, this is not propagated back correctly to the client in http-connect mode. This PR adds an http response, conveying the error message to the client before closing the http connection. Signed-off-by: Imran Pochi <imranpochi@microsoft.com>
c37aed4
to
5c7f6ae
Compare
/test pull-apiserver-network-proxy-test |
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: cheftako, ipochi The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
If there is an error encountered by the proxy-server, such as DNS lookup, this is currently not propagated currently back to the client in http-connect mode.
This PR adds a http response, conveying the error message to the client before closing the http connection.
I'm unsure about the Status Code, hence it is merely as a placeholder for now whether the status code should be in the 400 or 500 range.
fixes: #458