Skip to content

Commit a7223ba

Browse files
committed
Stack otelhttp into the AWS transport too
Hmm. Let's see what this does.
1 parent 3e36e85 commit a7223ba

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

internal/awsconfig/awsconfig.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ import (
1616
"github.com/aws/aws-sdk-go-v2/aws/retry"
1717
"github.com/aws/aws-sdk-go-v2/config"
1818
"go.opentelemetry.io/contrib/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws"
19+
"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp"
1920
)
2021

2122
const (
@@ -46,7 +47,7 @@ func New(ctx context.Context) (aws.Config, error) {
4647
cfg, err := config.LoadDefaultConfig(ctx,
4748
config.WithHTTPClient(&http.Client{
4849
Timeout: DefaultTimeout,
49-
Transport: transport,
50+
Transport: otelhttp.NewTransport(transport),
5051
}),
5152
config.WithRetryer(
5253
func() aws.Retryer {

0 commit comments

Comments
 (0)