mirror of
https://github.com/scylladb/scylladb.git
synced 2026-04-24 02:20:37 +00:00
db: Do not fail when creating a table with composite partition key
This commit is contained in:
@@ -63,7 +63,7 @@ schema::schema(sstring ks_name, sstring cf_name, std::vector<column> partition_k
|
||||
thrift.partition_key_type = partition_key[0].type;
|
||||
} else {
|
||||
// TODO: the type should be composite_type
|
||||
throw std::runtime_error("not implemented");
|
||||
warn(unimplemented::cause::LEGACY_COMPOSITE_KEYS);
|
||||
}
|
||||
|
||||
build_columns(partition_key, column_definition::column_kind::PARTITION, _partition_key);
|
||||
|
||||
@@ -25,6 +25,7 @@ std::ostream& operator<<(std::ostream& out, cause c) {
|
||||
case cause::COMPACT_TABLES: return out << "COMPACT_TABLES";
|
||||
case cause::GOSSIP: return out << "GOSSIP";
|
||||
case cause::TOKEN_RESTRICTION: return out << "TOKEN_RESTRICTION";
|
||||
case cause::LEGACY_COMPOSITE_KEYS: return out << "LEGACY_COMPOSITE_KEYS";
|
||||
}
|
||||
assert(0);
|
||||
}
|
||||
|
||||
@@ -24,6 +24,7 @@ enum class cause {
|
||||
COMPACT_TABLES,
|
||||
GOSSIP,
|
||||
TOKEN_RESTRICTION,
|
||||
LEGACY_COMPOSITE_KEYS,
|
||||
};
|
||||
|
||||
void fail(cause what) __attribute__((noreturn));
|
||||
|
||||
Reference in New Issue
Block a user