Skip to content

Commit

Permalink
Expose tailsamplingprocessor metrics
Browse files Browse the repository at this point in the history
  • Loading branch information
pmm-sumo committed Dec 2, 2020
1 parent 81c33f2 commit dee8e2d
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions processor/tailsamplingprocessor/metrics.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,11 @@ var (
statTracesOnMemoryGauge = stats.Int64("sampling_traces_on_memory", "Tracks the number of traces current on memory", stats.UnitDimensionless)
)

func init() {
// TODO: this is hardcoding the metrics level and skips error handling
_ = view.Register(SamplingProcessorMetricViews(configtelemetry.LevelNormal)...)
}

// SamplingProcessorMetricViews return the metrics views according to given telemetry level.
func SamplingProcessorMetricViews(level configtelemetry.Level) []*view.View {
if level == configtelemetry.LevelNone {
Expand Down

0 comments on commit dee8e2d

Please sign in to comment.