thrift: Fail when mixed CFs are detected

Fixes #2588

Signed-off-by: Duarte Nunes <duarte@scylladb.com>
Message-Id: <20170717222612.7429-1-duarte@scylladb.com>
This commit is contained in:
Duarte Nunes
2017-07-18 00:26:12 +02:00
committed by Avi Kivity
parent 64ef7aa5e4
commit d9fa3bf322

View File

@@ -894,7 +894,7 @@ public:
}
auto s = schema_from_thrift(cf_def, cf_def.keyspace, schema->id());
if (schema->thrift().is_dynamic() && !s->thrift().is_dynamic()) {
if (schema->thrift().is_dynamic() != s->thrift().is_dynamic()) {
fail(unimplemented::cause::MIXED_CF);
}
return _query_state.get_client_state().has_schema_access(*schema, auth::permission::ALTER).then([this, s = std::move(s)] {