Closed davidpdrsn closed 10 months ago
Hi David, I'll have some time the next couple of weeks and would like to help with this one, if possible.
Cheers
Go ahead! Just post here which example you’re working on so others know.
I'll fix rest-grpc-multiplex example until tonic support http 1.0.
@takkuumi what do you mean? The example can't be updated yet.
@takkuumi what do you mean? The example can't be updated yet.
Not this mean, I’d wrote this example and I think that i can help on it.
I'm pretty sure the example can't be updated yet because tonic uses http 0.2 and axum now requires http 1.0. You can't convert requests/responses from 0.2 to 1.0 because extensions are totally opaque. Having to put a bunch of conversion code in an example isn't appropriate either.
I think people using axum with tonic will have to wait until tonic has been updated.
It looks like the tls-graceful-shutdown
example is missing from this list.
axum 0.7 is really a big breaking
Go ahead! Just post here which example you’re working on so others know.
Thanks. Working on http-proxy first.
Will update here. Cheers.
Made a PR https://github.com/tokio-rs/axum/pull/2375 to update low-level-rustls and https://github.com/tokio-rs/axum/pull/2376 to update low-level-openssl
Made a PR https://github.com/tokio-rs/axum/pull/2384 to update tls-graceful-shutdown
Here's my shot at reverse_proxy example.
- [x] testing - No blockers. Can use hyper-util's legacy client (claimed by @davidpdrsn)
Not sure this is the best place to report as I see testing
is already updated.
I run with the following when running the example testing (with 0.7.1 and fresh git pull
)
$cargo test -p example-testing
Compiling hyper-util v0.1.1
error[E0599]: no method named `with_retries` found for struct `TcpKeepalive` in the current scope
--> .cargo/registry/src/index.crates.io-6f17d22bba15001f/hyper-util-0.1.1/src/client/legacy/connect/http.rs:130:12
|
130 | ka.with_retries(retries)
| ^^^^^^^^^^^^ help: there is a method with a similar name: `with_time`
For more information about this error, try `rustc --explain E0599`.
error: could not compile `hyper-util` (lib) due to previous error
Sounds like hyper-util has one of its dependency specifications wrong. cargo update
should work around it.
@davidpdrsn I just realised I did update the only commit in the PR #2430 after you merged so the changes on the comments here https://github.com/gerardcl/axum/commit/93799cf24d56e9140ca2850b69716d59865002e0#diff-60c9dfa63b6f41b8064cb70bbde4726a91cc3895257ef8b6c39c73c46b223b8eR65 and here https://github.com/gerardcl/axum/commit/93799cf24d56e9140ca2850b69716d59865002e0#diff-60c9dfa63b6f41b8064cb70bbde4726a91cc3895257ef8b6c39c73c46b223b8eR75 , did not get in. Let me know if you want me to fix it somehow. Thanks!
The code looks okay to me https://github.com/tokio-rs/axum/blob/main/examples/reqwest-response/src/main.rs#L67. Am I missing something?
hi @davidpdrsn , that is correct, but not the comment above and below, see the difference in the links in my previous comment. The first comment would be still fine but not the second IMHO.
Ah I see. You're free to submit a PR to clean that up :)
I think I'll close this issue now for now. All examples except rest-grpc-multiplex has been updated and that is blocked by tonic being updated. Nothing really we can do about that here. Follow https://github.com/hyperium/tonic/issues/1579 for more updates.
Thanks to everyone who helped porting examples ❤️
This tracks the examples that haven't yet been updated to axum 0.7: