-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
docs(server): http_proxy example #1835
Conversation
examples/http_proxy.rs
Outdated
// ``` | ||
// | ||
// When HTTP method is CONNECT we should return an empty body | ||
// then we can eventually upgrade the connection and talk a new protocal. |
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.
// then we can eventually upgrade the connection and talk a new protocal. | |
// then we can eventually upgrade the connection and talk a new protocol. |
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.
Looks good to me. Very educational.
0e6ec1c
to
3d03e7b
Compare
@ahmedcharles there have been a lot of change since this example is written. I found tokio has plan to get |
See: https://github.com/ahmedcharles/hyper/commit/cc37f87d6ebfd5a3db618852fc1788b2c88db515 It's hacky but it works. (Though, h2 doesn't build at the moment, so when I rebased, it failed to build.) |
773481d
to
1c3ae26
Compare
1c3ae26
to
b36f3dd
Compare
@ahmedcharles thanks, it works! I changed your code a little, |
No problem. |
Thanks for doing this, and sorry for taking so long, I've rebased and merged this into master manually! |
I added a CONNECT tunneling example #1759