cloudflare / cloudflare/quiche

Why doesn’t tokio-quiche provide a more user-friendly API?

Open
#2,299 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
11.8k
Forks
1.1k
Avg merge
21h 9m
Merged PRs (30d)
6

Description

Over the past two or three weeks, I’ve tried to write some simple test code using **tokio-quiche**, but I ran into many issues. For example:

* If `process_reads` does not read data in time (e.g. to apply backpressure), it will not be called again.
* If `wait_for_data` or other callbacks are not implemented correctly (what is a “correct” implementation?), the CPU may spin at 100%.

My question is: why doesn’t **tokio-quiche** provide a more ergonomic API? For example:

* `Conn` and `Stream` objects
* `open_stream` and `accept_stream` methods

I have read the article
[https://blog.cloudflare.com/async-quic-and-http-3-made-easy-tokio-quiche-is-now-open-source/](https://blog.cloudflare.com/async-quic-and-http-3-made-easy-tokio-quiche-is-now-open-source/)
but I still don’t see a convincing reason for this design choice.

I would appreciate some clarification. Thank you.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.