0.3.0: leofs & lustre2

This commit is contained in:
Cameron Sparr
2015-12-14 17:11:54 -06:00
parent 319c363c8e
commit 9fce094b36
2 changed files with 10 additions and 7 deletions

View File

@@ -197,6 +197,8 @@ func (l *LeoFS) gatherServer(endpoint string, serverType ServerType, acc plugins
"node": nodeNameTrimmed,
}
i := 0
fields := make(map[string]interface{})
for scanner.Scan() {
key := KeyMapping[serverType][i]
val, err := retrieveTokenAfterColon(scanner.Text())
@@ -207,9 +209,10 @@ func (l *LeoFS) gatherServer(endpoint string, serverType ServerType, acc plugins
if err != nil {
return fmt.Errorf("Unable to parse the value:%s, err:%s", val, err)
}
acc.Add(key, fVal, tags)
fields[key] = fVal
i++
}
acc.AddFields("leofs", fields, tags)
return nil
}