-
Notifications
You must be signed in to change notification settings - Fork 539
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
AWS Lambda Instrumentation should use presence of context, not env var, to parent to Lambda #565
Comments
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days. |
Just a quick question,
Are you saying that Lambda cannot start a sampled trace if the parent was constructed by reading an Which we solved by just updating the documentation to warn users that traces will be "not sampled" unless they explicitly set |
I was wondering if this is still an issue? I can see that the current implementation only overwrites the Lines 352 to 355 in e5a65c6
There are also methods to |
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days. |
This issue was closed because it has been stale for 14 days with no activity. |
Currently, AWS Lambda instrumentation checks whether a Lambda-provided parent is sampled or not to determine whether to instead extract from headers.
https://github.com/open-telemetry/opentelemetry-js-contrib/blob/main/plugins/node/opentelemetry-instrumentation-aws-lambda/src/instrumentation.ts#L322
Actually Lambda always populates the environment variable, and it will be just a trace ID when env var propagation should be ignored. If we don't make sure to ignore this case, then it is never possible for the Lambda to start a sampled trace. This should be tweaked to not overwrite the
parent
variablehttps://github.com/open-telemetry/opentelemetry-js-contrib/blob/main/plugins/node/opentelemetry-instrumentation-aws-lambda/src/instrumentation.ts#L312
The text was updated successfully, but these errors were encountered: