So tokio-rs had me really confused on how to properly use split streams and sinks to read and write io, so I made a simplified interface to save others (and myself) some trouble.

Check it out, it's called tokio-simplified, and it's on https://crates.io/crates/...

I like it, you can place as many callbacks as you want to respond to each frame from the stream, and use as many mpsc::senders as you like to write to the sink.

And as a bonus, you can have a filter callback called before any other, to choose whether or not a frame should make it to the others, and bonus feature: that callback is 0 cost against just passing it as a for_each on your stream.

Hope it helps some of you on your journeys to Rust

Your Job Suck?
Get a Better Job
Add Comment