feat: distributed alter table in region server (#97)

* feat: alter region request
This commit is contained in:
LFC
2023-09-04 18:58:35 +08:00
committed by GitHub
parent b585955dbb
commit 1969b5d610
14 changed files with 10367 additions and 5386 deletions
+18 -14
View File
@@ -60,9 +60,6 @@ message AlterExpr {
DropColumns drop_columns = 5;
RenameTable rename_table = 6;
}
TableId table_id = 7;
// table version before altering.
uint64 table_version = 8;
}
message DropTableExpr {
@@ -93,19 +90,26 @@ message RenameTable { string new_table_name = 1; }
message AddColumn {
ColumnDef column_def = 1;
bool is_key = 2;
message Location {
enum LocationType {
FIRST = 0;
AFTER = 1;
}
LocationType location_type = 1;
string after_column_name = 2;
}
Location location = 3;
AddColumnLocation location = 3;
}
message DropColumn { string name = 1; }
message TableId { uint32 id = 1; }
message ColumnDef {
string name = 1;
ColumnDataType data_type = 2;
bool is_nullable = 3;
bytes default_constraint = 4;
SemanticType semantic_type = 5;
}
message AddColumnLocation {
enum LocationType {
FIRST = 0;
AFTER = 1;
}
LocationType location_type = 1;
string after_column_name = 2;
}