Enforce stat prefixing at the accumulator layer

This commit is contained in:
Evan Phoenix
2015-05-18 12:15:15 -07:00
parent 34e87e7026
commit f1e1204374
10 changed files with 439 additions and 314 deletions

View File

@@ -12,9 +12,13 @@ type BatchPoints struct {
client.BatchPoints
Debug bool
Prefix string
}
func (bp *BatchPoints) Add(name string, val interface{}, tags map[string]string) {
name = bp.Prefix + name
if bp.Debug {
var tg []string