improve HasCollectionRequest and DropCollectionRequest comments (#7693)

Signed-off-by: Gitea <zizhao.chen@zilliz.com>
This commit is contained in:
nameczz 2021-09-14 09:53:21 +08:00 committed by GitHub
parent c33416f46a
commit 87460665e0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 41 additions and 17 deletions

View File

@ -65,16 +65,29 @@ message CreateCollectionRequest {
int32 shards_num = 5; int32 shards_num = 5;
} }
/**
* Drop collection in milvus, also will drop data in collection.
*/
message DropCollectionRequest { message DropCollectionRequest {
common.MsgBase base = 1; // must // Not useful for now
common.MsgBase base = 1;
// Not useful for now
string db_name = 2; string db_name = 2;
string collection_name = 3; // must // The unique collection name in milvus.(Required)
string collection_name = 3;
} }
/**
* Check collection exist in milvus or not.
*/
message HasCollectionRequest { message HasCollectionRequest {
common.MsgBase base = 1; // must // Not useful for now
common.MsgBase base = 1;
// Not useful for now
string db_name = 2; string db_name = 2;
string collection_name = 3; // must // The collection name you want to check.
string collection_name = 3;
// Not useful for now
uint64 time_stamp = 4; uint64 time_stamp = 4;
} }

View File

@ -157,9 +157,14 @@ func (m *CreateCollectionRequest) GetShardsNum() int32 {
return 0 return 0
} }
//*
// Drop collection in milvus, also will drop data in collection.
type DropCollectionRequest struct { type DropCollectionRequest struct {
// Not useful for now
Base *commonpb.MsgBase `protobuf:"bytes,1,opt,name=base,proto3" json:"base,omitempty"` Base *commonpb.MsgBase `protobuf:"bytes,1,opt,name=base,proto3" json:"base,omitempty"`
// Not useful for now
DbName string `protobuf:"bytes,2,opt,name=db_name,json=dbName,proto3" json:"db_name,omitempty"` DbName string `protobuf:"bytes,2,opt,name=db_name,json=dbName,proto3" json:"db_name,omitempty"`
// The unique collection name in milvus.(Required)
CollectionName string `protobuf:"bytes,3,opt,name=collection_name,json=collectionName,proto3" json:"collection_name,omitempty"` CollectionName string `protobuf:"bytes,3,opt,name=collection_name,json=collectionName,proto3" json:"collection_name,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"` XXX_unrecognized []byte `json:"-"`
@ -212,10 +217,16 @@ func (m *DropCollectionRequest) GetCollectionName() string {
return "" return ""
} }
//*
// Check collection exist in milvus or not.
type HasCollectionRequest struct { type HasCollectionRequest struct {
// Not useful for now
Base *commonpb.MsgBase `protobuf:"bytes,1,opt,name=base,proto3" json:"base,omitempty"` Base *commonpb.MsgBase `protobuf:"bytes,1,opt,name=base,proto3" json:"base,omitempty"`
// Not useful for now
DbName string `protobuf:"bytes,2,opt,name=db_name,json=dbName,proto3" json:"db_name,omitempty"` DbName string `protobuf:"bytes,2,opt,name=db_name,json=dbName,proto3" json:"db_name,omitempty"`
// The collection name you want to check.
CollectionName string `protobuf:"bytes,3,opt,name=collection_name,json=collectionName,proto3" json:"collection_name,omitempty"` CollectionName string `protobuf:"bytes,3,opt,name=collection_name,json=collectionName,proto3" json:"collection_name,omitempty"`
// Not useful for now
TimeStamp uint64 `protobuf:"varint,4,opt,name=time_stamp,json=timeStamp,proto3" json:"time_stamp,omitempty"` TimeStamp uint64 `protobuf:"varint,4,opt,name=time_stamp,json=timeStamp,proto3" json:"time_stamp,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"` XXX_unrecognized []byte `json:"-"`