Skip to content

Commit

Permalink
Merge pull request monitoring-tools#4 from monitoring-tools/fix-influ…
Browse files Browse the repository at this point in the history
…xdb-comment

The influx db comments were deleted.
  • Loading branch information
vlamug authored Aug 9, 2017
2 parents d88abcc + e0abd2f commit 463ede5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions common/convert.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ func ConvertValueToFloat64(value interface{}) (float64, error) {
case int64:
resultValue = float64(int64(val))
case uint64:
// InfluxDB does not support writing uint64
// Prometheus does not support writing uint64
if val < uint64(9223372036854775808) {
resultValue = float64(int64(val))
} else {
Expand All @@ -42,7 +42,7 @@ func ConvertValueToFloat64(value interface{}) (float64, error) {
case float32:
resultValue = float64(val)
case float64:
// NaNs are invalid values in influxdb, skip measurement
// NaNs are invalid values in Prometheus, skip measurement
if math.IsNaN(val) || math.IsInf(val, 0) {
return float64(0), errors.New("Unable to convert metric value: value is a Nan or Inf")
}
Expand Down

0 comments on commit 463ede5

Please sign in to comment.