Skip to content

Commit 519a92c

Browse files
committed
fix: otel example
1 parent c1b24ae commit 519a92c

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

lambda-runtime/src/layers/otel.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
use std::{fmt::Display, future::Future, pin::Pin, task};
22

33
use crate::LambdaInvocation;
4-
use opentelemetry_semantic_conventions::trace as traceconv;
4+
use opentelemetry_semantic_conventions::attribute as attribute;
55
use pin_project::pin_project;
66
use tower::{Layer, Service};
77
use tracing::{field, instrument::Instrumented, Instrument};
@@ -76,9 +76,9 @@ where
7676
"Lambda function invocation",
7777
"otel.name" = req.context.env_config.function_name,
7878
"otel.kind" = field::Empty,
79-
{ traceconv::FAAS_TRIGGER } = &self.otel_attribute_trigger,
80-
{ traceconv::FAAS_INVOCATION_ID } = req.context.request_id,
81-
{ traceconv::FAAS_COLDSTART } = self.coldstart
79+
{ attribute::FAAS_TRIGGER } = &self.otel_attribute_trigger,
80+
{ attribute::FAAS_INVOCATION_ID } = req.context.request_id,
81+
{ attribute::FAAS_COLDSTART } = self.coldstart
8282
);
8383

8484
// After the first execution, we can set 'coldstart' to false

0 commit comments

Comments
 (0)