コード例 #1
0
ファイル: changroup.go プロジェクト: ukd1/lumbermill
func (g *ChanGroup) Sample(ctx slog.Context) {
	ctx.Add("source", g.Name)
	for i := 0; i < numSeries; i++ {
		// TODO: If we set the ChanGroup.Name to be the hostname, this might need to change.
		ctx.Sample(fmt.Sprintf("points.%s.pending", seriesNames[i]), len(g.points[i]))
	}
}