2015-05-23 07:45:14 +08:00
|
|
|
package telegraf
|
2015-04-07 00:32:10 +08:00
|
|
|
|
2016-01-28 05:21:36 +08:00
|
|
|
import "time"
|
2015-04-07 00:32:10 +08:00
|
|
|
|
2015-10-17 06:13:32 +08:00
|
|
|
type Accumulator interface {
|
2016-01-28 05:21:36 +08:00
|
|
|
// Create a point with a value, decorating it with tags
|
|
|
|
|
// NOTE: tags is expected to be owned by the caller, don't mutate
|
|
|
|
|
// it after passing to Add.
|
|
|
|
|
Add(measurement string,
|
|
|
|
|
value interface{},
|
|
|
|
|
tags map[string]string,
|
|
|
|
|
t ...time.Time)
|
|
|
|
|
|
|
|
|
|
AddFields(measurement string,
|
|
|
|
|
fields map[string]interface{},
|
|
|
|
|
tags map[string]string,
|
|
|
|
|
t ...time.Time)
|
2015-05-20 13:19:32 +08:00
|
|
|
|
2015-10-17 06:13:32 +08:00
|
|
|
Debug() bool
|
|
|
|
|
SetDebug(enabled bool)
|
2015-04-07 00:32:10 +08:00
|
|
|
}
|