istio-gateway: Add debug logging when endpoints missing

This commit is contained in:
Matthew Warman 2022-01-24 12:26:39 +00:00
parent e21f2c4387
commit b79dc1e894

View File

@ -172,6 +172,11 @@ func (sc *gatewaySource) Endpoints(ctx context.Context) ([]*endpoint.Endpoint, e
return nil, err
}
if len(gwEndpoints) == 0 {
log.Debugf("No endpoints could be generated from gateway %s/%s", gateway.Namespace, gateway.Name)
continue
}
log.Debugf("Endpoints generated from gateway: %s/%s: %v", gateway.Namespace, gateway.Name, gwEndpoints)
sc.setResourceLabel(gateway, gwEndpoints)
endpoints = append(endpoints, gwEndpoints...)