-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
integrate with OpenCensus and Ocagent exporter #2
base: master
Are you sure you want to change the base?
Conversation
@reyang do you think that you could possibly update this with the proper changes to vendor/Gopkg.toml/Gopkg.lock? One of our goals is to have a repeatable demo people can use later, your PR doesn't introduce the needed bits to update vendor. |
@@ -73,7 +100,7 @@ func main() { | |||
http.Handle("/metrics", promhttp.Handler()) | |||
http.Handle("/", instrumentHandler(throttledHandler)) | |||
// go rpsTelemetryCalculator(ctr) | |||
log.Fatal(http.ListenAndServe(":8080", nil)) | |||
log.Fatal(http.ListenAndServe(":8080", &ochttp.Handler{Propagation: &tracecontext.HTTPFormat{}})) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
where is this defined? When I try to compile this, it doesn't compile:
---> Running in 8f6a5333361a
# rpsdemo/cmd/app
cmd/app/app.go:92:71: undefined: tracecontext
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
missed one line in the import: "go.opencensus.io/plugin/ochttp/propagation/tracecontext"
@jeremyrickard, good point, let me switch to vendor. |
Dope, thanks @reyang I’ll pull this in to the other repo and give it a whirl. |
Integration with OpenCensus and LocalForwarder.
Use environment variable OCAGENT_TRACE_EXPORTER_ENDPOINT to specify the LocalForwarder endpoint.