Skip to content
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

sdk/trace: add Jaeger remote sampler #2150

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 4 additions & 1 deletion sdk/go.mod
Expand Up @@ -5,11 +5,14 @@ go 1.15
replace go.opentelemetry.io/otel => ../

require (
github.com/gogo/protobuf v1.3.2
github.com/google/go-cmp v0.5.6
// TODO switch to https://github.com/jaegertracing/jaeger-idl
github.com/jaegertracing/jaeger v1.24.0
Comment on lines +10 to +11
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of importing jaegertracing/jaeger we should import jaegertracing/jaeger-idl. This is currently blowing up go.sum.
In fact, we only need proto/api_v2/sampling.proto.

I'm not sure how to do this though, help/feedback is welcome!

We should add it as git submodule:

[submodule "jaeger-idl"]
	path = sdk/trace/internal/jaeger-idl
	url = https://github.com/jaegertracing/jaeger-idl

But I'm not sure how to generate and import the proto as part of the build process.

  • Do I add a target in Makefile?
  • Should I check in the generated code or should people generate it themselves first?

fyi, the jaegertracing/protobuf image doesn't work on my machine (Apple M1). So that's also making testing more difficult... 😬

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This would need to live in a separate module to ensure that the increased dependency footprint only impacts applications that choose explicitly to include this sampler. Indeed, it might be best for this to live in the contrib repo as it is not required to conform to the spec.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, sounds good 👍 There aren't any other samplers yet in contrib, should I create a new folder, i.e. samplers/jaeger_remote?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, sounds good There aren't any other samplers yet in contrib, should I create a new folder, i.e. samplers/jaeger_remote?

Yeah, please create a new sampler directory. We can discuss in the contrib PR, but I would prefer samplers/jaeger.

github.com/stretchr/testify v1.7.0
go.opentelemetry.io/otel v1.0.0-RC2
go.opentelemetry.io/otel/trace v1.0.0-RC2
golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7
golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1
)

replace go.opentelemetry.io/otel/bridge/opencensus => ../bridge/opencensus
Expand Down