From 62a75b1dfdde38190a4bee365e14e1a6ec669400 Mon Sep 17 00:00:00 2001 From: kpango Date: Thu, 2 Jul 2020 13:42:27 +0900 Subject: [PATCH] fix Signed-off-by: kpango --- pkg/gateway/lb/handler/grpc/visitlist.go | 16 +++++++++++++++- pkg/gateway/lb/usecase/vald.go | 2 +- pkg/gateway/meta/handler/grpc/handler.go | 2 +- 3 files changed, 17 insertions(+), 3 deletions(-) diff --git a/pkg/gateway/lb/handler/grpc/visitlist.go b/pkg/gateway/lb/handler/grpc/visitlist.go index 42d44ecc3c4..ac39d7c5111 100644 --- a/pkg/gateway/lb/handler/grpc/visitlist.go +++ b/pkg/gateway/lb/handler/grpc/visitlist.go @@ -1,4 +1,18 @@ -// Code generated by syncmap; DO NOT EDIT. +// +// Copyright (C) 2019-2020 Vdaas.org Vald team ( kpango, rinx, kmrmt ) +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// https://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +// package grpc diff --git a/pkg/gateway/lb/usecase/vald.go b/pkg/gateway/lb/usecase/vald.go index ee1eb6726d6..2eae492a780 100644 --- a/pkg/gateway/lb/usecase/vald.go +++ b/pkg/gateway/lb/usecase/vald.go @@ -50,7 +50,7 @@ func New(cfg *config.Data) (r runner.Runner, err error) { eg := errgroup.Get() var ( - gateway service.Gateway + gateway service.Gateway ) if addrs := cfg.Gateway.BackupManager.Client.Addrs; len(addrs) == 0 { diff --git a/pkg/gateway/meta/handler/grpc/handler.go b/pkg/gateway/meta/handler/grpc/handler.go index d04ffd2f8d7..5946e6a73d8 100644 --- a/pkg/gateway/meta/handler/grpc/handler.go +++ b/pkg/gateway/meta/handler/grpc/handler.go @@ -340,7 +340,7 @@ func (s *server) MultiUpdate(ctx context.Context, vecs *payload.Object_Vectors) } return nil, status.WrapWithInternal(fmt.Sprintf("MultiUpdate API failed MultiUpdate request %#v", ids), err, info.Get()) } - for i := range vecs.GetVectors(){ + for i := range vecs.GetVectors() { vecs.Vectors[i].Id = metas[i] } res, err = s.MultiUpdate(ctx, vecs)