[
https://issues.apache.org/jira/browse/CASSANDRA-1186?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12881176#action_12881176
]
Gary Dusbabek commented on CASSANDRA-1186:
------------------------------------------
Moving to Avro/Thrift serialization isn't going to fix this. If anything, it
will make things more brittle since we would yield control the the
serialization/deserialization process to outside code (we wouldn't be able to
slip in default values to old versions when they are deserialized against the
new schema, etc.).
A simple test of serializing an instance, adding a new field to the class,
regenerating it, and then attempting to deserialize the old version confirmed
that Avro can't handle this. I suspect the same thing will happen with Thrift.
If we use Avro and serialize to JSON, it would be easy to provide a migration
tool that would update serialized schema from version to version.
> futureproof [KS|CF]MetaData
> ---------------------------
>
> Key: CASSANDRA-1186
> URL: https://issues.apache.org/jira/browse/CASSANDRA-1186
> Project: Cassandra
> Issue Type: Improvement
> Components: Core
> Affects Versions: 0.7
> Reporter: Jonathan Ellis
> Assignee: Gary Dusbabek
> Priority: Critical
> Fix For: 0.7
>
>
> KSMetaData/CFMetaData serialization is fragile. We need to be able to add
> fields easily without breaking when we read old-style serialized bytes.
> Avro and Thrift are designed to handle this. We should probably use one of
> those rather than re-inventing the wheel. If Avro is mature enough for this
> then let's use that, otherwise let's use Thrift.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.