diff --git a/consul/discovery.go b/consul/discovery.go index cde42da..42e4dcb 100644 --- a/consul/discovery.go +++ b/consul/discovery.go @@ -9,7 +9,6 @@ import ( "git.pbiernat.dev/egommerce/go-api-pkg/config" consul "github.com/hashicorp/consul/api" "github.com/hashicorp/consul/connect" - "github.com/hashicorp/go-hclog" ) type Service struct { @@ -73,9 +72,7 @@ func (s *Service) Register() error { Address: s.Address, Port: s.port, Tags: s.getTags(), - Connect: &consul.AgentServiceConnect{ - Native: true, - }, + // Connect: &consul.AgentServiceConnect{Native: true}, // Proxy: &consul.AgentServiceConnectProxyConfig{ // DestinationServiceName: s.Name, // }, @@ -118,11 +115,11 @@ func (s *Service) RegisterHealthChecks() { } func (s *Service) Connect() (*connect.Service, error) { - l := hclog.New(&hclog.LoggerOptions{ - Name: "consul-registry", - Level: hclog.Trace, - }) - svc, err := connect.NewServiceWithLogger(s.Name, s.client, l) + // l := hclog.New(&hclog.LoggerOptions{ + // Name: "consul-registry", + // Level: hclog.Trace, + // }) + svc, err := connect.NewService(s.Name, s.client) s.connect = svc cnf := svc.ServerTLSConfig() fmt.Printf("CONNECT SERVER:: %s CONFIG:: %v\n", s.Name, cnf)