vsfs/vsfs — pull request #11 by eddyxu (2013-05-31 19:53:35+00:00)
Title: Use Thrift to replace ProtoBuf as the serialization solution

Rational: we've already used thrift as RPC framework, which supports serialization. Although its serialization is not well-documented as what Protobuf did and its serialization performance / size is slightly worse than Protobuf [1]. But using Thrift object directly is expected to avoid many memory copying between protobuf object, thrift object and maybe our defined c++ objects as well.

```
ThriftObj tobj;
tobj.a_int = proto_obj.a_int;
tobj.a_map = proto_obj.a_map; // Copy an entire STL container.
....

FooServer->send_request(tobj);
```

It does not only introduce some memory copy overhead, more importantly, it might add many unnecessary overhead of development. It also eliminates one dependance.

So I suggest to use thrift serialization until it is demonstrated as a bottleneck.

[1] https://github.com/eishay/jvm-serializers/wiki