Skip to content

Commit

Permalink
datadogconnector: migrate to latest semconv version (open-telemetry#3…
Browse files Browse the repository at this point in the history
…5269)

Description: The version of semconv is upgraded from to v1.17.0 and
v1.5.0 to v1.27.0

Link to tracking Issue:
open-telemetry#22095

Testing: Tests passed

Co-authored-by: Alex Boten <[email protected]>
  • Loading branch information
2 people authored and jriguera committed Oct 4, 2024
1 parent 1b62c6e commit 8ee8eca
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion connector/datadogconnector/connector.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import (
"go.opentelemetry.io/collector/consumer"
"go.opentelemetry.io/collector/pdata/pmetric"
"go.opentelemetry.io/collector/pdata/ptrace"
semconv "go.opentelemetry.io/collector/semconv/v1.17.0"
semconv "go.opentelemetry.io/collector/semconv/v1.27.0"
"go.opentelemetry.io/otel/metric/noop"
"go.uber.org/zap"
)
Expand Down
5 changes: 2 additions & 3 deletions connector/datadogconnector/connector_native_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@ import (
"go.opentelemetry.io/collector/connector/connectortest"
"go.opentelemetry.io/collector/consumer/consumertest"
"go.opentelemetry.io/collector/pdata/ptrace"
conventions127 "go.opentelemetry.io/collector/semconv/v1.27.0"
semconv "go.opentelemetry.io/collector/semconv/v1.5.0"
semconv "go.opentelemetry.io/collector/semconv/v1.27.0"
"go.uber.org/zap"
"google.golang.org/protobuf/proto"
"google.golang.org/protobuf/testing/protocmp"
Expand Down Expand Up @@ -146,7 +145,7 @@ func TestMeasuredAndClientKindNative(t *testing.T) {
td := ptrace.NewTraces()
res := td.ResourceSpans().AppendEmpty().Resource()
res.Attributes().PutStr("service.name", "svc")
res.Attributes().PutStr(conventions127.AttributeDeploymentEnvironmentName, "my-env")
res.Attributes().PutStr(semconv.AttributeDeploymentEnvironmentName, "my-env")

ss := td.ResourceSpans().At(0).ScopeSpans().AppendEmpty().Spans()
// Root span
Expand Down
2 changes: 1 addition & 1 deletion connector/datadogconnector/connector_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import (
"go.opentelemetry.io/collector/featuregate"
"go.opentelemetry.io/collector/pdata/pcommon"
"go.opentelemetry.io/collector/pdata/ptrace"
semconv "go.opentelemetry.io/collector/semconv/v1.5.0"
semconv "go.opentelemetry.io/collector/semconv/v1.27.0"
"go.uber.org/zap"
"google.golang.org/protobuf/proto"
)
Expand Down

0 comments on commit 8ee8eca

Please sign in to comment.