Merge pull request #270 from prometheus/beorn7/fixes

graphite: Adjust ExtractSamples call to new interface
This commit is contained in:
Björn Rabenstein 2017-01-09 00:28:57 +01:00 committed by GitHub
commit 74f9ce27f6
1 changed files with 4 additions and 1 deletions

View File

@ -182,9 +182,12 @@ func (b *Bridge) Push() error {
}
func writeMetrics(w io.Writer, mfs []*dto.MetricFamily, prefix string, now model.Time) error {
vec := expfmt.ExtractSamples(&expfmt.DecodeOptions{
vec, err := expfmt.ExtractSamples(&expfmt.DecodeOptions{
Timestamp: now,
}, mfs...)
if err != nil {
return err
}
buf := bufio.NewWriter(w)
for _, s := range vec {