Skip to content

Fix B3 propagator to not crash work with DefaultSpan#1148

Merged
codeboten merged 1 commit intoopen-telemetry:masterfrom
owais:b3-propagation-fixes
Sep 23, 2020
Merged

Fix B3 propagator to not crash work with DefaultSpan#1148
codeboten merged 1 commit intoopen-telemetry:masterfrom
owais:b3-propagation-fixes

Conversation

@owais
Copy link
Copy Markdown
Contributor

@owais owais commented Sep 23, 2020

Description

B3 propagator was crashing as it could not find .context and .parent attributes when passed a context with a DefaultSpan instance. I ran into it while trying to instrument a demo grpc service with opentelemetry. I think grpc instrumentation might probably have another issue where it extracts context from incoming request and uses that as the parent for an outgoing request missing the spans in between. I plan to look into that as well later.

Fixes # (issue)

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • Manual test
  • Added unit test

Checklist:

  • Followed the style guidelines of this project
  • Changelogs have been updated
  • Unit tests have been added
  • Documentation has been updated

@owais owais requested a review from a team September 23, 2020 12:39
@owais owais force-pushed the b3-propagation-fixes branch 3 times, most recently from dbe2092 to c039cb2 Compare September 23, 2020 13:54
Copy link
Copy Markdown
Contributor

@codeboten codeboten left a comment

Choose a reason for hiding this comment

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

Nice, looks like linting needs some attention otherwise it looks great!

@owais owais force-pushed the b3-propagation-fixes branch from c039cb2 to 8709002 Compare September 23, 2020 15:08
@codeboten codeboten merged commit 30f79fd into open-telemetry:master Sep 23, 2020
@owais owais deleted the b3-propagation-fixes branch September 23, 2020 15:50
alertedsnake pushed a commit to alertedsnake/opentelemetry-python that referenced this pull request Sep 25, 2020
srikanthccv pushed a commit to srikanthccv/opentelemetry-python that referenced this pull request Nov 1, 2020
Co-authored-by: Mayur Kale <mayurkale@google.com>
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.

4 participants