From 17dcbac9ce1ef17e3aabd27736a0be09a6428b78 Mon Sep 17 00:00:00 2001 From: Sangbum Kim Date: Tue, 10 Jul 2018 02:19:58 +0900 Subject: [PATCH] add uint64 support --- consumer/influx_stat.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/consumer/influx_stat.go b/consumer/influx_stat.go index e7b2af8..d736327 100644 --- a/consumer/influx_stat.go +++ b/consumer/influx_stat.go @@ -7,11 +7,15 @@ import ( "amuz.es/src/infra/cpu_ctrl/producer" "github.com/influxdata/influxdb/client/v2" zlog "amuz.es/src/infra/goutils/logger/zap" + influxmodels "github.com/influxdata/influxdb/models" "go.uber.org/zap" "unsafe" "sync/atomic" ) +func init(){ + influxmodels.EnableUintSupport() +} type processorData struct { Tempeture float64 FanSpeed int @@ -142,7 +146,6 @@ func (m *influxMetric) sendPoint( if err := influxDbConn.Write(batchPoint); err != nil { m.logger.Warn(err) } - } func (m *influxMetric) getOsMetric(points *[]*client.Point, info *producer.OSMetricInfo) {