2021-01-14 06:24:14 +00:00
|
|
|
syntax = "proto3";
|
|
|
|
|
|
|
|
package milvus.proto.index;
|
|
|
|
|
|
|
|
option go_package = "github.com/zilliztech/milvus-distributed/internal/proto/indexpb";
|
|
|
|
|
|
|
|
import "common.proto";
|
|
|
|
import "internal.proto";
|
|
|
|
|
|
|
|
|
|
|
|
message RegisterNodeRequest {
|
2021-01-16 07:06:19 +00:00
|
|
|
common.MsgBase base = 1;
|
2021-01-14 06:24:14 +00:00
|
|
|
common.Address address = 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
message RegisterNodeResponse {
|
2021-01-20 07:02:23 +00:00
|
|
|
common.Status status = 1;
|
|
|
|
internal.InitParams init_params = 2;
|
2021-01-14 06:24:14 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
message IndexStatesRequest {
|
2021-01-26 01:38:40 +00:00
|
|
|
repeated int64 indexIDs = 1;
|
2021-01-20 07:02:23 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
message IndexInfo {
|
|
|
|
common.IndexState state = 1;
|
|
|
|
int64 indexID = 2;
|
|
|
|
string Reason = 3;
|
2021-01-14 06:24:14 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
message IndexStatesResponse {
|
|
|
|
common.Status status = 1;
|
2021-01-20 07:02:23 +00:00
|
|
|
repeated IndexInfo states = 2;
|
2021-01-14 06:24:14 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
message BuildIndexRequest {
|
2021-01-21 02:01:29 +00:00
|
|
|
repeated string data_paths = 1;
|
|
|
|
repeated common.KeyValuePair type_params = 2;
|
|
|
|
repeated common.KeyValuePair index_params = 3;
|
2021-01-14 06:24:14 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
message BuildIndexResponse {
|
|
|
|
common.Status status = 1;
|
|
|
|
int64 indexID = 2;
|
|
|
|
}
|
|
|
|
|
2021-01-15 06:38:36 +00:00
|
|
|
message BuildIndexCmd {
|
|
|
|
int64 indexID = 1;
|
|
|
|
BuildIndexRequest req = 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
message BuildIndexNotification {
|
|
|
|
common.Status status = 1;
|
|
|
|
int64 indexID = 2;
|
|
|
|
repeated string index_file_paths = 3;
|
2021-01-26 01:38:40 +00:00
|
|
|
int64 nodeID = 4;
|
2021-01-15 06:38:36 +00:00
|
|
|
}
|
|
|
|
|
2021-01-21 02:01:29 +00:00
|
|
|
message IndexFilePathsRequest {
|
|
|
|
repeated int64 indexIDs = 1;
|
2021-01-14 06:24:14 +00:00
|
|
|
}
|
|
|
|
|
2021-01-21 02:01:29 +00:00
|
|
|
message IndexFilePathInfo {
|
2021-01-14 06:24:14 +00:00
|
|
|
common.Status status = 1;
|
|
|
|
int64 indexID = 2;
|
|
|
|
repeated string index_file_paths = 3;
|
|
|
|
}
|
|
|
|
|
2021-01-21 02:01:29 +00:00
|
|
|
message IndexFilePathsResponse {
|
|
|
|
common.Status status = 1;
|
|
|
|
repeated IndexFilePathInfo file_paths = 2;
|
|
|
|
}
|
|
|
|
|
2021-01-14 06:24:14 +00:00
|
|
|
message IndexMeta {
|
2021-01-18 11:32:08 +00:00
|
|
|
common.IndexState state = 1;
|
2021-01-14 06:24:14 +00:00
|
|
|
int64 indexID = 2;
|
2021-01-26 01:38:40 +00:00
|
|
|
string fail_reason = 3;
|
|
|
|
BuildIndexRequest req = 4;
|
|
|
|
repeated string index_file_paths = 5;
|
2021-01-14 06:24:14 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
/****************IndexService************************/
|
|
|
|
service IndexService {
|
|
|
|
/**
|
|
|
|
* @brief This method is used to create collection
|
|
|
|
*
|
|
|
|
* @param CollectionSchema, use to provide collection information to be created.
|
|
|
|
*
|
|
|
|
* @return Status
|
|
|
|
*/
|
|
|
|
rpc RegisterNode(RegisterNodeRequest) returns (RegisterNodeResponse) {}
|
|
|
|
rpc BuildIndex(BuildIndexRequest) returns (BuildIndexResponse){}
|
|
|
|
rpc GetIndexStates(IndexStatesRequest) returns (IndexStatesResponse) {}
|
2021-01-21 02:01:29 +00:00
|
|
|
rpc GetIndexFilePaths(IndexFilePathsRequest) returns (IndexFilePathsResponse){}
|
2021-01-15 06:38:36 +00:00
|
|
|
rpc NotifyBuildIndex(BuildIndexNotification) returns (common.Status) {}
|
|
|
|
}
|
2021-01-14 06:24:14 +00:00
|
|
|
|
2021-01-15 06:38:36 +00:00
|
|
|
|
|
|
|
service IndexNode {
|
|
|
|
/**
|
|
|
|
* @brief This method is used to create collection
|
|
|
|
*
|
|
|
|
* @param CollectionSchema, use to provide collection information to be created.
|
|
|
|
*
|
|
|
|
* @return Status
|
|
|
|
*/
|
|
|
|
rpc BuildIndex(BuildIndexCmd) returns (common.Status){}
|
|
|
|
|
|
|
|
}
|