diff --git a/database/graphite/database.go b/database/graphite/database.go index a0bf9b4..bab9c06 100644 --- a/database/graphite/database.go +++ b/database/graphite/database.go @@ -9,10 +9,11 @@ import ( ) const ( - MeasurementNode = "node" // Measurement for per-node statistics - MeasurementGlobal = "global" // Measurement for summarized global statistics - CounterMeasurementFirmware = "firmware" // Measurement for firmware statistics - CounterMeasurementModel = "model" // Measurement for model statistics + MeasurementNode = "node" // Measurement for per-node statistics + MeasurementGlobal = "global" // Measurement for summarized global statistics + CounterMeasurementFirmware = "firmware" // Measurement for firmware statistics + CounterMeasurementModel = "model" // Measurement for model statistics + CounterMeasurementAutoupdater = "autoupdater" // Measurement for autoupdater ) type Connection struct { diff --git a/database/graphite/global.go b/database/graphite/global.go index 2c2bedb..acdd056 100644 --- a/database/graphite/global.go +++ b/database/graphite/global.go @@ -11,16 +11,19 @@ func (c *Connection) InsertGlobals(stats *runtime.GlobalStats, time time.Time, s measurementGlobal := MeasurementGlobal counterMeasurementModel := CounterMeasurementModel counterMeasurementFirmware := CounterMeasurementFirmware + counterMeasurementAutoupdater := CounterMeasurementAutoupdater if site != runtime.GLOBAL_SITE { measurementGlobal += "_" + site counterMeasurementModel += "_" + site counterMeasurementFirmware += "_" + site + counterMeasurementAutoupdater += "_" + site } c.addPoint(GlobalStatsFields(measurementGlobal, stats)) c.addCounterMap(counterMeasurementModel, stats.Models, time) c.addCounterMap(counterMeasurementFirmware, stats.Firmwares, time) + c.addCounterMap(counterMeasurementAutoupdater, stats.Autoupdater, time) } func GlobalStatsFields(name string, stats *runtime.GlobalStats) []graphigo.Metric {