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

Change AwsLambdaInstrumentor span attribute settings to match faas semconv #2371

Closed
tammy-baylis-swi opened this issue Mar 26, 2024 · 0 comments · Fixed by #2372
Closed

Change AwsLambdaInstrumentor span attribute settings to match faas semconv #2371

tammy-baylis-swi opened this issue Mar 26, 2024 · 0 comments · Fixed by #2372
Assignees

Comments

@tammy-baylis-swi
Copy link
Contributor

Is your feature request related to a problem?
No.

Describe the solution you'd like
Python AwsLambdaInstrumentor attribute settings are not consistent with the latest faas semconv. Specifically, I think these instrumentor changes are needed:

  1. ResourceAttributes.FAAS_ID --> ResourceAttributes.CLOUD_RESOURCE_ID
  2. SpanAttributes.FAAS_EXECUTION --> SpanAttributes.FAAS_INVOCATION_ID

For this solution, change these set_attribute calls. Make special note in the release notes that this is breaking. This is not additive like #2368.

Describe alternatives you've considered
I've thought about and brought up 2 other ideas on Slack:

Idea (A)
The Python AwsLambdaInstrumentor upgrades to a newer semconv version. Would it need to be an opt-in for users like for http instrumentation? (i.e. this recent issue) Would this need to be presented to an Otel Spec project group? (i.e. this issue)

Idea (B)
The Python AwsLambdaInstrumentor gets request/response hooks implemented like in NodeJS. This would allow users to add any attributes they like. I see this was requested, discussed in Otel Spec, PR'd (rejected), discussed at faas project sig, alternatively PR'd as a SpanProcessor requirement (rejected), and brought up again in Slack. I haven't found any other updates since May 2023.

In this otel-faas thread, it was mentioned that the faas attributes are not stable so a breaking change would be ok. Therefore we could implement the quick, in-place change.

Additional context

  1. https://cloud-native.slack.com/archives/C01PD4HUVBL/p1711140906040599
  2. https://cloud-native.slack.com/archives/C04HVBETC9Z/p1711387797268909
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant