Replace thrift by PB