2021-01-14 14:24:14 +08:00
|
|
|
syntax = "proto3";
|
|
|
|
package milvus.proto.internal;
|
2021-04-22 14:45:57 +08:00
|
|
|
option go_package = "github.com/milvus-io/milvus/internal/proto/internalpb";
|
2021-01-14 14:24:14 +08:00
|
|
|
|
|
|
|
import "common.proto";
|
2021-05-19 18:45:15 +08:00
|
|
|
import "schema.proto";
|
2021-01-14 14:24:14 +08:00
|
|
|
|
2021-03-12 14:22:09 +08:00
|
|
|
message GetTimeTickChannelRequest {
|
|
|
|
}
|
|
|
|
|
|
|
|
message GetStatisticsChannelRequest {
|
|
|
|
}
|
|
|
|
|
|
|
|
message GetDdChannelRequest {
|
|
|
|
}
|
|
|
|
|
|
|
|
message NodeInfo {
|
2021-01-14 14:24:14 +08:00
|
|
|
common.Address address = 1;
|
|
|
|
string role = 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
message InitParams {
|
|
|
|
int64 nodeID = 1;
|
|
|
|
repeated common.KeyValuePair start_params = 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
message StringList {
|
2021-01-22 11:07:07 +08:00
|
|
|
repeated string values = 1;
|
|
|
|
common.Status status = 2;
|
2021-01-14 14:24:14 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
message TimeTickMsg {
|
2021-01-16 15:06:19 +08:00
|
|
|
common.MsgBase base = 1;
|
2021-01-14 14:24:14 +08:00
|
|
|
}
|
|
|
|
|
2022-07-18 09:58:28 +08:00
|
|
|
message GetStatisticsRequest {
|
|
|
|
common.MsgBase base = 1;
|
|
|
|
// Not useful for now
|
|
|
|
int64 dbID = 2;
|
|
|
|
// The collection you want get statistics
|
|
|
|
int64 collectionID = 3;
|
|
|
|
// The partitions you want get statistics
|
|
|
|
repeated int64 partitionIDs = 4;
|
|
|
|
// timestamp of the statistics
|
|
|
|
uint64 travel_timestamp = 5;
|
|
|
|
uint64 guarantee_timestamp = 6;
|
|
|
|
uint64 timeout_timestamp = 7;
|
|
|
|
}
|
|
|
|
|
|
|
|
message GetStatisticsResponse {
|
|
|
|
common.MsgBase base = 1;
|
|
|
|
// Contain error_code and reason
|
|
|
|
common.Status status = 2;
|
|
|
|
// Collection statistics data. Contain pairs like {"row_count": "1"}
|
|
|
|
repeated common.KeyValuePair stats = 3;
|
|
|
|
}
|
|
|
|
|
2021-01-18 19:32:08 +08:00
|
|
|
message CreateCollectionRequest {
|
|
|
|
common.MsgBase base = 1;
|
|
|
|
string db_name = 2;
|
|
|
|
string collectionName = 3;
|
2021-07-06 09:16:03 +08:00
|
|
|
string partitionName = 4;
|
2021-01-18 19:32:08 +08:00
|
|
|
// `schema` is the serialized `schema.CollectionSchema`
|
2021-07-06 09:16:03 +08:00
|
|
|
int64 dbID = 5;
|
|
|
|
int64 collectionID = 6;
|
|
|
|
int64 partitionID = 7;
|
|
|
|
bytes schema = 8;
|
|
|
|
repeated string virtualChannelNames = 9;
|
|
|
|
repeated string physicalChannelNames = 10;
|
2021-01-18 19:32:08 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
message DropCollectionRequest {
|
|
|
|
common.MsgBase base = 1;
|
|
|
|
string db_name = 2;
|
|
|
|
string collectionName = 3;
|
|
|
|
int64 dbID = 4;
|
|
|
|
int64 collectionID = 5;
|
|
|
|
}
|
|
|
|
|
|
|
|
message CreatePartitionRequest {
|
|
|
|
common.MsgBase base = 1;
|
|
|
|
string db_name = 2;
|
|
|
|
string collection_name = 3;
|
|
|
|
string partition_name = 4;
|
2021-03-12 14:22:09 +08:00
|
|
|
int64 dbID = 5;
|
2021-01-18 19:32:08 +08:00
|
|
|
int64 collectionID = 6;
|
|
|
|
int64 partitionID = 7;
|
|
|
|
}
|
|
|
|
|
|
|
|
message DropPartitionRequest {
|
|
|
|
common.MsgBase base = 1;
|
|
|
|
string db_name = 2;
|
|
|
|
string collection_name = 3;
|
|
|
|
string partition_name = 4;
|
2021-03-12 14:22:09 +08:00
|
|
|
int64 dbID = 5;
|
2021-01-18 19:32:08 +08:00
|
|
|
int64 collectionID = 6;
|
|
|
|
int64 partitionID = 7;
|
|
|
|
}
|
|
|
|
|
2021-09-18 11:13:51 +08:00
|
|
|
message CreateAliasRequest {
|
|
|
|
common.MsgBase base = 1;
|
2021-10-01 21:40:21 +08:00
|
|
|
string db_name = 2;
|
|
|
|
string collection_name = 3;
|
|
|
|
string alias = 4;
|
2021-09-18 11:13:51 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
message DropAliasRequest {
|
|
|
|
common.MsgBase base = 1;
|
2021-10-01 21:40:21 +08:00
|
|
|
string db_name = 2;
|
|
|
|
string alias = 3;
|
2021-09-18 11:13:51 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
message AlterAliasRequest{
|
|
|
|
common.MsgBase base = 1;
|
2021-10-01 21:40:21 +08:00
|
|
|
string db_name = 2;
|
|
|
|
string collection_name = 3;
|
|
|
|
string alias = 4;
|
2021-09-18 11:13:51 +08:00
|
|
|
}
|
|
|
|
|
2021-01-18 19:32:08 +08:00
|
|
|
message CreateIndexRequest {
|
|
|
|
common.MsgBase base = 1;
|
|
|
|
string db_name = 2;
|
|
|
|
string collection_name = 3;
|
|
|
|
string field_name = 4;
|
|
|
|
int64 dbID = 5;
|
|
|
|
int64 collectionID = 6;
|
|
|
|
int64 fieldID = 7;
|
|
|
|
repeated common.KeyValuePair extra_params = 8;
|
|
|
|
}
|
|
|
|
|
2022-03-04 15:09:56 +08:00
|
|
|
enum InsertDataVersion {
|
|
|
|
// 0 must refer to row-based format, since it's the first version in Milvus.
|
|
|
|
RowBased = 0;
|
|
|
|
ColumnBased = 1;
|
|
|
|
}
|
|
|
|
|
2021-01-18 19:32:08 +08:00
|
|
|
message InsertRequest {
|
|
|
|
common.MsgBase base = 1;
|
2021-09-27 10:01:59 +08:00
|
|
|
string shardName = 2;
|
|
|
|
string db_name = 3;
|
|
|
|
string collection_name = 4;
|
|
|
|
string partition_name = 5;
|
|
|
|
int64 dbID = 6;
|
|
|
|
int64 collectionID = 7;
|
|
|
|
int64 partitionID = 8;
|
|
|
|
int64 segmentID = 9;
|
2021-01-22 11:44:02 +08:00
|
|
|
repeated uint64 timestamps = 10;
|
|
|
|
repeated int64 rowIDs = 11;
|
2022-03-04 15:09:56 +08:00
|
|
|
// row_data was reserved for compatibility
|
2021-01-22 11:44:02 +08:00
|
|
|
repeated common.Blob row_data = 12;
|
2022-03-04 15:09:56 +08:00
|
|
|
repeated schema.FieldData fields_data = 13;
|
|
|
|
uint64 num_rows = 14;
|
|
|
|
InsertDataVersion version = 15;
|
2021-01-18 19:32:08 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
message SearchRequest {
|
|
|
|
common.MsgBase base = 1;
|
2022-05-23 16:41:58 +08:00
|
|
|
int64 reqID = 2;
|
2021-02-03 11:52:19 +08:00
|
|
|
int64 dbID = 3;
|
|
|
|
int64 collectionID = 4;
|
|
|
|
repeated int64 partitionIDs = 5;
|
|
|
|
string dsl = 6;
|
|
|
|
// serialized `PlaceholderGroup`
|
|
|
|
bytes placeholder_group = 7;
|
2021-05-07 15:20:47 +08:00
|
|
|
common.DslType dsl_type = 8;
|
2021-05-07 19:27:17 +08:00
|
|
|
bytes serialized_expr_plan = 9;
|
2021-06-21 20:18:13 +08:00
|
|
|
repeated int64 output_fields_id = 10;
|
|
|
|
uint64 travel_timestamp = 11;
|
2021-06-30 21:02:13 +08:00
|
|
|
uint64 guarantee_timestamp = 12;
|
2021-12-08 14:15:03 +08:00
|
|
|
uint64 timeout_timestamp = 13;
|
2022-05-23 16:41:58 +08:00
|
|
|
int64 nq = 14;
|
|
|
|
int64 topk = 15;
|
|
|
|
string metricType = 16;
|
2021-01-18 19:32:08 +08:00
|
|
|
}
|
2021-02-03 11:52:19 +08:00
|
|
|
|
2021-01-18 19:32:08 +08:00
|
|
|
message SearchResults {
|
|
|
|
common.MsgBase base = 1;
|
|
|
|
common.Status status = 2;
|
2022-05-23 16:41:58 +08:00
|
|
|
int64 reqID = 3;
|
2021-01-18 19:32:08 +08:00
|
|
|
string metric_type = 4;
|
2021-08-24 11:13:52 +08:00
|
|
|
int64 num_queries = 5;
|
|
|
|
int64 top_k = 6;
|
|
|
|
repeated int64 sealed_segmentIDs_searched = 7;
|
|
|
|
repeated string channelIDs_searched = 8;
|
|
|
|
repeated int64 global_sealed_segmentIDs = 9;
|
2021-06-21 20:18:13 +08:00
|
|
|
// schema.SearchResultsData inside
|
2021-08-24 11:13:52 +08:00
|
|
|
bytes sliced_blob = 10;
|
|
|
|
int64 sliced_num_count = 11;
|
|
|
|
int64 sliced_offset = 12;
|
2021-01-18 19:32:08 +08:00
|
|
|
}
|
|
|
|
|
2021-05-19 18:45:15 +08:00
|
|
|
message RetrieveRequest {
|
|
|
|
common.MsgBase base = 1;
|
2022-05-23 16:41:58 +08:00
|
|
|
int64 reqID = 2;
|
2021-05-19 18:45:15 +08:00
|
|
|
int64 dbID = 3;
|
|
|
|
int64 collectionID = 4;
|
|
|
|
repeated int64 partitionIDs = 5;
|
2021-09-03 17:12:55 +08:00
|
|
|
bytes serialized_expr_plan = 6;
|
2021-07-14 13:11:54 +08:00
|
|
|
repeated int64 output_fields_id = 7;
|
2021-06-21 10:42:10 +08:00
|
|
|
uint64 travel_timestamp = 8;
|
2021-06-30 21:02:13 +08:00
|
|
|
uint64 guarantee_timestamp = 9;
|
2021-12-08 14:15:03 +08:00
|
|
|
uint64 timeout_timestamp = 10;
|
2022-09-01 18:54:58 +08:00
|
|
|
int64 limit = 11; // Optional
|
2021-05-19 18:45:15 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
message RetrieveResults {
|
|
|
|
common.MsgBase base = 1;
|
|
|
|
common.Status status = 2;
|
2022-05-23 16:41:58 +08:00
|
|
|
int64 reqID = 3;
|
2021-05-19 18:45:15 +08:00
|
|
|
schema.IDs ids = 4;
|
|
|
|
repeated schema.FieldData fields_data = 5;
|
2021-06-15 11:01:13 +08:00
|
|
|
repeated int64 sealed_segmentIDs_retrieved = 6;
|
|
|
|
repeated string channelIDs_retrieved = 7;
|
|
|
|
repeated int64 global_sealed_segmentIDs = 8;
|
2021-05-19 18:45:15 +08:00
|
|
|
}
|
|
|
|
|
2021-01-18 19:32:08 +08:00
|
|
|
message DeleteRequest {
|
|
|
|
common.MsgBase base = 1;
|
2021-09-27 10:01:59 +08:00
|
|
|
string shardName = 2;
|
|
|
|
string db_name = 3;
|
|
|
|
string collection_name = 4;
|
|
|
|
string partition_name = 5;
|
|
|
|
int64 dbID = 6;
|
|
|
|
int64 collectionID = 7;
|
|
|
|
int64 partitionID = 8;
|
2022-04-02 17:43:29 +08:00
|
|
|
repeated int64 int64_primary_keys = 9; // deprecated
|
2021-10-14 14:48:34 +08:00
|
|
|
repeated uint64 timestamps = 10;
|
2022-04-02 17:43:29 +08:00
|
|
|
int64 num_rows = 11;
|
|
|
|
schema.IDs primary_keys = 12;
|
2021-01-18 19:32:08 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
message LoadIndex {
|
|
|
|
common.MsgBase base = 1;
|
|
|
|
int64 segmentID = 2;
|
|
|
|
string fieldName = 3;
|
|
|
|
int64 fieldID = 4;
|
|
|
|
repeated string index_paths = 5;
|
|
|
|
repeated common.KeyValuePair index_params = 6;
|
|
|
|
}
|
|
|
|
|
|
|
|
message IndexStats {
|
|
|
|
repeated common.KeyValuePair index_params = 1;
|
|
|
|
int64 num_related_segments = 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
message FieldStats {
|
|
|
|
int64 collectionID = 1;
|
|
|
|
int64 fieldID = 2;
|
|
|
|
repeated IndexStats index_stats = 3;
|
|
|
|
}
|
|
|
|
|
|
|
|
message SegmentStats {
|
|
|
|
int64 segmentID = 1;
|
|
|
|
int64 memory_size = 2;
|
|
|
|
int64 num_rows = 3;
|
|
|
|
bool recently_modified = 4;
|
|
|
|
}
|
|
|
|
|
|
|
|
message MsgPosition {
|
|
|
|
string channel_name = 1;
|
2021-03-27 09:46:54 +08:00
|
|
|
bytes msgID = 2;
|
2021-03-22 16:36:10 +08:00
|
|
|
string msgGroup = 3;
|
|
|
|
uint64 timestamp = 4;
|
2021-01-21 09:55:25 +08:00
|
|
|
}
|
2021-05-21 16:08:12 +08:00
|
|
|
|
|
|
|
message ChannelTimeTickMsg {
|
|
|
|
common.MsgBase base = 1;
|
|
|
|
repeated string channelNames = 2;
|
|
|
|
repeated uint64 timestamps = 3;
|
2021-06-17 14:57:57 +08:00
|
|
|
uint64 default_timestamp = 4;
|
2021-05-21 16:08:12 +08:00
|
|
|
}
|
2022-04-11 19:49:34 +08:00
|
|
|
|
|
|
|
message CredentialInfo {
|
|
|
|
string username = 1;
|
2022-06-29 20:02:18 +08:00
|
|
|
// encrypted by bcrypt (for higher security level)
|
2022-04-11 19:49:34 +08:00
|
|
|
string encrypted_password = 2;
|
2022-05-28 00:04:01 +08:00
|
|
|
string tenant = 3;
|
|
|
|
bool is_super = 4;
|
2022-06-29 20:02:18 +08:00
|
|
|
// encrypted by sha256 (for good performance in cache mapping)
|
|
|
|
string sha256_password = 5;
|
2022-04-11 19:49:34 +08:00
|
|
|
}
|
2022-05-28 00:04:01 +08:00
|
|
|
|
|
|
|
message ListPolicyRequest {
|
|
|
|
// Not useful for now
|
|
|
|
common.MsgBase base = 1;
|
|
|
|
}
|
|
|
|
|
|
|
|
message ListPolicyResponse {
|
|
|
|
// Contain error_code and reason
|
|
|
|
common.Status status = 1;
|
|
|
|
repeated string policy_infos = 2;
|
2022-08-04 11:04:34 +08:00
|
|
|
repeated string user_roles = 3;
|
2022-07-23 17:14:28 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
message ShowConfigurationsRequest {
|
|
|
|
common.MsgBase base = 1;
|
|
|
|
string pattern = 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
message ShowConfigurationsResponse {
|
|
|
|
common.Status status = 1;
|
2022-09-16 09:56:47 +08:00
|
|
|
repeated common.KeyValuePair configuations = 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
enum RateType {
|
|
|
|
DDLCollection = 0;
|
|
|
|
DDLPartition = 1;
|
|
|
|
DDLIndex = 2;
|
|
|
|
DDLFlush = 3;
|
|
|
|
DDLCompaction = 4;
|
|
|
|
DMLInsert = 5;
|
|
|
|
DMLDelete = 6;
|
|
|
|
DMLBulkLoad = 7;
|
|
|
|
DQLSearch = 8;
|
|
|
|
DQLQuery = 9;
|
|
|
|
}
|
|
|
|
|
|
|
|
message Rate {
|
|
|
|
RateType rt = 1;
|
|
|
|
double r = 2;
|
2022-07-23 17:14:28 +08:00
|
|
|
}
|