Rename ID -> Name

This commit is contained in:
Clayton Coleman
2014-10-22 13:02:02 -04:00
parent bdebff5b28
commit bb77a5d15f
107 changed files with 777 additions and 777 deletions

View File

@@ -73,10 +73,10 @@ func (kl *Kubelet) runOnce(pods []api.BoundPod) (results []RunPodResult, err err
results = append(results, res)
if res.Err != nil {
// TODO(proppy): report which containers failed the pod.
glog.Infof("failed to start pod %q: %v", res.Pod.ID, res.Err)
failedPods = append(failedPods, res.Pod.ID)
glog.Infof("failed to start pod %q: %v", res.Pod.Name, res.Err)
failedPods = append(failedPods, res.Pod.Name)
} else {
glog.Infof("started pod %q", res.Pod.ID)
glog.Infof("started pod %q", res.Pod.Name)
}
}
if len(failedPods) > 0 {
@@ -100,18 +100,18 @@ func (kl *Kubelet) runPod(pod api.BoundPod) error {
return fmt.Errorf("failed to check pod status: %v", err)
}
if running {
glog.Infof("pod %q containers running", pod.ID)
glog.Infof("pod %q containers running", pod.Name)
return nil
}
glog.Infof("pod %q containers not running: syncing", pod.ID)
glog.Infof("pod %q containers not running: syncing", pod.Name)
if err = kl.syncPod(&pod, dockerContainers); err != nil {
return fmt.Errorf("error syncing pod: %v", err)
}
if retry >= RunOnceMaxRetries {
return fmt.Errorf("timeout error: pod %q containers not running after %d retries", pod.ID, RunOnceMaxRetries)
return fmt.Errorf("timeout error: pod %q containers not running after %d retries", pod.Name, RunOnceMaxRetries)
}
// TODO(proppy): health checking would be better than waiting + checking the state at the next iteration.
glog.Infof("pod %q containers synced, waiting for %v", pod.ID, delay)
glog.Infof("pod %q containers synced, waiting for %v", pod.Name, delay)
<-time.After(delay)
retry++
delay *= RunOnceRetryDelayBackoff