Given the protocol you linked in your internals post, this looks like something that would be better handled via tokio_util::codec
's Encoder
and Decoder
traits, along with the Framed
abstraction it provides for sending and receiving bytes.
2 Likes