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

Initial gin-gonic instrumentation with otel-go #15

Merged
merged 5 commits into from
May 14, 2020

Conversation

krnowak
Copy link
Member

@krnowak krnowak commented Apr 16, 2020

This is some initial code that does the instrumentation. Still need to fix the tests, add docs and a Dockerfile with an example app. So it's work in progress.

There is the common.go file that is mostly about attributes for the span. I suppose it will end up being elsewhere in the long run.

@krnowak krnowak changed the title WIP: Initial gin-gonic instrumentation with otel-go Initial gin-gonic instrumentation with otel-go Apr 21, 2020
@krnowak
Copy link
Member Author

krnowak commented Apr 21, 2020

Ready for review. For now I have added a mock tracer to otel-go-contrib instead of exposing the one in otel-go. This is to avoid waiting for the potential otel-go changes to make it to master.

Copy link
Member

@andrewhsu andrewhsu left a comment

Choose a reason for hiding this comment

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

LGTM, glad to see the Dockerfile and docker-compose. I'll have a go at the docker-compose later to verify.

@lizthegrey
Copy link
Member

Didn't Datadog sign the CLA allowing the copyright notice to read just the OTel authors?

@krnowak
Copy link
Member Author

krnowak commented Apr 22, 2020

Updated:

  • plugin/gin-gonic/gin/common{,_test}.go are now internal/trace/http{,_test}.go
  • fixed an import path comment in plugin/gin-gonic/gin/doc.go to use the vanity path

Also me when you talk about legal stuff: [insert meme with Homer Simpson backing into the bushes] ;)

@krnowak
Copy link
Member Author

krnowak commented Apr 22, 2020

Updated again to fix a documentation of the WithTracer option.

@andrewhsu
Copy link
Member

Didn't Datadog sign the CLA allowing the copyright notice to read just the OTel authors?

@lizthegrey i don't believe anybody from datadog had committed to this repo with a signed CLA as was done in the opentelemetry-python-contrib repo open-telemetry/opentelemetry-python-contrib#1

Copy link
Member

@andrewhsu andrewhsu left a comment

Choose a reason for hiding this comment

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

requesting change as described in #15 (comment)

@krnowak
Copy link
Member Author

krnowak commented Apr 22, 2020

Updated, did some small fixes in tests, and added the NOTICE file.

Copy link
Member

@lizthegrey lizthegrey left a comment

Choose a reason for hiding this comment

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

I'm sorry, but I'm going to need to block merging this until we can discuss the CLA, the copyright notice, etc. at governance committee.

@andrewhsu
Copy link
Member

I'm sorry, but I'm going to need to block merging this until we can discuss the CLA, the copyright notice, etc. at governance committee.

@lizthegrey is there an eta on discussing with the governance committee?

fyi i used https://github.com/cncf/foundation/blob/master/copyright-notices.md#what-about-third-party-code as guidance for this PR since the code is altered from original source

@lizthegrey
Copy link
Member

I'm sorry, but I'm going to need to block merging this until we can discuss the CLA, the copyright notice, etc. at governance committee.

@lizthegrey is there an eta on discussing with the governance committee?

Tomorrow.

fyi i used cncf/foundation:copyright-notices.md@master#what-about-third-party-code as guidance for this PR since the code is altered from original source

There are certain sensitivities here about not wanting to bias towards any one vendor in the copyright notices, etc. -- none of the other code contributed to OTel says "copyright Honeycomb", "copyright Lightstep", etc. so it's a matter of fairness.

@lizthegrey
Copy link
Member

lizthegrey commented Apr 23, 2020

I'm sorry, but I'm going to need to block merging this until we can discuss the CLA, the copyright notice, etc. at governance committee.

@lizthegrey is there an eta on discussing with the governance committee?

Tomorrow.

fyi i used cncf/foundation:copyright-notices.md@master#what-about-third-party-code as guidance for this PR since the code is altered from original source

There are certain sensitivities here about not wanting to bias towards any one vendor in the copyright notices, etc. -- none of the other code contributed to OTel says "copyright Honeycomb", "copyright Lightstep", etc. so it's a matter of fairness.

We met. @tedsuo will follow up with more specific detail, but the CNCF third party code guideline applies unless the contributor has waived the requirement. In this case, the contributor Datadog has waived the requirement (they are not a third party to this project). One way to move forward may be to explicitly get a Datadog engineer to append the commit that strips the copyright notices to make clear that it's officially sanctioned.

@MikeGoldsmith MikeGoldsmith mentioned this pull request Apr 24, 2020
@tedsuo
Copy link

tedsuo commented Apr 24, 2020

Thanks @lizthegrey. I'm reaching out to Datadog. I feel we have been given permission to change these licenses, but I will confirm again, and look to adding a clause in our community repo to clarify this subject.

Copy link
Member

@MikeGoldsmith MikeGoldsmith left a comment

Choose a reason for hiding this comment

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

Plugin code looks good, I understand there is some stuff to iron out regarding the DataDog licence though.

@lizthegrey lizthegrey added the blocked: copyright Waiting on licensing to be addressed before progress can be made label May 4, 2020
@krnowak krnowak requested a review from Aneurysm9 as a code owner May 5, 2020 15:18
@jeremy-lq
Copy link

Datadog did give our explicit permission to attribute copyright to "OpenTelemetry Authors" here: open-telemetry/community#305 (comment)

I wasn't previously aware of this thread. If there are future questions about the topic or clarification needed, do feel free to mention me so I can take a look.

@lizthegrey
Copy link
Member

Thanks, y'all.

@MrAlias MrAlias self-requested a review May 14, 2020 19:52
Based on [this](open-telemetry/community#305 (comment))
approval, changing attribution to the OpenTelemetry authors.
@krnowak krnowak requested a review from evantorrie as a code owner May 14, 2020 20:04
@MrAlias MrAlias requested a review from lizthegrey May 14, 2020 20:07
@MrAlias MrAlias removed the blocked: copyright Waiting on licensing to be addressed before progress can be made label May 14, 2020
Use new `kv` and `value` packages.
Copy link
Member

@andrewhsu andrewhsu left a comment

Choose a reason for hiding this comment

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

LGTM

@jmacd jmacd dismissed lizthegrey’s stale review May 14, 2020 22:18

Based on her "Thanks y'all"

@jmacd jmacd merged commit 87b1c69 into open-telemetry:master May 14, 2020
plantfansam referenced this pull request in plantfansam/opentelemetry-go-contrib Mar 18, 2022
goimports for import rewritting
golangci-lint as the configurable linting swiss army knife.

These tools are recorded in [tools.go](https://github.com/golang/go/wiki/Modules#how-can-i-track-tool-dependencies-for-a-module). This records
them as a dependency to make sure we're all using the same tool versions.

To make sure this project's tool's versions don't stomp over versions
from other projects, they are installed in ./.tools, which is
.gitignored.

goimports was run and fixed up a single file:
plugin/httptrace/httptrace.go

I prefer to group local packages below external packages, hence the use
of goimports -local option.

.golangci.yml contains nothing but an incomplete set of defaults ATM.
I expect those to change over time though. ;-)

To use, run:

$ make precommit

Fixes #15
@pellared pellared added this to the untracked milestone Nov 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants