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 Tracestate into the SamplingResult struct #1432

Merged

Conversation

ozerovandrei
Copy link
Contributor

@ozerovandrei ozerovandrei commented Jan 2, 2021

Add trace.Tracestate field into the SDK trace.SamplingResult struct.

Use ParentContext from SamplingParameters to return Tracestate in
traceIDRatioSampler, alwaysOnSampler and alwaysOffSampler.

Add a new test to check that Tracestate is passed.

Fixes #1341

@codecov
Copy link

codecov bot commented Jan 2, 2021

Codecov Report

Merging #1432 (cb6c980) into master (db06c8d) will increase coverage by 0.0%.
The diff coverage is 100.0%.

Impacted file tree graph

@@          Coverage Diff           @@
##           master   #1432   +/-   ##
======================================
  Coverage    78.6%   78.6%           
======================================
  Files         126     126           
  Lines        6367    6375    +8     
======================================
+ Hits         5009    5017    +8     
  Misses       1114    1114           
  Partials      244     244           
Impacted Files Coverage Δ
sdk/trace/sampling.go 100.0% <100.0%> (ø)

Add `trace.Tracestate` field into the SDK `trace.SamplingResult` struct.

Use ParentContext from SamplingParameters to return Tracestate in
`traceIDRatioSampler`, `alwaysOnSampler` and `alwaysOffSampler`.

Add a new test to check that Tracestate is passed.
@ozerovandrei ozerovandrei force-pushed the 1341-tracestate-in-samplingresult branch from fa10b10 to 99cd9ce Compare January 6, 2021 07:22
@ozerovandrei
Copy link
Contributor Author

Rebased.

sdk/trace/sampling_test.go Outdated Show resolved Hide resolved
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.

Sampler interface should return Tracestate
5 participants