From 89a9489c570c3d7d724c73d11d2f228dc5f6f8cc Mon Sep 17 00:00:00 2001 From: Tyler Yahn Date: Mon, 9 Aug 2021 08:56:24 -0700 Subject: [PATCH 1/2] Add OC bridge internal unit tests (#2164) --- .../internal/oc2otel/attributes_test.go | 56 ++++ .../oc2otel/tracer_start_options_test.go | 52 ++++ bridge/opencensus/internal/span_test.go | 264 ++++++++++++++++++ bridge/opencensus/internal/tracer_test.go | 161 +++++++++++ 4 files changed, 533 insertions(+) create mode 100644 bridge/opencensus/internal/oc2otel/attributes_test.go create mode 100644 bridge/opencensus/internal/oc2otel/tracer_start_options_test.go create mode 100644 bridge/opencensus/internal/span_test.go create mode 100644 bridge/opencensus/internal/tracer_test.go diff --git a/bridge/opencensus/internal/oc2otel/attributes_test.go b/bridge/opencensus/internal/oc2otel/attributes_test.go new file mode 100644 index 00000000000..44d40ec899a --- /dev/null +++ b/bridge/opencensus/internal/oc2otel/attributes_test.go @@ -0,0 +1,56 @@ +// Copyright The OpenTelemetry Authors +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package oc2otel + +import ( + "testing" + + octrace "go.opencensus.io/trace" + + "go.opentelemetry.io/otel/attribute" +) + +func TestAttributes(t *testing.T) { + in := []octrace.Attribute{ + octrace.BoolAttribute("bool", true), + octrace.Int64Attribute("int64", 49), + octrace.Float64Attribute("float64", 1.618), + octrace.StringAttribute("key", "val"), + } + + want := []attribute.KeyValue{ + attribute.Bool("bool", true), + attribute.Int64("int64", 49), + attribute.Float64("float64", 1.618), + attribute.String("key", "val"), + } + got := Attributes(in) + + if len(got) != len(want) { + t.Errorf("Attributes conversion failed: want %#v, got %#v", want, got) + } + for i := range got { + if g, w := got[i], want[i]; g != w { + t.Errorf("Attributes conversion: want %#v, got %#v", w, g) + } + } +} + +func TestAttributeValueUnknown(t *testing.T) { + got := AttributeValue([]byte{}) + if got != attribute.StringValue("unknown") { + t.Errorf("AttributeValue of unknown wrong: %#v", got) + } +} diff --git a/bridge/opencensus/internal/oc2otel/tracer_start_options_test.go b/bridge/opencensus/internal/oc2otel/tracer_start_options_test.go new file mode 100644 index 00000000000..6a525424cab --- /dev/null +++ b/bridge/opencensus/internal/oc2otel/tracer_start_options_test.go @@ -0,0 +1,52 @@ +// Copyright The OpenTelemetry Authors +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package oc2otel + +import ( + "testing" + + octrace "go.opencensus.io/trace" + + "go.opentelemetry.io/otel/trace" +) + +func TestStartOptionsSpanKind(t *testing.T) { + conv := map[int]trace.SpanKind{ + octrace.SpanKindClient: trace.SpanKindClient, + octrace.SpanKindServer: trace.SpanKindServer, + octrace.SpanKindUnspecified: trace.SpanKindUnspecified, + } + + for oc, otel := range conv { + ocOpts := []octrace.StartOption{octrace.WithSpanKind(oc)} + otelOpts, err := StartOptions(ocOpts) + if err != nil { + t.Errorf("StartOptions errored: %v", err) + continue + } + c := trace.NewSpanStartConfig(otelOpts...) + if c.SpanKind() != otel { + t.Errorf("conversion of SpanKind start option: got %v, want %v", c.SpanKind(), otel) + } + } +} + +func TestStartOptionsSamplerErrors(t *testing.T) { + ocOpts := []octrace.StartOption{octrace.WithSampler(octrace.AlwaysSample())} + _, err := StartOptions(ocOpts) + if err == nil { + t.Error("StartOptions should error Sampler option") + } +} diff --git a/bridge/opencensus/internal/span_test.go b/bridge/opencensus/internal/span_test.go new file mode 100644 index 00000000000..b0771aad63c --- /dev/null +++ b/bridge/opencensus/internal/span_test.go @@ -0,0 +1,264 @@ +// Copyright The OpenTelemetry Authors +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package internal_test + +import ( + "testing" + + octrace "go.opencensus.io/trace" + + "go.opentelemetry.io/otel/attribute" + "go.opentelemetry.io/otel/bridge/opencensus/internal" + "go.opentelemetry.io/otel/bridge/opencensus/internal/oc2otel" + "go.opentelemetry.io/otel/bridge/opencensus/internal/otel2oc" + "go.opentelemetry.io/otel/codes" + "go.opentelemetry.io/otel/trace" +) + +type span struct { + trace.Span + + recording bool + ended bool + sc trace.SpanContext + name string + sCode codes.Code + sMsg string + attrs []attribute.KeyValue + eName string + eOpts []trace.EventOption +} + +func (s *span) IsRecording() bool { return s.recording } +func (s *span) End(...trace.SpanEndOption) { s.ended = true } +func (s *span) SpanContext() trace.SpanContext { return s.sc } +func (s *span) SetName(n string) { s.name = n } +func (s *span) SetStatus(c codes.Code, d string) { s.sCode, s.sMsg = c, d } +func (s *span) SetAttributes(a ...attribute.KeyValue) { s.attrs = a } +func (s *span) AddEvent(n string, o ...trace.EventOption) { s.eName, s.eOpts = n, o } + +func TestSpanIsRecordingEvents(t *testing.T) { + s := &span{recording: true} + ocS := internal.NewSpan(s) + if !ocS.IsRecordingEvents() { + t.Errorf("span.IsRecordingEvents() = false, want true") + } + s.recording = false + if ocS.IsRecordingEvents() { + t.Errorf("span.IsRecordingEvents() = true, want false") + } +} + +func TestSpanEnd(t *testing.T) { + s := new(span) + ocS := internal.NewSpan(s) + if s.ended { + t.Fatal("new span already ended") + } + + ocS.End() + if !s.ended { + t.Error("span.End() did not end OpenTelemetry span") + } +} + +func TestSpanSpanContext(t *testing.T) { + sc := trace.NewSpanContext(trace.SpanContextConfig{ + TraceID: [16]byte{1}, + SpanID: [8]byte{1}, + }) + // Do not test the conversion, only that the method is called. + converted := otel2oc.SpanContext(sc) + + s := &span{sc: sc} + ocS := internal.NewSpan(s) + if ocS.SpanContext() != converted { + t.Error("span.SpanContext did not use OpenTelemetry SpanContext") + } +} + +func TestSpanSetName(t *testing.T) { + // OpenCensus does not set a name if not recording. + s := &span{recording: true} + ocS := internal.NewSpan(s) + name := "test name" + ocS.SetName(name) + if s.name != name { + t.Error("span.SetName did not set OpenTelemetry span name") + } +} + +func TestSpanSetStatus(t *testing.T) { + // OpenCensus does not set a status if not recording. + s := &span{recording: true} + ocS := internal.NewSpan(s) + + c, d := codes.Error, "error" + status := octrace.Status{Code: int32(c), Message: d} + ocS.SetStatus(status) + + if s.sCode != c { + t.Error("span.SetStatus failed to set OpenTelemetry status code") + } + if s.sMsg != d { + t.Error("span.SetStatus failed to set OpenTelemetry status description") + } +} + +func TestSpanAddAttributes(t *testing.T) { + attrs := []octrace.Attribute{ + octrace.BoolAttribute("a", true), + } + // Do not test the conversion, only that the method is called. + converted := oc2otel.Attributes(attrs) + + // OpenCensus does not set attributes if not recording. + s := &span{recording: true} + ocS := internal.NewSpan(s) + ocS.AddAttributes(attrs...) + + if len(s.attrs) != len(converted) || s.attrs[0] != converted[0] { + t.Error("span.AddAttributes failed to set OpenTelemetry attributes") + } +} + +func TestSpanAnnotate(t *testing.T) { + name := "annotation" + attrs := []octrace.Attribute{ + octrace.BoolAttribute("a", true), + } + // Do not test the conversion, only that the method is called. + want := oc2otel.Attributes(attrs) + + // OpenCensus does not set events if not recording. + s := &span{recording: true} + ocS := internal.NewSpan(s) + ocS.Annotate(attrs, name) + + if s.eName != name { + t.Error("span.Annotate did not set event name") + } + + got := trace.NewEventConfig(s.eOpts...).Attributes() + if len(want) != len(got) || want[0] != got[0] { + t.Error("span.Annotate did not set event options") + } +} + +func TestSpanAnnotatef(t *testing.T) { + format := "annotation %s" + attrs := []octrace.Attribute{ + octrace.BoolAttribute("a", true), + } + // Do not test the conversion, only that the method is called. + want := oc2otel.Attributes(attrs) + + // OpenCensus does not set events if not recording. + s := &span{recording: true} + ocS := internal.NewSpan(s) + ocS.Annotatef(attrs, format, "a") + + if s.eName != "annotation a" { + t.Error("span.Annotatef did not set event name") + } + + got := trace.NewEventConfig(s.eOpts...).Attributes() + if len(want) != len(got) || want[0] != got[0] { + t.Error("span.Annotatef did not set event options") + } +} + +func TestSpanAddMessageSendEvent(t *testing.T) { + var u, c int64 = 1, 2 + + // OpenCensus does not set events if not recording. + s := &span{recording: true} + ocS := internal.NewSpan(s) + ocS.AddMessageSendEvent(0, u, c) + + if s.eName != internal.MessageSendEvent { + t.Error("span.AddMessageSendEvent did not set event name") + } + + got := trace.NewEventConfig(s.eOpts...).Attributes() + if len(got) != 2 { + t.Fatalf("span.AddMessageSendEvent set %d attributes, want 2", len(got)) + } + + want := attribute.KeyValue{Key: internal.UncompressedKey, Value: attribute.Int64Value(u)} + if got[0] != want { + t.Errorf("span.AddMessageSendEvent wrong uncompressed attribute: %v", got[0]) + } + + want = attribute.KeyValue{Key: internal.CompressedKey, Value: attribute.Int64Value(c)} + if got[1] != want { + t.Errorf("span.AddMessageSendEvent wrong compressed attribute: %v", got[1]) + } +} + +func TestSpanAddMessageReceiveEvent(t *testing.T) { + var u, c int64 = 3, 4 + + // OpenCensus does not set events if not recording. + s := &span{recording: true} + ocS := internal.NewSpan(s) + ocS.AddMessageReceiveEvent(0, u, c) + + if s.eName != internal.MessageReceiveEvent { + t.Error("span.AddMessageReceiveEvent did not set event name") + } + + got := trace.NewEventConfig(s.eOpts...).Attributes() + if len(got) != 2 { + t.Fatalf("span.AddMessageReceiveEvent set %d attributes, want 2", len(got)) + } + + want := attribute.KeyValue{Key: internal.UncompressedKey, Value: attribute.Int64Value(u)} + if got[0] != want { + t.Errorf("span.AddMessageReceiveEvent wrong uncompressed attribute: %v", got[0]) + } + + want = attribute.KeyValue{Key: internal.CompressedKey, Value: attribute.Int64Value(c)} + if got[1] != want { + t.Errorf("span.AddMessageReceiveEvent wrong compressed attribute: %v", got[1]) + } +} + +func TestSpanAddLinkFails(t *testing.T) { + h, restore := withHandler() + defer restore() + + // OpenCensus does not try to set links if not recording. + s := &span{recording: true} + ocS := internal.NewSpan(s) + ocS.AddLink(octrace.Link{}) + + if h.err == nil { + t.Error("span.AddLink failed to raise an error") + } +} + +func TestSpanString(t *testing.T) { + sc := trace.NewSpanContext(trace.SpanContextConfig{ + TraceID: [16]byte{1}, + SpanID: [8]byte{1}, + }) + + s := &span{sc: sc} + ocS := internal.NewSpan(s) + if expected := "span 0100000000000000"; ocS.String() != expected { + t.Errorf("span.String = %q, not %q", ocS.String(), expected) + } +} diff --git a/bridge/opencensus/internal/tracer_test.go b/bridge/opencensus/internal/tracer_test.go new file mode 100644 index 00000000000..1e3518a7efe --- /dev/null +++ b/bridge/opencensus/internal/tracer_test.go @@ -0,0 +1,161 @@ +// Copyright The OpenTelemetry Authors +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package internal_test + +import ( + "context" + "testing" + + octrace "go.opencensus.io/trace" + + "go.opentelemetry.io/otel/bridge/opencensus/internal" + "go.opentelemetry.io/otel/bridge/opencensus/internal/oc2otel" + "go.opentelemetry.io/otel/bridge/opencensus/internal/otel2oc" + "go.opentelemetry.io/otel/trace" +) + +type handler struct{ err error } + +func (h *handler) Handle(e error) { h.err = e } + +func withHandler() (*handler, func()) { + h := new(handler) + original := internal.Handle + internal.Handle = h.Handle + return h, func() { internal.Handle = original } +} + +type tracer struct { + ctx context.Context + name string + opts []trace.SpanStartOption +} + +func (t *tracer) Start(ctx context.Context, name string, opts ...trace.SpanStartOption) (context.Context, trace.Span) { + t.ctx, t.name, t.opts = ctx, name, opts + noop := trace.NewNoopTracerProvider().Tracer("testing") + return noop.Start(ctx, name, opts...) +} + +type ctxKey string + +func TestTracerStartSpan(t *testing.T) { + h, restore := withHandler() + defer restore() + + otelTracer := &tracer{} + ocTracer := internal.NewTracer(otelTracer) + + ctx := context.WithValue(context.Background(), ctxKey("key"), "value") + name := "testing span" + ocTracer.StartSpan(ctx, name, octrace.WithSpanKind(octrace.SpanKindClient)) + if h.err != nil { + t.Fatalf("OC tracer.StartSpan errored: %v", h.err) + } + + if otelTracer.ctx != ctx { + t.Error("OTel tracer.Start called with wrong context") + } + if otelTracer.name != name { + t.Error("OTel tracer.Start called with wrong name") + } + sk := trace.SpanKindClient + c := trace.NewSpanStartConfig(otelTracer.opts...) + if c.SpanKind() != sk { + t.Errorf("OTel tracer.Start called with wrong options: %#v", c) + } +} + +func TestTracerStartSpanReportsErrors(t *testing.T) { + h, restore := withHandler() + defer restore() + + ocTracer := internal.NewTracer(&tracer{}) + ocTracer.StartSpan(context.Background(), "", octrace.WithSampler(octrace.AlwaysSample())) + if h.err == nil { + t.Error("OC tracer.StartSpan no error when converting Sampler") + } +} + +func TestTracerStartSpanWithRemoteParent(t *testing.T) { + otelTracer := new(tracer) + ocTracer := internal.NewTracer(otelTracer) + sc := octrace.SpanContext{TraceID: [16]byte{1}, SpanID: [8]byte{1}} + converted := oc2otel.SpanContext(sc).WithRemote(true) + + ocTracer.StartSpanWithRemoteParent(context.Background(), "", sc) + + got := trace.SpanContextFromContext(otelTracer.ctx) + if !got.Equal(converted) { + t.Error("tracer.StartSpanWithRemoteParent failed to set remote parent") + } +} + +func TestTracerFromContext(t *testing.T) { + sc := trace.NewSpanContext(trace.SpanContextConfig{ + TraceID: [16]byte{1}, + SpanID: [8]byte{1}, + }) + ctx := trace.ContextWithSpanContext(context.Background(), sc) + + noop := trace.NewNoopTracerProvider().Tracer("TestTracerFromContext") + // Test using the fact that the No-Op span will propagate a span context . + ctx, _ = noop.Start(ctx, "test") + + got := internal.NewTracer(noop).FromContext(ctx).SpanContext() + // Do not test the convedsion, only that the propagtion. + want := otel2oc.SpanContext(sc) + if got != want { + t.Errorf("tracer.FromContext returned wrong context: %#v", got) + } +} + +func TestTracerNewContext(t *testing.T) { + sc := trace.NewSpanContext(trace.SpanContextConfig{ + TraceID: [16]byte{1}, + SpanID: [8]byte{1}, + }) + ctx := trace.ContextWithSpanContext(context.Background(), sc) + + noop := trace.NewNoopTracerProvider().Tracer("TestTracerNewContext") + // Test using the fact that the No-Op span will propagate a span context . + _, s := noop.Start(ctx, "test") + + ocTracer := internal.NewTracer(noop) + ctx = ocTracer.NewContext(context.Background(), internal.NewSpan(s)) + got := trace.SpanContextFromContext(ctx) + + if !got.Equal(sc) { + t.Error("tracer.NewContext did not attach Span to context") + } +} + +type differentSpan struct { + octrace.SpanInterface +} + +func (s *differentSpan) String() string { return "testing span" } + +func TestTracerNewContextErrors(t *testing.T) { + h, restore := withHandler() + defer restore() + + ocTracer := internal.NewTracer(&tracer{}) + ocSpan := octrace.NewSpan(&differentSpan{}) + ocTracer.NewContext(context.Background(), ocSpan) + if h.err == nil { + t.Error("tracer.NewContext did not error for unrecognized span") + } +} From b1d1d52959d2ef8ad93aa2d8f859adecafbee702 Mon Sep 17 00:00:00 2001 From: Tyler Yahn Date: Mon, 9 Aug 2021 09:24:43 -0700 Subject: [PATCH 2/2] Move OC bridge integration tests to own mod (#2165) Use the default SDK to test the OpenCensus bridge. In order to not add the SDK as a dependency to the bridge module and require users to depend on it if they use the bridge these tests are moved to a new dedicated test module. --- .github/dependabot.yml | 10 ++ bridge/opencensus/go.mod | 3 +- bridge/opencensus/{ => test}/bridge_test.go | 131 ++++++++++-------- bridge/opencensus/test/go.mod | 71 ++++++++++ bridge/opencensus/test/go.sum | 108 +++++++++++++++ bridge/opentracing/go.mod | 2 + example/jaeger/go.mod | 2 + example/namedtracer/go.mod | 2 + example/opencensus/go.mod | 2 + example/otel-collector/go.mod | 2 + example/passthrough/go.mod | 2 + example/prometheus/go.mod | 2 + example/zipkin/go.mod | 2 + exporters/jaeger/go.mod | 2 + exporters/otlp/otlpmetric/go.mod | 2 + .../otlp/otlpmetric/otlpmetricgrpc/go.mod | 2 + .../otlp/otlpmetric/otlpmetrichttp/go.mod | 2 + exporters/otlp/otlptrace/go.mod | 2 + exporters/otlp/otlptrace/otlptracegrpc/go.mod | 2 + exporters/otlp/otlptrace/otlptracehttp/go.mod | 2 + exporters/prometheus/go.mod | 2 + exporters/stdout/stdoutmetric/go.mod | 2 + exporters/stdout/stdouttrace/go.mod | 2 + exporters/zipkin/go.mod | 2 + go.mod | 2 + internal/metric/go.mod | 2 + internal/tools/go.mod | 2 + metric/go.mod | 2 + oteltest/go.mod | 2 + sdk/export/metric/go.mod | 2 + sdk/go.mod | 2 + sdk/metric/go.mod | 2 + trace/go.mod | 2 + 33 files changed, 319 insertions(+), 60 deletions(-) rename bridge/opencensus/{ => test}/bridge_test.go (63%) create mode 100644 bridge/opencensus/test/go.mod create mode 100644 bridge/opencensus/test/go.sum diff --git a/.github/dependabot.yml b/.github/dependabot.yml index a96d1f8ede0..1b2d8c0ce82 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -46,6 +46,16 @@ updates: schedule: day: sunday interval: weekly + - + package-ecosystem: gomod + directory: /bridge/opencensus/test + labels: + - dependencies + - go + - "Skip Changelog" + schedule: + day: sunday + interval: weekly - package-ecosystem: gomod directory: /example/prom-collector diff --git a/bridge/opencensus/go.mod b/bridge/opencensus/go.mod index 054159eae31..46983755edd 100644 --- a/bridge/opencensus/go.mod +++ b/bridge/opencensus/go.mod @@ -6,7 +6,6 @@ require ( go.opencensus.io v0.22.6-0.20201102222123-380f4078db9f go.opentelemetry.io/otel v1.0.0-RC2 go.opentelemetry.io/otel/metric v0.22.0 - go.opentelemetry.io/otel/oteltest v1.0.0-RC2 go.opentelemetry.io/otel/sdk v1.0.0-RC2 go.opentelemetry.io/otel/sdk/export/metric v0.22.0 go.opentelemetry.io/otel/trace v1.0.0-RC2 @@ -71,3 +70,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../exporter replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ./test diff --git a/bridge/opencensus/bridge_test.go b/bridge/opencensus/test/bridge_test.go similarity index 63% rename from bridge/opencensus/bridge_test.go rename to bridge/opencensus/test/bridge_test.go index 90c8c2e7a32..f1d5b8a8382 100644 --- a/bridge/opencensus/bridge_test.go +++ b/bridge/opencensus/test/bridge_test.go @@ -12,7 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. -package opencensus +package test import ( "context" @@ -21,18 +21,20 @@ import ( octrace "go.opencensus.io/trace" "go.opentelemetry.io/otel/attribute" + ocbridge "go.opentelemetry.io/otel/bridge/opencensus" "go.opentelemetry.io/otel/bridge/opencensus/internal" "go.opentelemetry.io/otel/bridge/opencensus/utils" "go.opentelemetry.io/otel/codes" - "go.opentelemetry.io/otel/oteltest" + sdktrace "go.opentelemetry.io/otel/sdk/trace" + "go.opentelemetry.io/otel/sdk/trace/tracetest" "go.opentelemetry.io/otel/trace" ) func TestMixedAPIs(t *testing.T) { - sr := new(oteltest.SpanRecorder) - tp := oteltest.NewTracerProvider(oteltest.WithSpanRecorder(sr)) + sr := tracetest.NewSpanRecorder() + tp := sdktrace.NewTracerProvider(sdktrace.WithSpanProcessor(sr)) tracer := tp.Tracer("mixedapitracer") - octrace.DefaultTracer = NewTracer(tracer) + octrace.DefaultTracer = ocbridge.NewTracer(tracer) func() { ctx := context.Background() @@ -53,7 +55,7 @@ func TestMixedAPIs(t *testing.T) { defer otspan2.End() }() - spans := sr.Completed() + spans := sr.Ended() if len(spans) != 4 { for _, span := range spans { @@ -62,28 +64,27 @@ func TestMixedAPIs(t *testing.T) { t.Fatalf("Got %d spans, exepected %d.", len(spans), 4) } - parent := &oteltest.Span{} - for i := range spans { - // Reverse the order we look at the spans in, since they are listed in last-to-first order. - i = len(spans) - i - 1 - // Verify that OpenCensus spans and opentelemetry spans have each other as parents. - if spans[i].ParentSpanID() != parent.SpanContext().SpanID() { - t.Errorf("Span %v had parent %v. Expected %d", spans[i].Name(), spans[i].ParentSpanID(), parent.SpanContext().SpanID()) + var parent trace.SpanContext + for i := len(spans) - 1; i >= 0; i-- { + // Verify that OpenCensus spans and OpenTelemetry spans have each + // other as parents. + if psid := spans[i].Parent().SpanID(); psid != parent.SpanID() { + t.Errorf("Span %v had parent %v. Expected %v", spans[i].Name(), psid, parent.SpanID()) } - parent = spans[i] + parent = spans[i].SpanContext() } } func TestStartOptions(t *testing.T) { - sr := new(oteltest.SpanRecorder) - tp := oteltest.NewTracerProvider(oteltest.WithSpanRecorder(sr)) - octrace.DefaultTracer = NewTracer(tp.Tracer("startoptionstracer")) + sr := tracetest.NewSpanRecorder() + tp := sdktrace.NewTracerProvider(sdktrace.WithSpanProcessor(sr)) + octrace.DefaultTracer = ocbridge.NewTracer(tp.Tracer("startoptionstracer")) ctx := context.Background() _, span := octrace.StartSpan(ctx, "OpenCensusSpan", octrace.WithSpanKind(octrace.SpanKindClient)) span.End() - spans := sr.Completed() + spans := sr.Ended() if len(spans) != 1 { t.Fatalf("Got %d spans, exepected %d", len(spans), 1) @@ -95,10 +96,10 @@ func TestStartOptions(t *testing.T) { } func TestStartSpanWithRemoteParent(t *testing.T) { - sr := new(oteltest.SpanRecorder) - tp := oteltest.NewTracerProvider(oteltest.WithSpanRecorder(sr)) + sr := tracetest.NewSpanRecorder() + tp := sdktrace.NewTracerProvider(sdktrace.WithSpanProcessor(sr)) tracer := tp.Tracer("remoteparent") - octrace.DefaultTracer = NewTracer(tracer) + octrace.DefaultTracer = ocbridge.NewTracer(tracer) ctx := context.Background() ctx, parent := tracer.Start(ctx, "OpenTelemetrySpan1") @@ -106,22 +107,22 @@ func TestStartSpanWithRemoteParent(t *testing.T) { _, span := octrace.StartSpanWithRemoteParent(ctx, "OpenCensusSpan", utils.OTelSpanContextToOC(parent.SpanContext())) span.End() - spans := sr.Completed() + spans := sr.Ended() if len(spans) != 1 { t.Fatalf("Got %d spans, exepected %d", len(spans), 1) } - if spans[0].ParentSpanID() != parent.SpanContext().SpanID() { - t.Errorf("Span %v, had parent %v. Expected %d", spans[0].Name(), spans[0].ParentSpanID(), parent.SpanContext().SpanID()) + if psid := spans[0].Parent().SpanID(); psid != parent.SpanContext().SpanID() { + t.Errorf("Span %v, had parent %v. Expected %d", spans[0].Name(), psid, parent.SpanContext().SpanID()) } } func TestToFromContext(t *testing.T) { - sr := new(oteltest.SpanRecorder) - tp := oteltest.NewTracerProvider(oteltest.WithSpanRecorder(sr)) + sr := tracetest.NewSpanRecorder() + tp := sdktrace.NewTracerProvider(sdktrace.WithSpanProcessor(sr)) tracer := tp.Tracer("tofromcontext") - octrace.DefaultTracer = NewTracer(tracer) + octrace.DefaultTracer = ocbridge.NewTracer(tracer) func() { ctx := context.Background() @@ -140,28 +141,27 @@ func TestToFromContext(t *testing.T) { }() - spans := sr.Completed() + spans := sr.Ended() if len(spans) != 2 { t.Fatalf("Got %d spans, exepected %d.", len(spans), 2) } - parent := &oteltest.Span{} - for i := range spans { - // Reverse the order we look at the spans in, since they are listed in last-to-first order. - i = len(spans) - i - 1 - // Verify that OpenCensus spans and opentelemetry spans have each other as parents. - if spans[i].ParentSpanID() != parent.SpanContext().SpanID() { - t.Errorf("Span %v had parent %v. Expected %d", spans[i].Name(), spans[i].ParentSpanID(), parent.SpanContext().SpanID()) + var parent trace.SpanContext + for i := len(spans) - 1; i >= 0; i-- { + // Verify that OpenCensus spans and OpenTelemetry spans have each + // other as parents. + if psid := spans[i].Parent().SpanID(); psid != parent.SpanID() { + t.Errorf("Span %v had parent %v. Expected %v", spans[i].Name(), psid, parent.SpanID()) } - parent = spans[i] + parent = spans[i].SpanContext() } } func TestIsRecordingEvents(t *testing.T) { - sr := new(oteltest.SpanRecorder) - tp := oteltest.NewTracerProvider(oteltest.WithSpanRecorder(sr)) - octrace.DefaultTracer = NewTracer(tp.Tracer("isrecordingevents")) + sr := tracetest.NewSpanRecorder() + tp := sdktrace.NewTracerProvider(sdktrace.WithSpanProcessor(sr)) + octrace.DefaultTracer = ocbridge.NewTracer(tp.Tracer("isrecordingevents")) ctx := context.Background() _, ocspan := octrace.StartSpan(ctx, "OpenCensusSpan1") @@ -170,10 +170,18 @@ func TestIsRecordingEvents(t *testing.T) { } } +func attrsMap(s []attribute.KeyValue) map[attribute.Key]attribute.Value { + m := make(map[attribute.Key]attribute.Value, len(s)) + for _, a := range s { + m[a.Key] = a.Value + } + return m +} + func TestSetThings(t *testing.T) { - sr := new(oteltest.SpanRecorder) - tp := oteltest.NewTracerProvider(oteltest.WithSpanRecorder(sr)) - octrace.DefaultTracer = NewTracer(tp.Tracer("setthings")) + sr := tracetest.NewSpanRecorder() + tp := sdktrace.NewTracerProvider(sdktrace.WithSpanProcessor(sr)) + octrace.DefaultTracer = ocbridge.NewTracer(tp.Tracer("setthings")) ctx := context.Background() _, ocspan := octrace.StartSpan(ctx, "OpenCensusSpan1") @@ -200,7 +208,7 @@ func TestSetThings(t *testing.T) { ocspan.AddMessageReceiveEvent(246, 135, 369) ocspan.End() - spans := sr.Completed() + spans := sr.Ended() if len(spans) != 1 { t.Fatalf("Got %d spans, exepected %d.", len(spans), 1) @@ -211,24 +219,25 @@ func TestSetThings(t *testing.T) { t.Errorf("Got name %v, expected span-foo", s.Name()) } - if s.StatusCode().String() != codes.Error.String() { - t.Errorf("Got code %v, expected 1", s.StatusCode().String()) + if s.Status().Code != codes.Error { + t.Errorf("Got code %v, expected %v", s.Status().Code, codes.Error) } - if s.StatusMessage() != "foo" { - t.Errorf("Got code %v, expected foo", s.StatusMessage()) + if s.Status().Description != "foo" { + t.Errorf("Got code %v, expected foo", s.Status().Description) } - if v := s.Attributes()[attribute.Key("bool")]; !v.AsBool() { + attrs := attrsMap(s.Attributes()) + if v := attrs[attribute.Key("bool")]; !v.AsBool() { t.Errorf("Got attributes[bool] %v, expected true", v.AsBool()) } - if v := s.Attributes()[attribute.Key("int64")]; v.AsInt64() != 12345 { + if v := attrs[attribute.Key("int64")]; v.AsInt64() != 12345 { t.Errorf("Got attributes[int64] %v, expected 12345", v.AsInt64()) } - if v := s.Attributes()[attribute.Key("float64")]; v.AsFloat64() != 12.345 { + if v := attrs[attribute.Key("float64")]; v.AsFloat64() != 12.345 { t.Errorf("Got attributes[float64] %v, expected 12.345", v.AsFloat64()) } - if v := s.Attributes()[attribute.Key("string")]; v.AsString() != "stringval" { + if v := attrs[attribute.Key("string")]; v.AsString() != "stringval" { t.Errorf("Got attributes[string] %v, expected stringval", v.AsString()) } @@ -236,43 +245,47 @@ func TestSetThings(t *testing.T) { t.Fatalf("Got len(events) = %v, expected 4", len(s.Events())) } annotateEvent := s.Events()[0] + aeAttrs := attrsMap(annotateEvent.Attributes) annotatefEvent := s.Events()[1] + afeAttrs := attrsMap(annotatefEvent.Attributes) sendEvent := s.Events()[2] receiveEvent := s.Events()[3] - if v := annotateEvent.Attributes[attribute.Key("string")]; v.AsString() != "annotateval" { + if v := aeAttrs[attribute.Key("string")]; v.AsString() != "annotateval" { t.Errorf("Got annotateEvent.Attributes[string] = %v, expected annotateval", v.AsString()) } if annotateEvent.Name != "annotate" { t.Errorf("Got annotateEvent.Name = %v, expected annotate", annotateEvent.Name) } - if v := annotatefEvent.Attributes[attribute.Key("int64")]; v.AsInt64() != 12345 { + if v := afeAttrs[attribute.Key("int64")]; v.AsInt64() != 12345 { t.Errorf("Got annotatefEvent.Attributes[int64] = %v, expected 12345", v.AsInt64()) } - if v := annotatefEvent.Attributes[attribute.Key("float64")]; v.AsFloat64() != 12.345 { + if v := afeAttrs[attribute.Key("float64")]; v.AsFloat64() != 12.345 { t.Errorf("Got annotatefEvent.Attributes[float64] = %v, expected 12.345", v.AsFloat64()) } if annotatefEvent.Name != "annotate67890" { t.Errorf("Got annotatefEvent.Name = %v, expected annotate67890", annotatefEvent.Name) } - if v := annotateEvent.Attributes[attribute.Key("string")]; v.AsString() != "annotateval" { + if v := aeAttrs[attribute.Key("string")]; v.AsString() != "annotateval" { t.Errorf("Got annotateEvent.Attributes[string] = %v, expected annotateval", v.AsString()) } + seAttrs := attrsMap(sendEvent.Attributes) + reAttrs := attrsMap(receiveEvent.Attributes) if sendEvent.Name != internal.MessageSendEvent { t.Errorf("Got sendEvent.Name = %v, expected message send", sendEvent.Name) } - if v := sendEvent.Attributes[internal.UncompressedKey]; v.AsInt64() != 456 { + if v := seAttrs[internal.UncompressedKey]; v.AsInt64() != 456 { t.Errorf("Got sendEvent.Attributes[uncompressedKey] = %v, expected 456", v.AsInt64()) } - if v := sendEvent.Attributes[internal.CompressedKey]; v.AsInt64() != 789 { + if v := seAttrs[internal.CompressedKey]; v.AsInt64() != 789 { t.Errorf("Got sendEvent.Attributes[compressedKey] = %v, expected 789", v.AsInt64()) } if receiveEvent.Name != internal.MessageReceiveEvent { t.Errorf("Got receiveEvent.Name = %v, expected message receive", receiveEvent.Name) } - if v := receiveEvent.Attributes[internal.UncompressedKey]; v.AsInt64() != 135 { + if v := reAttrs[internal.UncompressedKey]; v.AsInt64() != 135 { t.Errorf("Got receiveEvent.Attributes[uncompressedKey] = %v, expected 135", v.AsInt64()) } - if v := receiveEvent.Attributes[internal.CompressedKey]; v.AsInt64() != 369 { + if v := reAttrs[internal.CompressedKey]; v.AsInt64() != 369 { t.Errorf("Got receiveEvent.Attributes[compressedKey] = %v, expected 369", v.AsInt64()) } } diff --git a/bridge/opencensus/test/go.mod b/bridge/opencensus/test/go.mod new file mode 100644 index 00000000000..24f96a36f03 --- /dev/null +++ b/bridge/opencensus/test/go.mod @@ -0,0 +1,71 @@ +module go.opentelemetry.io/otel/bridge/opencensus/test + +go 1.15 + +require ( + go.opencensus.io v0.23.0 + go.opentelemetry.io/otel v1.0.0-RC2 + go.opentelemetry.io/otel/bridge/opencensus v0.21.0 + go.opentelemetry.io/otel/sdk v1.0.0-RC2 + go.opentelemetry.io/otel/trace v1.0.0-RC2 +) + +replace go.opentelemetry.io/otel => ../../.. + +replace go.opentelemetry.io/otel/bridge/opencensus => ../ + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ./ + +replace go.opentelemetry.io/otel/bridge/opentracing => ../../opentracing + +replace go.opentelemetry.io/otel/example/jaeger => ../../../example/jaeger + +replace go.opentelemetry.io/otel/example/namedtracer => ../../../example/namedtracer + +replace go.opentelemetry.io/otel/example/opencensus => ../../../example/opencensus + +replace go.opentelemetry.io/otel/example/otel-collector => ../../../example/otel-collector + +replace go.opentelemetry.io/otel/example/passthrough => ../../../example/passthrough + +replace go.opentelemetry.io/otel/example/prometheus => ../../../example/prometheus + +replace go.opentelemetry.io/otel/example/zipkin => ../../../example/zipkin + +replace go.opentelemetry.io/otel/exporters/jaeger => ../../../exporters/jaeger + +replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric => ../../../exporters/otlp/otlpmetric + +replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc => ../../../exporters/otlp/otlpmetric/otlpmetricgrpc + +replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/exporters/otlp/otlptrace => ../../../exporters/otlp/otlptrace + +replace go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc => ../../../exporters/otlp/otlptrace/otlptracegrpc + +replace go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp => ../../../exporters/otlp/otlptrace/otlptracehttp + +replace go.opentelemetry.io/otel/exporters/prometheus => ../../../exporters/prometheus + +replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../../exporters/stdout/stdoutmetric + +replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../../exporters/stdout/stdouttrace + +replace go.opentelemetry.io/otel/exporters/zipkin => ../../../exporters/zipkin + +replace go.opentelemetry.io/otel/internal/metric => ../../../internal/metric + +replace go.opentelemetry.io/otel/internal/tools => ../../../internal/tools + +replace go.opentelemetry.io/otel/metric => ../../../metric + +replace go.opentelemetry.io/otel/oteltest => ../../../oteltest + +replace go.opentelemetry.io/otel/sdk => ../../../sdk + +replace go.opentelemetry.io/otel/sdk/export/metric => ../../../sdk/export/metric + +replace go.opentelemetry.io/otel/sdk/metric => ../../../sdk/metric + +replace go.opentelemetry.io/otel/trace => ../../../trace diff --git a/bridge/opencensus/test/go.sum b/bridge/opencensus/test/go.sum new file mode 100644 index 00000000000..9cb1b023e7f --- /dev/null +++ b/bridge/opencensus/test/go.sum @@ -0,0 +1,108 @@ +cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= +github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= +github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= +github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= +github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= +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/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= +github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= +github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= +github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= +github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= +github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= +github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e h1:1r7pUrabqp18hOBcwBwiTsbnFeTZHV9eER/QT5JVZxY= +github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= +github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= +github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= +github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= +github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= +github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8= +github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA= +github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= +github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= +github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= +github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QDs8UjoX8= +github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= +github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= +github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= +github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= +github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.3/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/go-cmp v0.5.6 h1:BKbKCqvP6I+rmFHt06ZmyQtvB8xAkWdhFyr0ZUNZcxQ= +github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= +github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= +github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= +github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= +github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= +github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= +github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= +github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY= +github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= +go.opencensus.io v0.22.6-0.20201102222123-380f4078db9f/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= +go.opencensus.io v0.23.0 h1:gqCw0LfLxScz8irSi8exQc7fyQ0fKQU/qnC/X8+V/1M= +go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= +golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= +golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= +golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= +golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= +golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= +golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= +golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20201110031124-69a78807bb2b/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= +golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= +golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7 h1:iGu644GcxtEcrInvDsQRCwJjtCIOlT2V7IRt6ah2Whw= +golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= +golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= +golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= +golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= +golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= +golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= +golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= +google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= +google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= +google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= +google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= +google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= +google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= +google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= +google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= +google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY= +google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= +google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv2fbc= +google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= +google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= +google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= +google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE= +google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo= +google.golang.org/protobuf v1.22.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= +google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= +google.golang.org/protobuf v1.23.1-0.20200526195155-81db48ad09cc/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= +google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c= +gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM= +gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c h1:dUUwHk2QECo/6vqA44rthZ8ie2QXMNeKRTHCNY2nXvo= +gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= +honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= diff --git a/bridge/opentracing/go.mod b/bridge/opentracing/go.mod index f57d23a896f..e623cf8c29d 100644 --- a/bridge/opentracing/go.mod +++ b/bridge/opentracing/go.mod @@ -67,3 +67,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../exporter replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../opencensus/test diff --git a/example/jaeger/go.mod b/example/jaeger/go.mod index ee5a0459aa3..a2646dcaae7 100644 --- a/example/jaeger/go.mod +++ b/example/jaeger/go.mod @@ -67,3 +67,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../exporter replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../bridge/opencensus/test diff --git a/example/namedtracer/go.mod b/example/namedtracer/go.mod index b942edf274c..a8cfd6783f1 100644 --- a/example/namedtracer/go.mod +++ b/example/namedtracer/go.mod @@ -69,3 +69,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../exporter replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../bridge/opencensus/test diff --git a/example/opencensus/go.mod b/example/opencensus/go.mod index 8767ee83b6e..2934f5753c0 100644 --- a/example/opencensus/go.mod +++ b/example/opencensus/go.mod @@ -71,3 +71,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../exporter replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../bridge/opencensus/test diff --git a/example/otel-collector/go.mod b/example/otel-collector/go.mod index d39e9955ba4..a2a4be851ad 100644 --- a/example/otel-collector/go.mod +++ b/example/otel-collector/go.mod @@ -70,3 +70,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../exporter replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../bridge/opencensus/test diff --git a/example/passthrough/go.mod b/example/passthrough/go.mod index 394942f2958..59071d08ae3 100644 --- a/example/passthrough/go.mod +++ b/example/passthrough/go.mod @@ -70,3 +70,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../exporter replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../bridge/opencensus/test diff --git a/example/prometheus/go.mod b/example/prometheus/go.mod index e776eabcfcb..05bfb72e3c7 100644 --- a/example/prometheus/go.mod +++ b/example/prometheus/go.mod @@ -69,3 +69,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../exporter replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../bridge/opencensus/test diff --git a/example/zipkin/go.mod b/example/zipkin/go.mod index 85215c8b289..0ca2cea1e54 100644 --- a/example/zipkin/go.mod +++ b/example/zipkin/go.mod @@ -68,3 +68,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../exporter replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../bridge/opencensus/test diff --git a/exporters/jaeger/go.mod b/exporters/jaeger/go.mod index c547bae5ba3..b0c78c8352f 100644 --- a/exporters/jaeger/go.mod +++ b/exporters/jaeger/go.mod @@ -71,3 +71,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../stdout/stdo replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../bridge/opencensus/test diff --git a/exporters/otlp/otlpmetric/go.mod b/exporters/otlp/otlpmetric/go.mod index 86e021fa696..1c0045dd64c 100644 --- a/exporters/otlp/otlpmetric/go.mod +++ b/exporters/otlp/otlpmetric/go.mod @@ -77,3 +77,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../stdout/s replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ./otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../../bridge/opencensus/test diff --git a/exporters/otlp/otlpmetric/otlpmetricgrpc/go.mod b/exporters/otlp/otlpmetric/otlpmetricgrpc/go.mod index d43b19b1530..c24301c0335 100644 --- a/exporters/otlp/otlpmetric/otlpmetricgrpc/go.mod +++ b/exporters/otlp/otlpmetric/otlpmetricgrpc/go.mod @@ -75,3 +75,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../../stdou replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../../stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../../../bridge/opencensus/test diff --git a/exporters/otlp/otlpmetric/otlpmetrichttp/go.mod b/exporters/otlp/otlpmetric/otlpmetrichttp/go.mod index 1c70f44776e..61340430ba1 100644 --- a/exporters/otlp/otlpmetric/otlpmetrichttp/go.mod +++ b/exporters/otlp/otlpmetric/otlpmetrichttp/go.mod @@ -77,3 +77,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../../stdou replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../../stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc => ../otlpmetricgrpc + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../../../bridge/opencensus/test diff --git a/exporters/otlp/otlptrace/go.mod b/exporters/otlp/otlptrace/go.mod index a36b6611705..7741f7b2ede 100644 --- a/exporters/otlp/otlptrace/go.mod +++ b/exporters/otlp/otlptrace/go.mod @@ -74,3 +74,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../stdout/s replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../../bridge/opencensus/test diff --git a/exporters/otlp/otlptrace/otlptracegrpc/go.mod b/exporters/otlp/otlptrace/otlptracegrpc/go.mod index 2a93bfd6d75..825eb26b02a 100644 --- a/exporters/otlp/otlptrace/otlptracegrpc/go.mod +++ b/exporters/otlp/otlptrace/otlptracegrpc/go.mod @@ -70,3 +70,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../../stdou replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../../stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../../../bridge/opencensus/test diff --git a/exporters/otlp/otlptrace/otlptracehttp/go.mod b/exporters/otlp/otlptrace/otlptracehttp/go.mod index 19e7b51f1dc..ec13eb8d084 100644 --- a/exporters/otlp/otlptrace/otlptracehttp/go.mod +++ b/exporters/otlp/otlptrace/otlptracehttp/go.mod @@ -68,3 +68,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../../stdou replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../../stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../../../bridge/opencensus/test diff --git a/exporters/prometheus/go.mod b/exporters/prometheus/go.mod index d25f482f1d1..9fc8b739312 100644 --- a/exporters/prometheus/go.mod +++ b/exporters/prometheus/go.mod @@ -73,3 +73,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../stdout/stdo replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../bridge/opencensus/test diff --git a/exporters/stdout/stdoutmetric/go.mod b/exporters/stdout/stdoutmetric/go.mod index a832ad6a02e..49c47ae9115 100644 --- a/exporters/stdout/stdoutmetric/go.mod +++ b/exporters/stdout/stdoutmetric/go.mod @@ -71,3 +71,5 @@ replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc => ../ replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../../bridge/opencensus/test diff --git a/exporters/stdout/stdouttrace/go.mod b/exporters/stdout/stdouttrace/go.mod index 8614c481647..07a5626a71c 100644 --- a/exporters/stdout/stdouttrace/go.mod +++ b/exporters/stdout/stdouttrace/go.mod @@ -69,3 +69,5 @@ replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc => ../ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../stdoutmetric replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../../bridge/opencensus/test diff --git a/exporters/zipkin/go.mod b/exporters/zipkin/go.mod index 15db8639a33..45d5f064862 100644 --- a/exporters/zipkin/go.mod +++ b/exporters/zipkin/go.mod @@ -72,3 +72,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../stdout/stdo replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../bridge/opencensus/test diff --git a/go.mod b/go.mod index e2bc6d30a2f..0a9e1a9eaf0 100644 --- a/go.mod +++ b/go.mod @@ -67,3 +67,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ./exporters/st replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ./exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ./exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ./bridge/opencensus/test diff --git a/internal/metric/go.mod b/internal/metric/go.mod index fc3a9dc9600..45a121a7181 100644 --- a/internal/metric/go.mod +++ b/internal/metric/go.mod @@ -67,3 +67,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../exporter replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../bridge/opencensus/test diff --git a/internal/tools/go.mod b/internal/tools/go.mod index 10b4ae5b381..ec7626c9e01 100644 --- a/internal/tools/go.mod +++ b/internal/tools/go.mod @@ -70,3 +70,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../exporter replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../bridge/opencensus/test diff --git a/metric/go.mod b/metric/go.mod index a310d7b0b5a..f8fcf1e7833 100644 --- a/metric/go.mod +++ b/metric/go.mod @@ -68,3 +68,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../exporters/s replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../bridge/opencensus/test diff --git a/oteltest/go.mod b/oteltest/go.mod index 830f9e2ea6b..29dc60a1bad 100644 --- a/oteltest/go.mod +++ b/oteltest/go.mod @@ -67,3 +67,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../exporters/s replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../bridge/opencensus/test diff --git a/sdk/export/metric/go.mod b/sdk/export/metric/go.mod index c5e1e6aeb41..21b5b47bf38 100644 --- a/sdk/export/metric/go.mod +++ b/sdk/export/metric/go.mod @@ -68,3 +68,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../../expor replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../../bridge/opencensus/test diff --git a/sdk/go.mod b/sdk/go.mod index 05fa75ade69..bca9816cc52 100644 --- a/sdk/go.mod +++ b/sdk/go.mod @@ -69,3 +69,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../exporters/s replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../bridge/opencensus/test diff --git a/sdk/metric/go.mod b/sdk/metric/go.mod index 76ec1de69ed..c085602e07c 100644 --- a/sdk/metric/go.mod +++ b/sdk/metric/go.mod @@ -71,3 +71,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../../exporter replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../../bridge/opencensus/test diff --git a/trace/go.mod b/trace/go.mod index 1907de16a78..08a79eeeecf 100644 --- a/trace/go.mod +++ b/trace/go.mod @@ -67,3 +67,5 @@ replace go.opentelemetry.io/otel/exporters/stdout/stdoutmetric => ../exporters/s replace go.opentelemetry.io/otel/exporters/stdout/stdouttrace => ../exporters/stdout/stdouttrace replace go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetrichttp => ../exporters/otlp/otlpmetric/otlpmetrichttp + +replace go.opentelemetry.io/otel/bridge/opencensus/test => ../bridge/opencensus/test