RowMutation rm = new RowMutation(Table.SYSTEM_TABLE, versionKey);
long now = System.currentTimeMillis();
for (String ksname : ksnames)
{
KSMetaData ksm = org.apache.cassandra.config.Schema.instance.getTableDefinition(ksname);
rm.add(new QueryPath(Migration.SCHEMA_CF, null, ByteBufferUtil.bytes(ksm.name)), SerDeUtils.serialize(ksm.toAvro()), now);
}
// add the schema
rm.add(new QueryPath(Migration.SCHEMA_CF,
null,
DEFINITION_SCHEMA_COLUMN_NAME),