From 80f1eb8356abb8d07ecdf6c250da93da033d4f68 Mon Sep 17 00:00:00 2001 From: nameczz Date: Mon, 25 Oct 2021 19:58:18 +0800 Subject: [PATCH] [skip ci] Add IndexDescription comments in milvus.proto (#10246) Signed-off-by: Gitea --- internal/proto/milvus.proto | 12 ++++++++++++ internal/proto/milvuspb/milvus.pb.go | 26 ++++++++++++++++++-------- 2 files changed, 30 insertions(+), 8 deletions(-) diff --git a/internal/proto/milvus.proto b/internal/proto/milvus.proto index 15e022b51f..74430b8949 100644 --- a/internal/proto/milvus.proto +++ b/internal/proto/milvus.proto @@ -444,15 +444,27 @@ message DescribeIndexRequest { string index_name = 5; } +/* +* Index informations +*/ message IndexDescription { + // Index name string index_name = 1; + // Index id int64 indexID = 2; + // Will return index_type, metric_type, params(like nlist). repeated common.KeyValuePair params = 3; + // The vector field name string field_name = 4; } +/* +* Describe index response +*/ message DescribeIndexResponse { + // Response status common.Status status = 1; + // All index informations, for now only return tha latest index you created for the collection. repeated IndexDescription index_descriptions = 2; } diff --git a/internal/proto/milvuspb/milvus.pb.go b/internal/proto/milvuspb/milvus.pb.go index b61bd29d93..82067f1202 100644 --- a/internal/proto/milvuspb/milvus.pb.go +++ b/internal/proto/milvuspb/milvus.pb.go @@ -2178,14 +2178,20 @@ func (m *DescribeIndexRequest) GetIndexName() string { return "" } +// +// Index informations type IndexDescription struct { - IndexName string `protobuf:"bytes,1,opt,name=index_name,json=indexName,proto3" json:"index_name,omitempty"` - IndexID int64 `protobuf:"varint,2,opt,name=indexID,proto3" json:"indexID,omitempty"` - Params []*commonpb.KeyValuePair `protobuf:"bytes,3,rep,name=params,proto3" json:"params,omitempty"` - FieldName string `protobuf:"bytes,4,opt,name=field_name,json=fieldName,proto3" json:"field_name,omitempty"` - XXX_NoUnkeyedLiteral struct{} `json:"-"` - XXX_unrecognized []byte `json:"-"` - XXX_sizecache int32 `json:"-"` + // Index name + IndexName string `protobuf:"bytes,1,opt,name=index_name,json=indexName,proto3" json:"index_name,omitempty"` + // Index id + IndexID int64 `protobuf:"varint,2,opt,name=indexID,proto3" json:"indexID,omitempty"` + // Will return index_type, metric_type, params(like nlist). + Params []*commonpb.KeyValuePair `protobuf:"bytes,3,rep,name=params,proto3" json:"params,omitempty"` + // The vector field name + FieldName string `protobuf:"bytes,4,opt,name=field_name,json=fieldName,proto3" json:"field_name,omitempty"` + XXX_NoUnkeyedLiteral struct{} `json:"-"` + XXX_unrecognized []byte `json:"-"` + XXX_sizecache int32 `json:"-"` } func (m *IndexDescription) Reset() { *m = IndexDescription{} } @@ -2241,8 +2247,12 @@ func (m *IndexDescription) GetFieldName() string { return "" } +// +// Describe index response type DescribeIndexResponse struct { - Status *commonpb.Status `protobuf:"bytes,1,opt,name=status,proto3" json:"status,omitempty"` + // Response status + Status *commonpb.Status `protobuf:"bytes,1,opt,name=status,proto3" json:"status,omitempty"` + // All index informations, for now only return tha latest index you created for the collection. IndexDescriptions []*IndexDescription `protobuf:"bytes,2,rep,name=index_descriptions,json=indexDescriptions,proto3" json:"index_descriptions,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"`