Avoid extra byte-array copy in DistCache

I tried using `ByteVector` but at the end of the world you lose the ability to do a simple `write(byte[], 0, length)` copy. Not sure if there's a better/nicer way.