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

Use aws api that accepts context as first parameter. Opentracing integration requires context as first parameter for propagation #67

Open
etsangsplk opened this issue Sep 10, 2018 · 5 comments

Comments

@etsangsplk
Copy link
Contributor

Opentracing relies on context that encap span metadata inside context to flow through in or out of process boundaries, components etc
I understand that that means breaking change, AWS SDK go offers a parallel set of API that incoporates ...WithContext. See below
https://github.com/aws/aws-sdk-go/blob/master/service/cloudformation/cloudformationiface/interface.go

Or you can carry context in the structure and add WithContext method, which is not quite golang idiom.

opentracing:

example
https://github.com/jaegertracing/jaeger/tree/master/examples/hotrod
https://github.com/jaegertracing/jaeger-client-go

@etsangsplk etsangsplk changed the title add function that accepts context as first parameter. Opentracing integration requires context as first parameter for propagation Use aws api that accepts context as first parameter. Opentracing integration requires context as first parameter for propagation Sep 10, 2018
@etsangsplk
Copy link
Contributor Author

@harlow Any opinion about this suggestion?

@harlow
Copy link
Owner

harlow commented Oct 6, 2018

hi @etsangsplk can you give a code example of where you'd like to pass the context? i'm fine w/ a breaking change if it makes the library easier to work with and encourages good metrics

@etsangsplk
Copy link
Contributor Author

Found a way to hook into aws session,
#72

@etsangsplk etsangsplk reopened this Jan 2, 2019
@etsangsplk
Copy link
Contributor Author

etsangsplk commented Jan 2, 2019

Reopen until PR status is known

@harlow
Copy link
Owner

harlow commented Jan 2, 2019

Hi @etsangsplk while overall I think #72 looks good. I've been trying to get my head around if we need all the open-tracing code scattered around the repo. Or if there is a way to have a Tracer interface that we can optionally pass in (like we do w/ Counter, Logging, Etc)

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

No branches or pull requests

2 participants