GIRAPH-977: useMessageSizeEncoding is broken

Summary: When useMessageSizeEncoding is set to true, any application using messaging and no combiner will fail. It looks like writing lengths of messages was lost at some point, so we are just trying to read the lengths without ever writing them.

Test Plan: Added a test, it failed without the change but succeeded with it.

Reviewers: sergey.edunov, pavanka

Differential Revision: https://reviews.facebook.net/D30825