mirror of https://github.com/milvus-io/milvus.git
[skip ci] Add comment for grpcclient.ClientBase (#12966)
Signed-off-by: shaoyue.chen <shaoyue.chen@zilliz.com>pull/12975/head
parent
5045ba208e
commit
8f2c630434
|
@ -33,6 +33,7 @@ type GrpcClient interface {
|
|||
Close() error
|
||||
}
|
||||
|
||||
// ClientBase is a base of grpc client
|
||||
type ClientBase struct {
|
||||
getAddrFunc func() (string, error)
|
||||
newGrpcClient func(cc *grpc.ClientConn) interface{}
|
||||
|
@ -45,10 +46,12 @@ type ClientBase struct {
|
|||
ClientMaxRecvSize int
|
||||
}
|
||||
|
||||
// SetRole sets role of client
|
||||
func (c *ClientBase) SetRole(role string) {
|
||||
c.role = role
|
||||
}
|
||||
|
||||
// GetRole returns role of client
|
||||
func (c *ClientBase) GetRole() string {
|
||||
return c.role
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue