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

Add span_kind to the honeycomb exporter #474

Merged
merged 1 commit into from
Sep 29, 2020

Conversation

chris-smith-zocdoc
Copy link
Contributor

@paulosman

Adds the span kind to the event sent to Honeycomb, allowing for queries by the type of span (client / server)

Let me know if you thing I should rename the field or lowercase the values.

@chris-smith-zocdoc chris-smith-zocdoc requested a review from a team as a code owner July 20, 2020 16:54
@project-bot project-bot bot added this to In progress in Collector Jul 20, 2020
bogdandrutu
bogdandrutu previously approved these changes Jul 20, 2020
Collector automation moved this from In progress to Reviewer approved Jul 20, 2020
@bogdandrutu
Copy link
Member

@lizthegrey can you review this?

@@ -177,6 +177,7 @@ func (e *honeycombExporter) pushTraceData(ctx context.Context, td consumerdata.T
e.sendMessageEvents(td, span, traceLevelFields)
e.sendSpanLinks(span)

ev.AddField("span_kind", span.Kind.String())
Copy link
Member

Choose a reason for hiding this comment

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

Copy link
Contributor Author

Choose a reason for hiding this comment

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

meta.span_type is currently used for span_event and link per the metadata kind docs https://docs.honeycomb.io/working-with-your-data/managing-your-data/definitions/#metadata-kind

If sending values other than link/span_event is alright with you, I can change it

Copy link
Member

Choose a reason for hiding this comment

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

We need a bit of time to think through this API/schema design, is it okay with you if we come back to you in a week with a decision? Regardless, please go ahead and lowercase the constants as we're pretty sure on that.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah no rush on my end

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Separate action item: I think the exporter needs to be updated to the new internal data format, which will give it access to the other span kinds (producer, consumer, internal)

@lizthegrey lizthegrey moved this from Reviewer approved to Review in progress in Collector Jul 20, 2020
@codecov
Copy link

codecov bot commented Jul 20, 2020

Codecov Report

Merging #474 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #474   +/-   ##
=======================================
  Coverage   88.86%   88.86%           
=======================================
  Files         251      251           
  Lines       11979    11979           
=======================================
  Hits        10645    10645           
  Misses        990      990           
  Partials      344      344           
Flag Coverage Δ
#integration 75.42% <0.00%> (ø)
#unit 87.88% <0.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.


Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0cd707d...d2d734a. Read the comment docs.

@bogdandrutu
Copy link
Member

@lizthegrey do I understand correctly to hold on this PR until next week?

@lizthegrey
Copy link
Member

@lizthegrey do I understand correctly to hold on this PR until next week?

Affirm, please hold until we can figure out the right schema on our side. Thanks!

@bogdandrutu
Copy link
Member

Revoking my approval until @lizthegrey confirms the solution.

@bogdandrutu bogdandrutu self-requested a review July 21, 2020 17:52
@bogdandrutu bogdandrutu dismissed their stale review July 21, 2020 17:52

Revoking my approval until @lizthegrey confirms the solution.

mxiamxia referenced this pull request in mxiamxia/opentelemetry-collector-contrib Jul 22, 2020
* Correct README example for tail sampling

Signed-off-by: Annanay <annanayagarwal@gmail.com>

* Use standard yaml list syntax

Signed-off-by: Annanay <annanayagarwal@gmail.com>
@bogdandrutu bogdandrutu moved this from Review in progress to In progress in Collector Jul 23, 2020
@bogdandrutu
Copy link
Member

@lizthegrey ping

@lizthegrey
Copy link
Member

ping @paulosman and @MikeGoldsmith

@tigrannajaryan
Copy link
Member

@paulosman and @MikeGoldsmith do you plan to continue working on this?

@MikeGoldsmith
Copy link
Member

Ah, this got lost in our backlog. We'll look into it ASAP.

@flands flands moved this from In progress to Waiting on author in Collector Sep 17, 2020
@MikeGoldsmith
Copy link
Member

@chris-smith-zocdoc We've finished our internal work and we've settled on meta.annotation_type for span events and span links.

Sorry for the delay, there was some additional work we needed to complete beforehand.

@MikeGoldsmith
Copy link
Member

Hey @chris-smith-zocdoc, I've re-reviewed your PR and please can you make the following changes:

  1. line 61 replace spanType with annotation_type on spanEvent struct
  2. line 72 replace spanType with annotation_type on link struct
  3. link 181 use span_type as you are already, what you have already is good 👍

Thanks!

@bogdandrutu
Copy link
Member

Please also rebase

@MikeGoldsmith
Copy link
Member

@chris-smith-zocdoc If you don't have time to make the changes, I can do them and the rebase. I won't be able to use this PR, but I can base a branch on your original branch so your commits are not lost.

Thanks

Collector automation moved this from Waiting on author to Done Sep 22, 2020
Replace span_type with annotation_type
Collector automation moved this from Done to In progress Sep 22, 2020
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.

Looks good for me - thanks @chris-smith-zocdoc.

@chris-smith-zocdoc
Copy link
Contributor Author

@MikeGoldsmith rebased and made changes

@MikeGoldsmith
Copy link
Member

Thanks @chris-smith-zocdoc. We're happy with the changes above but need to finalise a couple of things on our side. Please do not merge this and I'll update when we're ready.

@bogdandrutu
Copy link
Member

@MikeGoldsmith please mark this with "required changes" so we don't by mistake merge this

@MikeGoldsmith
Copy link
Member

MikeGoldsmith commented Sep 24, 2020

Thanks @bogdandrutu - after some internal comms we're happy for this to merged as there won't be a negative effect if this were merged / released before our internal things are finished up. Happy for this to be merged now 😄

Collector automation moved this from In progress to Reviewer approved Sep 29, 2020
@bogdandrutu bogdandrutu merged commit b37f9aa into open-telemetry:master Sep 29, 2020
Collector automation moved this from Reviewer approved to Done Sep 29, 2020
@chris-smith-zocdoc chris-smith-zocdoc deleted the cs_span_kind branch November 24, 2020 03:49
ljmsc referenced this pull request in ljmsc/opentelemetry-collector-contrib Feb 21, 2022
* wip: observers

* wip: float observers

* fix copy pasta

* wip: rework observers in sdk

* small fix in global meter

* wip: aggregators and selectors

* wip: monotonicity option for observers

* some refactor

* wip: docs

needs more package docs (especially for api/metric and sdk/metric)

* fix ci

* Fix copy-pasta in docs

Co-Authored-By: Mauricio Vásquez <mauricio@kinvolk.io>

* recycle unused recorders in observers

if a recorder for a labelset is unused for a second collection cycle
in a row, drop it

* unregister

* thread-safe set callback

* Fix docs

* Revert "wip: aggregators and selectors"

This reverts commit 37b7d05aed5dc90f6d5593325b6eb77494e21736.

* update selector

* tests

* Rework number equality

Compare concrete numbers, so we can get actual numbers in the error
message when they are not equal, not some uint64 representation. This
also uses InDelta for comparing floats.

* Ensure that Observers are registered in the same order

* Run observers in fixed order

So the tests can be reproducible - iterating a map made the order of
measurements random.

* Ensure the proper alignment of the delegates

This wasn't checked at all. After adding the checks, the test-386
failed.

* Small tweaks to the global meter test

* Ensure proper alignment of the callback pointer

test-386 was complaining about it

* update docs

* update a TODO

* address review issues

* drop SetCallback

Co-authored-by: Mauricio Vásquez <mauricio@kinvolk.io>
Co-authored-by: Rahul Patel <rghetia@yahoo.com>
codeboten pushed a commit that referenced this pull request Nov 23, 2022
All instrumentations packages have almost exactly same setup.py files.
This commit adds a python script that generates it from a source
template. This dramatically reduces the time and effort required to
update all instrumentation setup.py files, and also reduces chances of
making manual mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Collector
  
Done
Development

Successfully merging this pull request may close these issues.

None yet

5 participants