kube-dns logging cleanup

--v=2 is low noise (record changes), can be default
--v=3 will shows per request logging

Note: due to the code path with which we integrate with
skydns, we don't see non-PILLAR_DOMAIN requests, so these
will never be logged.
This commit is contained in:
Bowei Du
2016-11-01 14:52:26 -07:00
parent 65e421b1d7
commit d9557d4eaf
8 changed files with 133 additions and 78 deletions

View File

@@ -63,7 +63,8 @@ func ReverseArray(arr []string) []string {
func GetSkyMsg(ip string, port int) (*msg.Service, string) {
msg := NewServiceRecord(ip, port)
hash := HashServiceRecord(msg)
glog.V(2).Infof("DNS Record:%s, hash:%s", fmt.Sprintf("%v", msg), hash)
glog.V(5).Infof("Constructed new DNS record: %s, hash:%s",
fmt.Sprintf("%v", msg), hash)
return msg, fmt.Sprintf("%x", hash)
}