thrift-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Benjy Weinberger <ben...@gmail.com>
Subject Re: Optional fields with conditional logic
Date Tue, 24 Jan 2012 17:12:58 GMT
If you're referring to a wire protocol, i.e., some protocol in which a
message header contains a bitfield indicating which fields are present
in the message, then that is not an advisable wire protocol.

The reason is that it does not provide protocol version compatibility:
a future version of the protocol cannot read old messages because the
bits in the bitfield may no longer correspond to the fields they
originally corresponded to.

On Tue, Jan 24, 2012 at 7:39 AM, Mike Stoddart <stodge@gmail.com> wrote:
> Does Thrift support conditional logic? For example, I have a protocol that
> uses the bits in a byte field to determine which of the subsequent optional
> fields are present. Thanks

Mime
View raw message