You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
I wanted to propose a small enhancement to the OpenTelemetry tracing layer implementation in the AWS Lambda Rust runtime.
Currently, in otel.rs, the tracing span for Lambda invocations doesn't include a way to specify the span kind (e.g., server, client). Adding this capability could improve how systems are represented in observability platforms.
My suggestion: we could add an otel.kind field to the span creation, initialized as empty. This would allow users to set the span kind in their handlers if needed. For example:
let span = tracing::info_span!(
"Lambda function invocation",
"otel.name" = req.context.env_config.function_name,
"otel.kind" = field::Empty, // New field for span kind
{ traceconv::FAAS_TRIGGER } = &self.otel_attribute_trigger,
{ traceconv::FAAS_INVOCATION_ID } = req.context.request_id,
{ traceconv::FAAS_COLDSTART } = self.coldstart
);
Users could then set the span kind in their handler like this:
This issue is now closed. Comments on closed issues are hard for our team to see.
If you need more assistance, please either tag a team member or open a new issue that references this one.
Hi,
I wanted to propose a small enhancement to the OpenTelemetry tracing layer implementation in the AWS Lambda Rust runtime.
Currently, in otel.rs, the tracing span for Lambda invocations doesn't include a way to specify the span kind (e.g., server, client). Adding this capability could improve how systems are represented in observability platforms.
My suggestion: we could add an
otel.kind
field to the span creation, initialized as empty. This would allow users to set the span kind in their handlers if needed. For example:Users could then set the span kind in their handler like this:
This change should be backward compatible and provide more flexibility for users. I'd love to hear your thoughts on this, and happy to propose a PR!
The text was updated successfully, but these errors were encountered: