fix for latest micro
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
8
http.go
8
http.go
@@ -10,10 +10,10 @@ import (
|
||||
"sync"
|
||||
"time"
|
||||
|
||||
jsonrpc "github.com/unistack-org/micro-codec-jsonrpc"
|
||||
protorpc "github.com/unistack-org/micro-codec-protorpc"
|
||||
"github.com/unistack-org/micro/v3/broker"
|
||||
"github.com/unistack-org/micro/v3/codec"
|
||||
jsonrpc "github.com/unistack-org/micro/v3/codec/jsonrpc"
|
||||
protorpc "github.com/unistack-org/micro/v3/codec/protorpc"
|
||||
"github.com/unistack-org/micro/v3/logger"
|
||||
"github.com/unistack-org/micro/v3/registry"
|
||||
"github.com/unistack-org/micro/v3/server"
|
||||
@@ -167,7 +167,7 @@ func (h *httpServer) Register() error {
|
||||
logger.Infof("Registering node: %s", opts.Name+"-"+opts.Id)
|
||||
})
|
||||
|
||||
if err := opts.Registry.Register(service, rOpts...); err != nil {
|
||||
if err := opts.Registry.Register(h.opts.Context, service, rOpts...); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
@@ -217,7 +217,7 @@ func (h *httpServer) Deregister() error {
|
||||
return err
|
||||
}
|
||||
|
||||
if err := opts.Registry.Deregister(service); err != nil {
|
||||
if err := opts.Registry.Deregister(h.opts.Context, service); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user