update to micro v3.1.2

Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
Василий Толстов 2021-01-19 03:18:11 +03:00
parent 3d3c5557c6
commit 0d3e8255ba
3 changed files with 5 additions and 4 deletions

2
go.mod
View File

@ -5,7 +5,7 @@ go 1.14
require ( require (
github.com/golang/protobuf v1.4.3 github.com/golang/protobuf v1.4.3
github.com/imdario/mergo v0.3.11 github.com/imdario/mergo v0.3.11
github.com/unistack-org/micro/v3 v3.1.1 github.com/unistack-org/micro/v3 v3.1.2
google.golang.org/genproto v0.0.0-20200904004341-0bd0a958aa1d // indirect google.golang.org/genproto v0.0.0-20200904004341-0bd0a958aa1d // indirect
google.golang.org/grpc v1.27.0 google.golang.org/grpc v1.27.0
google.golang.org/protobuf v1.25.0 google.golang.org/protobuf v1.25.0

4
go.sum
View File

@ -228,8 +228,8 @@ github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5
github.com/timewasted/linode v0.0.0-20160829202747-37e84520dcf7/go.mod h1:imsgLplxEC/etjIhdr3dNzV3JeT27LbVu5pYWm0JCBY= github.com/timewasted/linode v0.0.0-20160829202747-37e84520dcf7/go.mod h1:imsgLplxEC/etjIhdr3dNzV3JeT27LbVu5pYWm0JCBY=
github.com/transip/gotransip v0.0.0-20190812104329-6d8d9179b66f/go.mod h1:i0f4R4o2HM0m3DZYQWsj6/MEowD57VzoH0v3d7igeFY= github.com/transip/gotransip v0.0.0-20190812104329-6d8d9179b66f/go.mod h1:i0f4R4o2HM0m3DZYQWsj6/MEowD57VzoH0v3d7igeFY=
github.com/uber-go/atomic v1.3.2/go.mod h1:/Ct5t2lcmbJ4OSe/waGBoaVvVqtO0bmtfVNex1PFV8g= github.com/uber-go/atomic v1.3.2/go.mod h1:/Ct5t2lcmbJ4OSe/waGBoaVvVqtO0bmtfVNex1PFV8g=
github.com/unistack-org/micro/v3 v3.1.1 h1:kWL0BVzUBdotjfDbl1qL9lNYmZqvebQWPNCyqrjUSAk= github.com/unistack-org/micro/v3 v3.1.2 h1:NZnO6uhdRmoW/IhbWT1HWRCNWwgKbLlX4XikNx1cMzI=
github.com/unistack-org/micro/v3 v3.1.1/go.mod h1:0DgOy4OdJxQCDER8YSKitZugd2+1bddrRSNfeooTHDc= github.com/unistack-org/micro/v3 v3.1.2/go.mod h1:0DgOy4OdJxQCDER8YSKitZugd2+1bddrRSNfeooTHDc=
github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0=
github.com/vultr/govultr v0.1.4/go.mod h1:9H008Uxr/C4vFNGLqKx232C206GL0PBHzOP0809bGNA= github.com/vultr/govultr v0.1.4/go.mod h1:9H008Uxr/C4vFNGLqKx232C206GL0PBHzOP0809bGNA=
github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU=

View File

@ -7,6 +7,7 @@ import (
"github.com/imdario/mergo" "github.com/imdario/mergo"
pb "github.com/unistack-org/micro-config-service/v3/proto" pb "github.com/unistack-org/micro-config-service/v3/proto"
"github.com/unistack-org/micro/v3/config" "github.com/unistack-org/micro/v3/config"
rutil "github.com/unistack-org/micro/v3/util/reflect"
) )
var ( var (
@ -53,7 +54,7 @@ func (c *serviceConfig) Load(ctx context.Context) error {
return fmt.Errorf("failed to load error config: %w", err) return fmt.Errorf("failed to load error config: %w", err)
} }
src, err := config.Zero(c.opts.Struct) src, err := rutil.Zero(c.opts.Struct)
if err == nil { if err == nil {
err = c.opts.Codec.Unmarshal(rsp.Config, src) err = c.opts.Codec.Unmarshal(rsp.Config, src)
if err == nil { if err == nil {