cloudflare / quiche

šŸ„§ Savoury implementation of the QUIC transport protocol and HTTP/3

Home Page:https://docs.quic.tech/quiche/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Async Implementation

ETisREAL opened this issue Ā· comments

Hello, just a quick info check, is there any "simple" way to make the library work with a tokio runtime asynchronously? TY

There is a way to use the quiche library with tokio by just adding a thin wrapper to make it asynchronous. I am currently working on it, but it is definitely feasible and low-cost.

The basic idea is to make potentially blocking quiche methods asynchronous, for example, by returning Poll::Pending when Connection.send returns Done, and waking up at the appropriate time.

Ok, got you. Thank you for the example as well. Very helpful :)