fix(gather): add bkt and org id to scraper writer

pull/13664/head
Kelvin Wang 2019-04-26 12:49:45 -04:00
parent 9a8426c3f0
commit d7cb7d5ffa
1 changed files with 6 additions and 0 deletions

View File

@ -6,6 +6,7 @@ import (
"github.com/influxdata/influxdb/nats"
"github.com/influxdata/influxdb/storage"
"github.com/influxdata/influxdb/tsdb"
"go.uber.org/zap"
)
@ -20,6 +21,11 @@ func (s PointWriter) Record(collected MetricsCollection) error {
if err != nil {
return err
}
ps, err = tsdb.ExplodePoints(collected.OrgID, collected.BucketID, ps)
if err != nil {
return err
}
return s.Writer.WritePoints(context.TODO(), ps)
}