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

Added Jaeger Propagator to Opentelemetry.Extensions.Propagators #3309

Merged
merged 6 commits into from
Jun 8, 2022
Merged

Added Jaeger Propagator to Opentelemetry.Extensions.Propagators #3309

merged 6 commits into from
Jun 8, 2022

Conversation

notcool11
Copy link
Contributor

@notcool11 notcool11 commented May 26, 2022

  • added jaeger progagator with tests

  • updated changelog

  • moved comment to unreleased

Fixes #1881 .

Changes

Added Jaeger Propagator to the new Opentelemetry.Extensions.Propagators project with tests. Been running this code locally as a standalone propagator in production for about six months.

Couple of notes, I've found that URL encoding in headers is not consistent so sometimes the uber-trace-id is delimited with a : colon and sometimes encoded to %3A. There is also code to handle the shorter 64 traceid vs. the newer 128 bit format.

Unit tests should cover all these items. Thanks.

For significant contributions please make sure you have completed the following items:

  • Appropriate CHANGELOG.md updated for non-trivial changes
  • Design discussion issue #
  • Changes in public API reviewed

* added jaeger progagator with tests

* updated changelog

* moved comment to unreleased
@notcool11 notcool11 requested a review from a team May 26, 2022 16:11
@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented May 26, 2022

CLA Signed

The committers listed above are authorized under a signed CLA.

  • ✅ login: notcool11 / name: tyler jago (9c19f44)

@reyang
Copy link
Member

reyang commented May 26, 2022

More of a question for the maintainers - do we want different propagators to be bundled as a single package or they should be decoupled?

@notcool11
Copy link
Contributor Author

More of a question for the maintainers - do we want different propagators to be bundled as a single package or they should be decoupled?

Oh please no. :(

The discussion in 1881 has bounced several times already. I had it separate before 3244 was merged in and created the new extensions package.

@cijothomas
Copy link
Member

More of a question for the maintainers - do we want different propagators to be bundled as a single package or they should be decoupled?

The Non W3C ones, zipkin/jaeger can be a single package. I think @alanwest suggested it that way earlier, and I agree.
The W3C is part of the main package itself.

Copy link
Member

@reyang reyang left a comment

Choose a reason for hiding this comment

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

LGTM.

@codecov
Copy link

codecov bot commented May 26, 2022

Codecov Report

Merging #3309 (91415d0) into main (efc55d5) will decrease coverage by 0.11%.
The diff coverage is 95.38%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #3309      +/-   ##
==========================================
- Coverage   85.90%   85.78%   -0.12%     
==========================================
  Files         267      268       +1     
  Lines        9383     9448      +65     
==========================================
+ Hits         8060     8105      +45     
- Misses       1323     1343      +20     
Impacted Files Coverage Δ
...lemetry.Extensions.Propagators/JaegerPropagator.cs 95.38% <95.38%> (ø)
...entation/ExportClient/OtlpGrpcTraceExportClient.cs 50.00% <0.00%> (-28.58%) ⬇️
...xporter.OpenTelemetryProtocol/OtlpTraceExporter.cs 59.09% <0.00%> (-18.19%) ⬇️
...emetry.Api/Internal/OpenTelemetryApiEventSource.cs 76.47% <0.00%> (-5.89%) ⬇️
...metryProtocol/Implementation/ActivityExtensions.cs 91.20% <0.00%> (-3.30%) ⬇️
...ter.ZPages/Implementation/ZPagesActivityTracker.cs 97.14% <0.00%> (-2.86%) ⬇️

@github-actions
Copy link
Contributor

github-actions bot commented Jun 3, 2022

This PR was marked stale due to lack of activity and will be closed in 7 days. Commenting or Pushing will instruct the bot to automatically remove the label. This bot runs once per day.

@github-actions github-actions bot added the Stale Issues and pull requests which have been flagged for closing due to inactivity label Jun 3, 2022
@reyang reyang removed the Stale Issues and pull requests which have been flagged for closing due to inactivity label Jun 3, 2022
nit from PR comments
@notcool11
Copy link
Contributor Author

@reyang , @cijothomas , @alanwest
this was a pet project for me at my current company, but my last day here will be 06/10. i'll not have access to the fork after i leave. i also don't have confidence that anyone else at the company will care enough to try to babysit this PR to make any changes.

@pellared
Copy link
Member

pellared commented Jun 8, 2022

@notcool11, are you able to fix the build failures?

@notcool11
Copy link
Contributor Author

@pellared , yep. was failing after pulling latest, had to update the event source per @cijothomas . building in my fork now, should be done shortly

* Refactor string extensions (#3306)

* fixing InMemoryExporter & Metrics bug. new class: MetricSnapshot. new ctor: InMemoryExporter(Func) (#3266)

* Exporting tags consistently (#3281)

* feat(tracing): deprecate use of B3 propagator class from API package - use Extensions.Propagators package instead (#3289)

* Use TagTransformer for ConsoleExporter 💻  (#3311)

* Add core tag prefix to OTLP logs project (#3316)

* Add Extensions.Propagators to core (#3318)

* Changelog update for 1.3.0-rc.1 release prep (#3320)

* Adjust changelog to reflect actual date and package (#3327)

* Update protos to 0.18.0 (#3321)

Co-authored-by: Cijo Thomas <[email protected]>

* Propagation in case of remote parent (#3310)

* Replace MOQ with InMemoryExporter in ASP.NET Core (#3328)

* cleanup CI (#3332)

* ConsoleMetricExporter to export all resource attributes (#3334)

* Fix EventSource for B3Propagator (#3336)

* Update changelog to prepare release (#3337)

* Move public api to shipped (#3338)

* Post release cleanups (#3340)

* Fix NullReferenceException caught by SDK when metric has a tag with a null value (#3325)

* Add isRemote check for context propagation (#3329)

* Minor test fixes sln additions (#3341)

* Update .sln file;Remove docker compose file for net5.0 (#3347)

* Remove StackExchangeRedis Instrumenation (#3346)

Co-authored-by: Cijo Thomas <[email protected]>

* fixed event source in jaegerpropagator after pulling latest

Co-authored-by: Piotr Kiełkowicz <[email protected]>
Co-authored-by: Timothy Mothra <[email protected]>
Co-authored-by: Alan West <[email protected]>
Co-authored-by: John <[email protected]>
Co-authored-by: Cijo Thomas <[email protected]>
Co-authored-by: Vishwesh Bankwar <[email protected]>
Co-authored-by: Reiley Yang <[email protected]>
Co-authored-by: Utkarsh Umesan Pillai <[email protected]>
@notcool11
Copy link
Contributor Author

@pellared , yep. was failing after pulling latest, had to update the event source per @cijothomas . building in my fork now, should be done shortly

Green in my fork now.

@pellared
Copy link
Member

pellared commented Jun 8, 2022

There are conflicts with main

@notcool11
Copy link
Contributor Author

@pellared , ugh, that's lame. i didn't even change that file. stupid refresh from main now shows 129 files changed when really i just have 5. what a pita.

@notcool11
Copy link
Contributor Author

is there a better way to refresh my fork than this??
git pull https://github.com/open-telemetry/opentelemetry-dotnet.git

@pellared
Copy link
Member

pellared commented Jun 8, 2022

git remote add upstream https://github.com/open-telemetry/opentelemetry-dotnet.git
git fetch -p upstream
git merge upstream/main # or git rebase upstream/master - but this would require force push

@notcool11
Copy link
Contributor Author

only files that matter in this PR:
src/OpenTelemetry.Extensions.Propagators/.publicApi/net462/PublicAPI.Unshipped.txt
src/OpenTelemetry.Extensions.Propagators/.publicApi/netstandard2.0/PublicAPI.Unshipped.txt
src/OpenTelemetry.Extensions.Propagators/CHANGELOG.md
src/OpenTelemetry.Extensions.Propagators/JaegerPropagator.cs
test/OpenTelemetry.Extensions.Propagators.Tests/JaegerPropagatorTest.cs

do you need me to pull from main again or can you just merge and ignore changes in this PR except the above files?? my guess is this fork will continue to drift and will need to be rebased.

@notcool11
Copy link
Contributor Author

git remote add upstream https://github.com/open-telemetry/opentelemetry-dotnet.git
git fetch -p upstream
git merge upstream/main # or git rebase upstream/master - but this would require force push

okay, i'll try that

@cijothomas cijothomas merged commit 1da5b86 into open-telemetry:main Jun 8, 2022
alanwest added a commit that referenced this pull request Jun 27, 2022
* Added Jaeger Propagator to Opentelemetry.Extensions.Propagators (#3309)

* Remove unnecessary bullet in CHANGELOG.md (#3352)

Co-authored-by: Cijo Thomas <[email protected]>

* Fix OTLP test (#3357)

* Show that test is not doing what you might think it does

* More asserts the merrier

* Show this little test that it has potential

* improve test coverage: InMemoryExporter & IDeferredMeterProviderBuilder (#3345)

* [SDK] Circular buffer tweaks + cpu pressure test (#3349)

* CircularBuffer tweaks and cpu pressure test.

* Switch to Volatile.Read.

* Perf tweaks.

* Remove race check in debug after doing more testing.

Co-authored-by: Cijo Thomas <[email protected]>

* Fix event name logic + support null categoryname. (#3359)

* In-memory Exporter: Buffer log scopes (#3360)

* Buffer log scopes when using in-memory exporter.

* CHANGELOG update.

* Code review.

* Tests.

* CHANGELOG tweak.

* SDK: Forward SetParentProvider to children of CompositeProcessor (#3368)

* Examples: Fix ParentProvider not being set on MyFilteringProcessor (#3370)

* Fix ParentProvider not being set on MyFilteringProcessor example.

* Added XML comments.

* Tweak.

* Typo.

* Logs: Add helper ctors & forceflush on OpenTelemetryLoggerProvider (#3364)

* Add helper ctors & forceflush on OpenTelemetryLoggerProvider.

* CHANGELOG update.

* Unit tests.

* Code review.

* Code review.

* Tweak.

* SDK: Nullable annotations for base classes & batch + shims to enable compiler features (#3374)

* Nullable annotations and shims for SDK base classes & batch.

* Target updates.

* Remove System.Collections.Immutable ref.

* ApiCompat attribute exclusions.

* ASPNETCore instrumentation to populate httpflavor tag (#3372)

* improve test coverage: InMemoryExporter SnapshotMetric (#3344)

* Fix AspNetCore metrics to use correct value for http.flavor (#3379)

* Fix AspNetCore metrics to use correct value for http.flavor

* word better

* Logs: Add LogRecordData (#3378)

* Add LogRecordData and hook up to LogRecord.

* CHANGELOG update.

* Code review.

* Remove SetHttpFlavor from Http instrumentations (#3381)

* Asp.Net Core trace instrumentation to populate http schema tag (#3392)

* Try asp.net core tests with inproc server (#3394)

* Dedupe IsPackable (#3398)

* Remove AspNet and AspNet.TelemetryHttpModule instrumentation projects (#3397)

* Handle possible exception when initializing the default service name (#3405)

* HttpClient: Invoke Enrich when SocketException = HostNotFound (#3407)

* Add & use ConfigureResource API. (#3307)

Co-authored-by: tyler jago <[email protected]>
Co-authored-by: Robert Pająk <[email protected]>
Co-authored-by: Cijo Thomas <[email protected]>
Co-authored-by: Timothy Mothra <[email protected]>
Co-authored-by: Mikel Blanchard <[email protected]>
Co-authored-by: Reiley Yang <[email protected]>
Co-authored-by: Utkarsh Umesan Pillai <[email protected]>
Co-authored-by: Christian Neumüller <[email protected]>
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.

Support for Jaeger Propagator
5 participants