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

Convert status to not be a pointer in the Span #2242

Merged
merged 2 commits into from
Dec 3, 2020

Conversation

bogdandrutu
Copy link
Member

Signed-off-by: Bogdan Drutu bogdandrutu@gmail.com

@bogdandrutu bogdandrutu requested a review from a team December 2, 2020 19:01
@codecov
Copy link

codecov bot commented Dec 2, 2020

Codecov Report

Merging #2242 (e999bd3) into master (d3387a8) will decrease coverage by 0.02%.
The diff coverage is 96.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2242      +/-   ##
==========================================
- Coverage   92.13%   92.10%   -0.03%     
==========================================
  Files         272      272              
  Lines       15313    15284      -29     
==========================================
- Hits        14109    14078      -31     
- Misses        827      828       +1     
- Partials      377      378       +1     
Impacted Files Coverage Δ
translator/internaldata/oc_to_traces.go 86.33% <ø> (-0.23%) ⬇️
translator/internaldata/traces_to_oc.go 87.33% <ø> (-0.12%) ⬇️
translator/trace/jaeger/jaegerproto_to_traces.go 90.67% <ø> (-0.05%) ⬇️
translator/trace/zipkin/zipkinv2_to_traces.go 89.79% <ø> (-0.05%) ⬇️
internal/goldendataset/span_generator.go 98.29% <50.00%> (ø)
consumer/pdata/generated_trace.go 100.00% <100.00%> (ø)
consumer/pdata/trace.go 97.22% <100.00%> (ø)
exporter/loggingexporter/logging_exporter.go 96.28% <100.00%> (-0.02%) ⬇️
receiver/otlpreceiver/trace/otlp.go 100.00% <100.00%> (ø)
translator/trace/jaeger/traces_to_jaegerproto.go 93.60% <100.00%> (-0.83%) ⬇️
... and 3 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 d3387a8...e999bd3. Read the comment docs.

consumer/pdata/trace.go Outdated Show resolved Hide resolved
Comment on lines -389 to -392
if status.IsNil() {
return nil, nil
}

Copy link
Member

Choose a reason for hiding this comment

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

Should we return (nil, nil) if status.Code()==case pdata.StatusCodeUnset && status.message==""?

Copy link
Member Author

Choose a reason for hiding this comment

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

Not sure, was thinking about that as well. Is that not a different change? That behavior was not there before. Do you suggest to do this?

Copy link
Member

Choose a reason for hiding this comment

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

Because we now don't have a pointer to Status this case will happen always for all successful statuses, so it is a bit more important now. But, probably doesn't matter much, it only affects OpenCensus format. Let's leave as is and we can change in the future if needed.

Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
@bogdandrutu bogdandrutu merged commit 38c7aa3 into open-telemetry:master Dec 3, 2020
@bogdandrutu bogdandrutu deleted the statusnil branch December 3, 2020 18:59
MovieStoreGuy pushed a commit to atlassian-forks/opentelemetry-collector that referenced this pull request Nov 11, 2021
We previously were recording the Schema URL but were not setting
the recorded value when exporting. This change now uses the recorded
value when exporting to OTLP.
Troels51 pushed a commit to Troels51/opentelemetry-collector that referenced this pull request Jul 5, 2024
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.

3 participants