mirror of https://github.com/milvus-io/milvus.git
Establish a grpc connection When init queryNode client (#12236)
Signed-off-by: xige-16 <xi.ge@zilliz.com>pull/12202/head
parent
59d19384dc
commit
1a8e2e5e85
|
@ -110,7 +110,8 @@ func NewClient(ctx context.Context, addr string) (*Client, error) {
|
|||
// Init initializes QueryNode's grpc client.
|
||||
func (c *Client) Init() error {
|
||||
Params.Init()
|
||||
return nil
|
||||
_, err := c.getGrpcClient()
|
||||
return err
|
||||
}
|
||||
|
||||
func (c *Client) connect(retryOptions ...retry.Option) error {
|
||||
|
|
|
@ -97,8 +97,7 @@ func Test_NewClient(t *testing.T) {
|
|||
assert.Nil(t, err)
|
||||
assert.NotNil(t, client)
|
||||
|
||||
err = client.Init()
|
||||
assert.Nil(t, err)
|
||||
Params.Init()
|
||||
|
||||
err = client.Start()
|
||||
assert.Nil(t, err)
|
||||
|
|
Loading…
Reference in New Issue