quinn-rs / quinn

Async-friendly QUIC implementation in Rust
Apache License 2.0
3.85k stars 394 forks source link

Document how to close a stream correctly #1493

Closed flub closed 1 year ago

flub commented 1 year ago

It is not trivial to correctly close a stream without errors and knowing everything is fully acknowledged. Describe some details around this.

flub commented 1 year ago

Good call on actually compiling the example, there were quite a few errors!

I've left some EOF wording in there since I think that is the terminology when using stream I think. Let me know if you'd still like to remove this.

flub commented 1 year ago

Please take another look, I've adopted the suggested wording changes.

flub commented 1 year ago

Apologies for just using the github suggestions and letting CI find the bugs, which is just painful and slow.

I've fixed up the example locally and it all works again. I stuck with .read_to_end(0) and updated the description saying when it calls .stop().