Problem
Previously, we used `from_wire` and `to_wire` inline to encode and
decode record batches. This means we always have to match on the format,
and, more importantly, doesn't allow for reuse of the zstd
encoder/decoder.
Summary of Changes
Refactor such that the encoder and decoder can have the same lifetime
as the sender/receiver session.