Remove height tag from stats tool

Having a height tags resulted in performance issues due to an increase
in series cardinality.
This commit is contained in:
Travis Person 2019-10-23 23:05:53 -07:00
parent 705637b69f
commit 15742f2359

View File

@ -3,7 +3,6 @@ package main
import ( import (
"context" "context"
"flag" "flag"
"fmt"
"log" "log"
"os" "os"
"time" "time"
@ -94,7 +93,6 @@ func main() {
// Instead of having to pass around a bunch of generic stuff we want for each point // Instead of having to pass around a bunch of generic stuff we want for each point
// we will just add them at the end. // we will just add them at the end.
tsHeight := fmt.Sprintf("%d", tipset.Height())
tsTimestamp := time.Unix(int64(tipset.MinTimestamp()), int64(0)) tsTimestamp := time.Unix(int64(tipset.MinTimestamp()), int64(0))
nb, err := InfluxNewBatch() nb, err := InfluxNewBatch()
@ -103,7 +101,6 @@ func main() {
} }
for _, pt := range pl.Points() { for _, pt := range pl.Points() {
pt.AddTag("height", tsHeight)
pt.SetTime(tsTimestamp) pt.SetTime(tsTimestamp)
nb.AddPoint(NewPointFrom(pt)) nb.AddPoint(NewPointFrom(pt))