resolver/discovery: fix endpoint, scheme don't match grpc (#831)

pull/835/head
miya 4 years ago committed by GitHub
parent 0921f0156e
commit c673439d96
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 3
      transport/grpc/resolver/discovery/resolver.go

@ -46,6 +46,9 @@ func (r *discoveryResolver) update(ins []*registry.ServiceInstance) {
r.log.Errorf("Failed to parse discovery endpoint: %v", err) r.log.Errorf("Failed to parse discovery endpoint: %v", err)
continue continue
} }
if endpoint == "" {
continue
}
addr := resolver.Address{ addr := resolver.Address{
ServerName: in.Name, ServerName: in.Name,
Attributes: parseAttributes(in.Metadata), Attributes: parseAttributes(in.Metadata),

Loading…
Cancel
Save