Skip to content

Commit

Permalink
Merge branch 'main' into dependabot/go_modules/detectors/gcp/cloud.go…
Browse files Browse the repository at this point in the history
…ogle.com/go-0.83.0
  • Loading branch information
MrAlias authored Jun 7, 2021
2 parents 20a33ab + 6e5bea2 commit 7c2086b
Show file tree
Hide file tree
Showing 20 changed files with 17 additions and 49 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm

## [Unreleased]

### Fixed

- Dockerfile based examples for `otelgin` and `otelmacaron`. (#767)

### Changed

- Supported minimum version of Go bumped from 1.14 to 1.15. (#787)
Expand Down
2 changes: 1 addition & 1 deletion detectors/aws/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module go.opentelemetry.io/contrib/detectors/aws
go 1.15

require (
github.com/aws/aws-sdk-go v1.38.51
github.com/aws/aws-sdk-go v1.38.55
github.com/stretchr/testify v1.7.0
go.opentelemetry.io/otel v0.20.0
go.opentelemetry.io/otel/sdk v0.20.0
Expand Down
4 changes: 2 additions & 2 deletions detectors/aws/go.sum
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
github.com/aws/aws-sdk-go v1.38.51 h1:aKQmbVbwOCuQSd8+fm/MR3bq0QOsu9Q7S+/QEND36oQ=
github.com/aws/aws-sdk-go v1.38.51/go.mod h1:hcU610XS61/+aQV88ixoOzUoG7v3b31pl2zKMmprdro=
github.com/aws/aws-sdk-go v1.38.55 h1:1Wv5CE1Zy0hJ6MJUQ1ekFiCsNKBK5W69+towYQ1P4Vs=
github.com/aws/aws-sdk-go v1.38.55/go.mod h1:hcU610XS61/+aQV88ixoOzUoG7v3b31pl2zKMmprdro=
github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8=
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/google/go-cmp v0.5.5 h1:Khx7svrCpmxxtHBq5j2mp/xVjsi8hQMfNLvJFAlrGgU=
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,6 @@ func InitTracer() {
sdktrace.WithSampler(sdktrace.AlwaysSample()),
sdktrace.WithSyncer(exporter),
)
if err != nil {
log.Fatal(err)
}
otel.SetTracerProvider(tp)
otel.SetTextMapPropagator(propagation.NewCompositeTextMapPropagator(propagation.TraceContext{}))
}
Original file line number Diff line number Diff line change
Expand Up @@ -63,9 +63,6 @@ func initTracer() {
sdktrace.WithSampler(sdktrace.AlwaysSample()),
sdktrace.WithSyncer(exporter),
sdktrace.WithResource(resource.NewWithAttributes(semconv.ServiceNameKey.String("ExampleService"))))
if err != nil {
log.Fatal(err)
}
otel.SetTracerProvider(tp)
otel.SetTextMapPropagator(propagation.NewCompositeTextMapPropagator(propagation.TraceContext{}, propagation.Baggage{}))
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.
FROM golang:1.15-alpine AS base
COPY . /src/
WORKDIR /src/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws
WORKDIR /src/instrumentation/github.com/aws/aws-sdk-go-v2/otelaws/example

FROM base AS aws-client
RUN go install ./example/main.go
RUN go install ./main.go
CMD ["/go/bin/main"]
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.
FROM golang:1.15-alpine AS base
COPY . /src/
WORKDIR /src/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache
WORKDIR /src/instrumentation/github.com/bradfitz/gomemcache/memcache/otelmemcache/example

FROM base AS memcache-client
RUN go install ./example/client.go
RUN go install ./client.go
CMD ["/go/bin/client"]
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,6 @@ func initTracer() oteltrace.TracerProvider {
sdktrace.WithSampler(sdktrace.AlwaysSample()),
sdktrace.WithSyncer(exporter),
)
if err != nil {
log.Fatal(err)
}

return tp
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.
FROM golang:1.15-alpine AS base
COPY . /src/
WORKDIR /src/instrumentation/github.com/emicklei/go-restful/otelrestful
WORKDIR /src/instrumentation/github.com/emicklei/go-restful/otelrestful/example

FROM base AS go-restful-server
RUN go install ./example/server.go
RUN go install ./server.go
CMD ["/go/bin/server"]
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,6 @@ func initTracer() {
sdktrace.WithSampler(sdktrace.AlwaysSample()),
sdktrace.WithSyncer(exporter),
)
if err != nil {
log.Fatal(err)
}
otel.SetTracerProvider(tp)
tracer = otel.GetTracerProvider().Tracer("go-restful-server", oteltrace.WithInstrumentationVersion("0.1"))
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.
FROM golang:alpine AS base
COPY . /src/
WORKDIR /src/instrumentation/github.com/gin-gonic/gin/otelgin
WORKDIR /src/instrumentation/github.com/gin-gonic/gin/otelgin/example

FROM base AS gin-server
RUN go install ./example/server.go
RUN go install ./server.go
CMD ["/go/bin/server"]
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,6 @@ func initTracer() {
sdktrace.WithSampler(sdktrace.AlwaysSample()),
sdktrace.WithSyncer(exporter),
)
if err != nil {
log.Fatal(err)
}
otel.SetTracerProvider(tp)
otel.SetTextMapPropagator(propagation.NewCompositeTextMapPropagator(propagation.TraceContext{}, propagation.Baggage{}))
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,6 @@ func initTracer() {
sdktrace.WithSampler(sdktrace.AlwaysSample()),
sdktrace.WithSyncer(exporter),
)
if err != nil {
log.Fatal(err)
}
otel.SetTracerProvider(tp)
otel.SetTextMapPropagator(propagation.NewCompositeTextMapPropagator(propagation.TraceContext{}, propagation.Baggage{}))
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,6 @@ func Init() {
sdktrace.WithSampler(sdktrace.AlwaysSample()),
sdktrace.WithSyncer(exporter),
)
if err != nil {
log.Fatal(err)
}
otel.SetTracerProvider(tp)
otel.SetTextMapPropagator(propagation.NewCompositeTextMapPropagator(propagation.TraceContext{}, propagation.Baggage{}))
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
# limitations under the License.
FROM golang:alpine AS base
COPY . /src/
WORKDIR /src/instrumentation/gopkg.in/macaron.v1/otelmacaron
WORKDIR /src/instrumentation/gopkg.in/macaron.v1/otelmacaron/example

FROM base AS macaron-server
RUN go install ./example/server.go
RUN go install ./server.go
CMD ["/go/bin/server"]
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,6 @@ func initTracer() {
sdktrace.WithSampler(sdktrace.AlwaysSample()),
sdktrace.WithSyncer(exporter),
)
if err != nil {
log.Fatal(err)
}
otel.SetTracerProvider(tp)
otel.SetTextMapPropagator(propagation.NewCompositeTextMapPropagator(propagation.TraceContext{}, propagation.Baggage{}))
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,6 @@ func initTracer() {
sdktrace.WithSampler(sdktrace.AlwaysSample()),
sdktrace.WithSyncer(exporter),
)
if err != nil {
log.Fatal(err)
}
otel.SetTracerProvider(tp)
otel.SetTextMapPropagator(propagation.NewCompositeTextMapPropagator(propagation.TraceContext{}, propagation.Baggage{}))
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,6 @@ func initTracer() {
sdktrace.WithSyncer(exporter),
sdktrace.WithResource(resource.NewWithAttributes(semconv.ServiceNameKey.String("ExampleService"))),
)
if err != nil {
log.Fatal(err)
}
otel.SetTracerProvider(tp)
otel.SetTextMapPropagator(propagation.NewCompositeTextMapPropagator(propagation.TraceContext{}, propagation.Baggage{}))
}
Expand Down
3 changes: 0 additions & 3 deletions instrumentation/net/http/otelhttp/example/client/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,6 @@ func initTracer() {
sdktrace.WithSampler(sdktrace.AlwaysSample()),
sdktrace.WithSyncer(exporter),
)
if err != nil {
log.Fatal(err)
}
otel.SetTracerProvider(tp)
otel.SetTextMapPropagator(propagation.NewCompositeTextMapPropagator(propagation.TraceContext{}, propagation.Baggage{}))
}
Expand Down
3 changes: 0 additions & 3 deletions instrumentation/net/http/otelhttp/example/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,6 @@ func initTracer() {
sdktrace.WithSyncer(exporter),
sdktrace.WithResource(resource.NewWithAttributes(semconv.ServiceNameKey.String("ExampleService"))),
)
if err != nil {
log.Fatal(err)
}
otel.SetTracerProvider(tp)
otel.SetTextMapPropagator(propagation.NewCompositeTextMapPropagator(propagation.TraceContext{}, propagation.Baggage{}))
}
Expand Down

0 comments on commit 7c2086b

Please sign in to comment.