Clean up error logs.

Use %v for errors, tidy some messages, make error messages start lowe-case
(as per go guidelines).  Just accumulated nits.
This commit is contained in:
Tim Hockin
2014-11-20 18:00:36 +08:00
parent c688bd402f
commit ea960711ff
53 changed files with 163 additions and 163 deletions

View File

@@ -378,7 +378,7 @@ func checkEtcd(host string) error {
return err
}
if !strings.HasPrefix("etcd", string(body)) {
return fmt.Errorf("Unknown server: %s", string(body))
return fmt.Errorf("unknown server: %s", string(body))
}
return nil
}

View File

@@ -167,7 +167,7 @@ func etcdGetInitialWatchState(client EtcdGetSet, key string, recursive bool, inc
resp, err := client.Get(key, false, recursive)
if err != nil {
if !IsEtcdNotFound(err) {
glog.Errorf("watch was unable to retrieve the current index for the provided key: %v (%#v)", err, key)
glog.Errorf("watch was unable to retrieve the current index for the provided key (%q): %v", key, err)
return resourceVersion, err
}
if index, ok := etcdErrorIndex(err); ok {