Skip to content
This repository has been archived by the owner on Jul 1, 2022. It is now read-only.

Move contextFromString out of JaegerSpanContext into TextMapCodec #517

Merged

Conversation

isaachier
Copy link
Contributor

@isaachier isaachier commented Aug 17, 2018

Fixes #518.

Signed-off-by: Isaac Hier <ihier@uber.com>
@isaachier
Copy link
Contributor Author

As usual, Travis fails due to crossdock timeout.

@@ -54,6 +57,25 @@ private TextMapCodec(Builder builder) {
this.baggagePrefix = builder.baggagePrefix;
}

public static JaegerSpanContext contextFromString(String value)
Copy link
Collaborator

Choose a reason for hiding this comment

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

If it's used only in tests, can't we make this private and test the inject operation instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Isn't the point of the internal package to imply anything here may change without warning? Public makes this easily accessible in a number of test modules without compromising our external API.

Copy link
Member

Choose a reason for hiding this comment

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

This has been blocking the other PR, so I would rather not cause major refactoring of the tests. But going for minimum visibility is always a good goal. In this case, wouldn't all the tests work just as well if this was package level viz?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I tried it and sadly no. propagation is its own package.

Copy link
Member

Choose a reason for hiding this comment

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

Ah, yes. Ok then.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I can probably fix the other tests. Don't merge yet.

Copy link
Member

Choose a reason for hiding this comment

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

Oops too late. Put another one if a simple fix.

@codecov
Copy link

codecov bot commented Aug 17, 2018

Codecov Report

Merging #517 into master will decrease coverage by 0.1%.
The diff coverage is 90.9%.

Impacted file tree graph

@@             Coverage Diff             @@
##             master    #517      +/-   ##
===========================================
- Coverage     88.31%   88.2%   -0.11%     
  Complexity      499     499              
===========================================
  Files            65      65              
  Lines          1849    1849              
  Branches        239     239              
===========================================
- Hits           1633    1631       -2     
- Misses          139     141       +2     
  Partials         77      77
Impacted Files Coverage Δ Complexity Δ
...a/io/jaegertracing/internal/JaegerSpanContext.java 89.74% <ø> (-0.06%) 22 <0> (-3)
...egertracing/internal/propagation/TextMapCodec.java 89.74% <90.9%> (+0.03%) 21 <3> (+3) ⬆️
...egertracing/internal/reporters/RemoteReporter.java 83.33% <0%> (-2.39%) 7% <0%> (ø)

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 26869a9...36629bc. Read the comment docs.

@yurishkuro yurishkuro merged commit b6a824d into jaegertracing:master Aug 17, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants