diff --git a/pkg/agent/core/ngt/handler/grpc/index.go b/pkg/agent/core/ngt/handler/grpc/index.go index 97380baa496..6be641e5015 100644 --- a/pkg/agent/core/ngt/handler/grpc/index.go +++ b/pkg/agent/core/ngt/handler/grpc/index.go @@ -50,8 +50,8 @@ func (s *server) CreateIndex(ctx context.Context, c *payload.Control_CreateIndex &errdetails.PreconditionFailure{ Violations: []*errdetails.PreconditionFailureViolation{ { - Type: "uncommited index is empty", - Subject: "failed to CreateIndex operation caused by empty uncommited indices", + Type: "uncommitted index is empty", + Subject: "failed to CreateIndex operation caused by empty uncommitted indices", }, }, }, info.Get()) @@ -125,8 +125,8 @@ func (s *server) CreateAndSaveIndex(ctx context.Context, c *payload.Control_Crea &errdetails.PreconditionFailure{ Violations: []*errdetails.PreconditionFailureViolation{ { - Type: "uncommited index is empty", - Subject: "failed to CreateAndSaveIndex operation caused by empty uncommited indices", + Type: "uncommitted index is empty", + Subject: "failed to CreateAndSaveIndex operation caused by empty uncommitted indices", }, }, }, info.Get()) @@ -153,7 +153,7 @@ func (s *server) CreateAndSaveIndex(ctx context.Context, c *payload.Control_Crea } func (s *server) IndexInfo(ctx context.Context, _ *payload.Empty) (res *payload.Info_Index_Count, err error) { - ctx, span := trace.StartSpan(ctx, apiName+".IndexInfo") + _, span := trace.StartSpan(ctx, apiName+".IndexInfo") defer func() { if span != nil { span.End() diff --git a/pkg/agent/core/ngt/handler/grpc/remove.go b/pkg/agent/core/ngt/handler/grpc/remove.go index cc25e096a75..a1209830f4f 100644 --- a/pkg/agent/core/ngt/handler/grpc/remove.go +++ b/pkg/agent/core/ngt/handler/grpc/remove.go @@ -33,7 +33,7 @@ import ( ) func (s *server) Remove(ctx context.Context, req *payload.Remove_Request) (res *payload.Object_Location, err error) { - ctx, span := trace.StartSpan(ctx, apiName+".Remove") + _, span := trace.StartSpan(ctx, apiName+".Remove") defer func() { if span != nil { span.End() @@ -169,7 +169,7 @@ func (s *server) StreamRemove(stream vald.Remove_StreamRemoveServer) (err error) } func (s *server) MultiRemove(ctx context.Context, reqs *payload.Remove_MultiRequest) (res *payload.Object_Locations, err error) { - ctx, span := trace.StartSpan(ctx, apiName+".MultiRemove") + _, span := trace.StartSpan(ctx, apiName+".MultiRemove") defer func() { if span != nil { span.End() diff --git a/pkg/agent/core/ngt/handler/grpc/update_test.go b/pkg/agent/core/ngt/handler/grpc/update_test.go index 6387b386842..5d3c27a2f08 100644 --- a/pkg/agent/core/ngt/handler/grpc/update_test.go +++ b/pkg/agent/core/ngt/handler/grpc/update_test.go @@ -157,7 +157,7 @@ func Test_server_Update(t *testing.T) { - case 6.2: success update with one min value vector (type: float32) - case 7.1: success update with one max value vector (type: uint8) - case 7.2: success update with one max value vector (type: float32) - - case 8.1: success update with one NaN value vector (type: float32) // NOTE: To fix it, it is necessarry to check all of vector value + - case 8.1: success update with one NaN value vector (type: float32) // NOTE: To fix it, it is necessary to check all of vector value - case 9.1: success update with one +inf value vector (type: float32) - case 9.2: success update with one -inf value vector (type: float32) - case 10.1: fail update with one nil vector