procstat: Add user, pidfile, pattern & exe tags

closes #1035
This commit is contained in:
Cameron Sparr
2016-04-20 13:18:07 -06:00
parent 4bcf157d88
commit f1b7ecb2a2
4 changed files with 40 additions and 18 deletions

View File

@@ -36,9 +36,8 @@ func NewSpecProcessor(
prefix string,
acc telegraf.Accumulator,
p *process.Process,
tags map[string]string,
) *SpecProcessor {
tags := make(map[string]string)
tags["pid"] = fmt.Sprintf("%v", p.Pid)
if name, err := p.Name(); err == nil {
tags["process_name"] = name
}