Log failure to send NaN values to remote store as Debug (#3235)

This was a warning and can be a frequent occurrence.  Let's not fill up
logs unless we are asked to.
This commit is contained in:
Jack Neely 2017-10-06 06:22:55 -04:00 committed by Brian Brazil
parent a03193232a
commit 128b31d058
2 changed files with 2 additions and 2 deletions

View file

@ -86,7 +86,7 @@ func (c *Client) Write(samples model.Samples) error {
t := float64(s.Timestamp.UnixNano()) / 1e9
v := float64(s.Value)
if math.IsNaN(v) || math.IsInf(v, 0) {
log.Warnf("cannot send value %f to Graphite,"+
log.Debugf("cannot send value %f to Graphite,"+
"skipping sample %#v", v, s)
continue
}

View file

@ -75,7 +75,7 @@ func (c *Client) Write(samples model.Samples) error {
for _, s := range samples {
v := float64(s.Value)
if math.IsNaN(v) || math.IsInf(v, 0) {
log.Warnf("cannot send value %f to OpenTSDB, skipping sample %#v", v, s)
log.Debugf("cannot send value %f to OpenTSDB, skipping sample %#v", v, s)
continue
}
metric := TagValue(s.Metric[model.MetricNameLabel])