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

Separate Carrier into Injector and Extractor #105

Closed
jtescher opened this issue Apr 30, 2020 · 3 comments · Fixed by #164
Closed

Separate Carrier into Injector and Extractor #105

jtescher opened this issue Apr 30, 2020 · 3 comments · Fixed by #164
Labels
help wanted Good for taking. Extra help will be provided by maintainers/approvers

Comments

@jtescher
Copy link
Member

See open-telemetry/opentelemetry-specification#578 for spec changes

@jtescher jtescher added the help wanted Good for taking. Extra help will be provided by maintainers/approvers label Jul 5, 2020
@TommyCpp
Copy link
Contributor

I think we can use something like

pub trait Carrier{}

impl<T> Carrier for T where T: Injector + Extractor{}

which basically make Carrier into a marker trait and implement it for every struct that implements Injector and Extractor

@jtescher
Copy link
Member Author

@TommyCpp do you have cases in mind that would prefer to operate on Carrier? It seems likely that they exist, but most of the obvious use cases are either client or server libraries that would probably only impl Injector or Extractor.

@TommyCpp
Copy link
Contributor

@TommyCpp do you have cases in mind that would prefer to operate on Carrier?

Hmmm actually not. I guess it make sense to replace Carrier with Injector and Extractor. I'd like to work on this if that's OK

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Good for taking. Extra help will be provided by maintainers/approvers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants