mirror of https://github.com/k3s-io/k3s
Better logs in service controller
parent
2052e334b6
commit
78322091f0
|
@ -352,18 +352,20 @@ func (s *ServiceController) persistUpdate(service *api.Service) error {
|
|||
// out so that we can process the delete, which we should soon be receiving
|
||||
// if we haven't already.
|
||||
if errors.IsNotFound(err) {
|
||||
glog.Infof("Not persisting update to service that no longer exists: %v", err)
|
||||
glog.Infof("Not persisting update to service '%s/%s' that no longer exists: %v",
|
||||
service.Namespace, service.Name, err)
|
||||
return nil
|
||||
}
|
||||
// TODO: Try to resolve the conflict if the change was unrelated to load
|
||||
// balancer status. For now, just rely on the fact that we'll
|
||||
// also process the update that caused the resource version to change.
|
||||
if errors.IsConflict(err) {
|
||||
glog.V(4).Infof("Not persisting update to service that has been changed since we received it: %v", err)
|
||||
glog.V(4).Infof("Not persisting update to service '%s/%s' that has been changed since we received it: %v",
|
||||
service.Namespace, service.Name, err)
|
||||
return nil
|
||||
}
|
||||
glog.Warningf("Failed to persist updated LoadBalancerStatus to service %s after creating its load balancer: %v",
|
||||
service.Name, err)
|
||||
glog.Warningf("Failed to persist updated LoadBalancerStatus to service '%s/%s' after creating its load balancer: %v",
|
||||
service.Namespace, service.Name, err)
|
||||
time.Sleep(clientRetryInterval)
|
||||
}
|
||||
return err
|
||||
|
|
Loading…
Reference in New Issue