adding metadata "dc"

Adding dc to every entry , 
still Todo 
- exposing rmq.drops , rmq.parsed  to _internal measurement with timestamp , server , dc
This commit is contained in:
Sachin Rase 2016-09-04 13:55:36 -07:00 committed by GitHub
parent 2287edce0a
commit 48e102609c
1 changed files with 3 additions and 0 deletions

View File

@ -568,6 +568,9 @@ func structureKey(key string, value interface{}) (string, map[string]string, map
field := fmt.Sprintf("%v.%v.%v.%v", s[1], s[2], sp[3], sp[4])
fields[field] = value
}
//Adding Datacenter as first 4 letter of hostname
tags["dc"] = tag["host"][:4]
// Return the start of a point
return meas, tags, fields
}