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 switch to OpenTelemetry #7725

Merged
merged 2 commits into from
Dec 2, 2021
Merged

Initial switch to OpenTelemetry #7725

merged 2 commits into from
Dec 2, 2021

Conversation

hannahhoward
Copy link
Contributor

Goals

Switch the underlying tracing library to OpenTelemetry, with a bridge to OpenCensus for
compatibility

But why? cause OpenCensus is merged into OpenTelemetry and will go away one day in the future.
Screen Shot 2021-12-01 at 4 11 00 PM

Implementation

Don't worry, this changes none of your existing OpenCensus calls! But it switches the underlying library to OpenTelemetry, using an Opencensus Bridge.

Theoretically, no changes. However, libraries that use OpenTelemetry might now get their traces picked up (see for example... the recently merged Graphsync OpenTelemetry instrumentation

But bonus -- you can no start converting your OpenCensus traces... at your leisure. Theoretically, all the spans will still stack.

What about metrics? -- there's a bridge for that too, but I haven't attempted to set it up here.

Why is this so complicated and weird? - a great question. I find it ridiculously complicated too and wish I didn't know about all these OpenSomeFakeInstrumentationStandardThatWillChangeAgainInACoupleYears libraries as part of my career as a programmer, but now I've had to learn them just to get the damn tracing working.

@hannahhoward hannahhoward requested a review from a team as a code owner December 2, 2021 00:18
Switch the underlying tracing library to OpenTelemetry, with a bridge to OpenCensus for
compatibility
@codecov
Copy link

codecov bot commented Dec 2, 2021

Codecov Report

Merging #7725 (bfd1099) into master (0cfc344) will decrease coverage by 0.07%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #7725      +/-   ##
==========================================
- Coverage   39.59%   39.52%   -0.08%     
==========================================
  Files         640      640              
  Lines       68326    68332       +6     
==========================================
- Hits        27056    27009      -47     
- Misses      36631    36675      +44     
- Partials     4639     4648       +9     
Impacted Files Coverage Δ
cmd/lotus-miner/main.go 4.23% <0.00%> (-0.04%) ⬇️
cmd/lotus/main.go 0.00% <0.00%> (ø)
lib/tracing/setup.go 0.00% <0.00%> (ø)
extern/sector-storage/worker_tracked.go 76.53% <0.00%> (-8.17%) ⬇️
chain/events/observer.go 71.64% <0.00%> (-6.72%) ⬇️
chain/rand/rand.go 57.89% <0.00%> (-6.32%) ⬇️
markets/retrievaladapter/client_blockstore.go 62.50% <0.00%> (-6.25%) ⬇️
chain/stmgr/call.go 67.87% <0.00%> (-3.64%) ⬇️
chain/types/blockheader.go 55.55% <0.00%> (-2.23%) ⬇️
storage/wdpost_sched.go 75.49% <0.00%> (-1.97%) ⬇️
... and 13 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 0cfc344...bfd1099. Read the comment docs.

@magik6k magik6k merged commit d5e1cc0 into master Dec 2, 2021
@magik6k magik6k deleted the feat/open-telemetry branch December 2, 2021 13:39
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.

2 participants