[FLINK-23712] Improve Protobuf serialization performance

Profiling allocations shows that around 25% of the allocations happens
while parsing Protobuf, this happens because
the CodedInputStream/CodedOutputStream allocate a 4kb buffer on construction.
This can be easily avoided by caching and reusing them.

This closes #251.
1 file changed