Skip to content

Commit 9d7b1f5

Browse files
committed
[FIX] fix change log entry
1 parent b40c1d6 commit 9d7b1f5

File tree

8 files changed

+14
-10
lines changed

8 files changed

+14
-10
lines changed

CHANGELOG.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm
2121
### Changed
2222

2323
- Jaeger remote sampler's probabilistic strategy now uses the same sampling algorithm as `trace.TraceIDRatioBased` in `go.opentelemetry.io/contrib/samplers/jaegerremote`. (#6892)
24-
- - Migrated `otelecho` instrumentation to use OpenTelemetry semantic conventions (`semconv`) for HTTP attributes. (#6980)
24+
- Support for the `OTEL_SEMCONV_STABILITY_OPT_IN=http/dup` environment variable in `go.opentelemetry.io/contrib/instrumentation/github.com/labstack/echo/otelecho` to emit attributes for both the v1.20.0 and v1.26.0 semantic conventions. (#6980)
2525

2626
### Fixed
2727

instrumentation/github.com/gin-gonic/gin/otelgin/internal/semconvutil/httpconv.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
// SPDX-License-Identifier: Apache-2.0
66

77
// Package semconvutil provides OpenTelemetry semantic convention utilities.
8-
package semconvutil // import "go.opentelemetry.io/contrib/instrumentation/github.com/gin-gonic/gin/otelgin/internal/semconvutil"
8+
package semconvutil
99

1010
import (
1111
"fmt"

instrumentation/github.com/gin-gonic/gin/otelgin/internal/semconvutil/netconv.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
// Copyright The OpenTelemetry Authors
55
// SPDX-License-Identifier: Apache-2.0
66

7-
package semconvutil // import "go.opentelemetry.io/contrib/instrumentation/github.com/gin-gonic/gin/otelgin/internal/semconvutil"
7+
package semconvutil // import "go.opentelemetry.io/contrib/internal/shared/semconvutil"
88

99
import (
1010
"net"

instrumentation/github.com/labstack/echo/otelecho/internal/semconv/httpconv.go

+7-3
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
// Copyright The OpenTelemetry Authors
55
// SPDX-License-Identifier: Apache-2.0
66

7+
// Package semconv provides OpenTelemetry semantic convention types and
8+
// functionality.
79
package semconv
810

911
import (
@@ -201,9 +203,11 @@ func (n CurrentHTTPServer) scheme(https bool) attribute.KeyValue { // nolint:rev
201203
return semconvNew.URLScheme("http")
202204
}
203205

204-
// ResponseTraceAttrs returns trace attributes for telemetry from an HTTP response.
206+
// ResponseTraceAttrs returns trace attributes for telemetry from an HTTP
207+
// response.
205208
//
206-
// If any of the fields in the ResponseTelemetry are not set the attribute will be omitted.
209+
// If any of the fields in the ResponseTelemetry are not set the attribute will
210+
// be omitted.
207211
func (n CurrentHTTPServer) ResponseTraceAttrs(resp ResponseTelemetry) []attribute.KeyValue {
208212
var count int
209213

@@ -547,7 +551,7 @@ func (n CurrentHTTPClient) MetricAttributes(req *http.Request, statusCode int, a
547551
return attributes
548552
}
549553

550-
// Attributes for httptrace.
554+
// TraceAttributes returns attributes for httptrace.
551555
func (n CurrentHTTPClient) TraceAttributes(host string) []attribute.KeyValue {
552556
return []attribute.KeyValue{
553557
semconvNew.ServerAddress(host),

instrumentation/github.com/labstack/echo/otelecho/internal/semconv/test/common_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -67,5 +67,5 @@ func testTraceRequest(t *testing.T, serv semconv.HTTPServer, want func(testServe
6767
clientIP: clientIP,
6868
}
6969

70-
assert.ElementsMatch(t, want(srvReq), serv.RequestTraceAttrs("", req))
70+
assert.ElementsMatch(t, want(srvReq), serv.RequestTraceAttrs("", req, semconv.RequestTraceAttrsOpts{}))
7171
}

instrumentation/github.com/labstack/echo/otelecho/internal/semconv/v1.20.0.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ func (o OldHTTPClient) createMeasures(meter metric.Meter) (metric.Int64Counter,
269269
return requestBytesCounter, responseBytesCounter, latencyMeasure
270270
}
271271

272-
// Attributes for httptrace.
272+
// TraceAttributes returns attributes for httptrace.
273273
func (c OldHTTPClient) TraceAttributes(host string) []attribute.KeyValue {
274274
return []attribute.KeyValue{
275275
semconv.NetHostName(host),

instrumentation/github.com/labstack/echo/otelecho/internal/semconvutil/httpconv.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
// SPDX-License-Identifier: Apache-2.0
66

77
// Package semconvutil provides OpenTelemetry semantic convention utilities.
8-
package semconvutil // import "go.opentelemetry.io/contrib/instrumentation/github.com/labstack/echo/otelecho/internal/semconvutil"
8+
package semconvutil
99

1010
import (
1111
"fmt"

instrumentation/github.com/labstack/echo/otelecho/internal/semconvutil/netconv.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
// Copyright The OpenTelemetry Authors
55
// SPDX-License-Identifier: Apache-2.0
66

7-
package semconvutil // import "go.opentelemetry.io/contrib/instrumentation/github.com/labstack/echo/otelecho/internal/semconvutil"
7+
package semconvutil // import "go.opentelemetry.io/contrib/internal/shared/semconvutil"
88

99
import (
1010
"net"

0 commit comments

Comments
 (0)