opencensus-go icon indicating copy to clipboard operation
opencensus-go copied to clipboard

Meter#Register hangs indefinitely if meter not started

Open nicks opened this issue 5 years ago • 0 comments

Please answer these questions before submitting a bug report.

What version of OpenCensus are you using?

go.opencensus.io v0.22.4

What version of Go are you using?

go version go1.14.3 linux/amd64

What did you do?

If possible, provide a recipe for reproducing the error.

package main

import (
	"go.opencensus.io/stats/view"
)

func main() {
	meter := view.NewMeter()
	_ = meter.Register()
}

What did you expect to see?

The Register() call to return

What did you see instead?

The meter.Register call hangs forever waiting on the go channel.

I didn't find anything in the documentation that suggested I needed to call Start() before doing any Register calls

Additional context

Add any other context about the problem here.

nicks avatar Sep 02 '20 18:09 nicks