diff --git a/internal/filter/filterottl/bridge.go b/internal/filter/filterottl/bridge.go index 1bd8893c77ef..7261e63be563 100644 --- a/internal/filter/filterottl/bridge.go +++ b/internal/filter/filterottl/bridge.go @@ -1,16 +1,5 @@ // 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. +// SPDX-License-Identifier: Apache-2.0 package filterottl // import "github.com/open-telemetry/opentelemetry-collector-contrib/internal/filter/filterottl" @@ -31,7 +20,7 @@ import ( const ( serviceNameStaticStatement = `resource.attributes["service.name"] == "%v"` spanNameStaticStatement = `name == "%v"` - spanKindStaticStatement = `kind == "%v"` + spanKindStaticStatement = `kind.deprecated_string == "%v"` scopeNameStaticStatement = `instrumentation_scope.name == "%v"` scopeVersionStaticStatement = `instrumentation_scope.version == "%v"` attributesStaticStatement = `attributes["%v"] == %v` @@ -39,7 +28,7 @@ const ( serviceNameRegexStatement = `IsMatch(resource.attributes["service.name"], "%v")` spanNameRegexStatement = `IsMatch(name, "%v")` - spanKindRegexStatement = `IsMatch(kind, "%v")` + spanKindRegexStatement = `IsMatch(kind.deprecated_string, "%v")` scopeNameRegexStatement = `IsMatch(instrumentation_scope.name, "%v")` scopeVersionRegexStatement = `IsMatch(instrumentation_scope.version, "%v")` attributesRegexStatement = `IsMatch(attributes["%v"], "%v")` @@ -177,7 +166,7 @@ func createAttributeConditions(template string, input []filterconfig.Attribute, if matchType == filterset.Strict { value = convertAttribute(attribute.Value) } else { - value = attribute.Key + value = attribute.Value } attributeConditions = append(attributeConditions, fmt.Sprintf(template, attribute.Key, value)) } diff --git a/internal/filter/filterspan/filterspan_test.go b/internal/filter/filterspan/filterspan_test.go index ab6b43854991..38c8562cf680 100644 --- a/internal/filter/filterspan/filterspan_test.go +++ b/internal/filter/filterspan/filterspan_test.go @@ -17,8 +17,10 @@ import ( "github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal/testdata" "github.com/open-telemetry/opentelemetry-collector-contrib/internal/coreinternal/traceutil" "github.com/open-telemetry/opentelemetry-collector-contrib/internal/filter/filterconfig" + "github.com/open-telemetry/opentelemetry-collector-contrib/internal/filter/filterottl" "github.com/open-telemetry/opentelemetry-collector-contrib/internal/filter/filterset" "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/ottl/contexts/ottlspan" + "github.com/open-telemetry/opentelemetry-collector-contrib/pkg/ottl/ottltest" ) func createConfig(matchType filterset.MatchType) *filterset.Config { @@ -305,6 +307,927 @@ func TestServiceNameForResource(t *testing.T) { } +func Test_NewSkipExpr_With_Bridge(t *testing.T) { + tests := []struct { + name string + condition *filterconfig.MatchConfig + }{ + // Service name + { + name: "single static service name include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Services: []string{"svcA"}, + }, + }, + }, + { + name: "multiple static service name include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Services: []string{"svcB", "svcC"}, + }, + }, + }, + { + name: "single regex service name include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Services: []string{"svc.*"}, + }, + }, + }, + { + name: "multiple regex service name include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Services: []string{".*B", ".*C"}, + }, + }, + }, + { + name: "single static service name exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Services: []string{"svcA"}, + }, + }, + }, + { + name: "multiple static service name exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Services: []string{"svcB", "svcC"}, + }, + }, + }, + { + name: "single regex service name exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Services: []string{"svc.*"}, + }, + }, + }, + { + name: "multiple regex service name exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Services: []string{".*B", ".*C"}, + }, + }, + }, + + // Span name + { + name: "single static span name include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + SpanNames: []string{"spanName"}, + }, + }, + }, + { + name: "multiple static span name include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + SpanNames: []string{"foo", "bar"}, + }, + }, + }, + { + name: "single regex span name include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + SpanNames: []string{"span.*"}, + }, + }, + }, + { + name: "multiple regex span name include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + SpanNames: []string{"foo.*", "bar.*"}, + }, + }, + }, + { + name: "single static span name exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + SpanNames: []string{"spanName"}, + }, + }, + }, + { + name: "multiple static span name exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + SpanNames: []string{"foo", "bar"}, + }, + }, + }, + { + name: "single regex span name exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + SpanNames: []string{"span.*"}, + }, + }, + }, + { + name: "multiple regex span name exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + SpanNames: []string{"foo.*", "bar.*"}, + }, + }, + }, + + // Span kind + { + name: "single static span kind include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + SpanKinds: []string{"SPAN_KIND_CLIENT"}, + }, + }, + }, + { + name: "multiple static span kind include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + SpanKinds: []string{"SPAN_KIND_SERVER", "SPAN_KIND_PRODUCER"}, + }, + }, + }, + { + name: "single regex span kind include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + SpanKinds: []string{"SPAN_KIND_"}, + }, + }, + }, + { + name: "multiple regex span kind include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + SpanKinds: []string{"foo.*", "bar.*"}, + }, + }, + }, + { + name: "single static span kind exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + SpanKinds: []string{"SPAN_KIND_CLIENT"}, + }, + }, + }, + { + name: "multiple static span kind exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + SpanKinds: []string{"SPAN_KIND_SERVER", "SPAN_KIND_PRODUCER"}, + }, + }, + }, + { + name: "single regex span kind exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + SpanKinds: []string{"SPAN_KIND_"}, + }, + }, + }, + { + name: "multiple regex span kind exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + SpanKinds: []string{"foo.*", "bar.*"}, + }, + }, + }, + + // Scope name + { + name: "single static scope name include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "scope", + }, + }, + }, + }, + }, + { + name: "multiple static scope name include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "foo", + }, + { + Name: "bar", + }, + }, + }, + }, + }, + { + name: "single regex scope name include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "scope", + }, + }, + }, + }, + }, + { + name: "multiple regex scope name include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "foo.*", + }, + { + Name: "bar.*", + }, + }, + }, + }, + }, + { + name: "single static scope name exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "scope", + }, + }, + }, + }, + }, + { + name: "multiple static scope name exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "foo", + }, + { + Name: "bar", + }, + }, + }, + }, + }, + { + name: "single regex scope name exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "scope", + }, + }, + }, + }, + }, + { + name: "multiple regex scope name exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "foo.*", + }, + { + Name: "bar.*", + }, + }, + }, + }, + }, + + // Scope version + { + name: "single static scope version include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "scope", + Version: ottltest.Strp("0.1.0"), + }, + }, + }, + }, + }, + { + name: "multiple static scope version include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "scope", + Version: ottltest.Strp("2.0.0"), + }, + { + Name: "scope", + Version: ottltest.Strp(`1.1.0`), + }, + }, + }, + }, + }, + { + name: "single regex scope version include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "scope", + Version: ottltest.Strp("0.*"), + }, + }, + }, + }, + }, + { + name: "multiple regex scope version include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "scope", + Version: ottltest.Strp("2.*"), + }, + { + Name: "scope", + Version: ottltest.Strp("^1\\\\.1.*"), + }, + }, + }, + }, + }, + { + name: "single static scope version exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "scope", + Version: ottltest.Strp("0.1.0"), + }, + }, + }, + }, + }, + { + name: "multiple static scope version exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "scope", + Version: ottltest.Strp("2.0.0"), + }, + { + Name: "scope", + Version: ottltest.Strp(`1.1.0`), + }, + }, + }, + }, + }, + { + name: "single regex scope version exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "scope", + Version: ottltest.Strp("0.*"), + }, + }, + }, + }, + }, + { + name: "multiple regex scope version exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "scope", + Version: ottltest.Strp("2.*"), + }, + { + Name: "scope", + Version: ottltest.Strp(`1\\.1.*`), + }, + }, + }, + }, + }, + + // attributes + { + name: "single static attribute include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Attributes: []filterconfig.Attribute{ + { + Key: "attr1", + Value: "val1", + }, + }, + }, + }, + }, + { + name: "multiple static attribute include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + + Attributes: []filterconfig.Attribute{ + { + Key: "attr1", + Value: "val2", + }, + { + Key: "attr2", + Value: "val2", + }, + }, + }, + }, + }, + { + name: "single regex attribute include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Attributes: []filterconfig.Attribute{ + { + Key: "attr1", + Value: "val.*", + }, + }, + }, + }, + }, + { + name: "multiple regex attribute include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Attributes: []filterconfig.Attribute{ + { + Key: "attr1", + Value: "val", + }, + { + Key: "attr3", + Value: "val.*", + }, + }, + }, + }, + }, + { + name: "single static attribute exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Attributes: []filterconfig.Attribute{ + { + Key: "attr1", + Value: "val1", + }, + }, + }, + }, + }, + { + name: "multiple static attribute exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + + Attributes: []filterconfig.Attribute{ + { + Key: "attr1", + Value: "val2", + }, + { + Key: "attr2", + Value: "val2", + }, + }, + }, + }, + }, + { + name: "single regex attribute exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Attributes: []filterconfig.Attribute{ + { + Key: "attr1", + Value: "val.*", + }, + }, + }, + }, + }, + { + name: "multiple regex attribute exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Attributes: []filterconfig.Attribute{ + { + Key: "attr1", + Value: "val", + }, + { + Key: "attr3", + Value: "val.*", + }, + }, + }, + }, + }, + + // resource attributes + { + name: "single static resource attribute include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Resources: []filterconfig.Attribute{ + { + Key: "service.name", + Value: "svcA", + }, + }, + }, + }, + }, + { + name: "multiple static resource attribute include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + + Resources: []filterconfig.Attribute{ + { + Key: "service.name", + Value: "svc2", + }, + { + Key: "service.version", + Value: "v1", + }, + }, + }, + }, + }, + { + name: "single regex resource attribute include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Resources: []filterconfig.Attribute{ + { + Key: "service.name", + Value: "svc.*", + }, + }, + }, + }, + }, + { + name: "multiple regex resource attribute include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Resources: []filterconfig.Attribute{ + { + Key: "service.name", + Value: ".*2", + }, + { + Key: "service.name", + Value: ".*3", + }, + }, + }, + }, + }, + { + name: "single static resource attribute exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + Resources: []filterconfig.Attribute{ + { + Key: "service.name", + Value: "svcA", + }, + }, + }, + }, + }, + { + name: "multiple static resource attribute exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + + Resources: []filterconfig.Attribute{ + { + Key: "service.name", + Value: "svc2", + }, + { + Key: "service.version", + Value: "v1", + }, + }, + }, + }, + }, + { + name: "single regex resource attribute exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Resources: []filterconfig.Attribute{ + { + Key: "service.name", + Value: "svc.*", + }, + }, + }, + }, + }, + { + name: "multiple regex resource attribute exclude", + condition: &filterconfig.MatchConfig{ + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Resources: []filterconfig.Attribute{ + { + Key: "service.name", + Value: ".*2", + }, + { + Key: "service.name", + Value: ".*3", + }, + }, + }, + }, + }, + + // complex + { + name: "single static resource attribute include", + condition: &filterconfig.MatchConfig{ + Include: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Regexp, + }, + Services: []string{"svcA"}, + Libraries: []filterconfig.InstrumentationLibrary{ + { + Name: "scope", + Version: ottltest.Strp("0.1.0"), + }, + }, + Resources: []filterconfig.Attribute{ + { + Key: "service.name", + Value: "svcA", + }, + }, + }, + Exclude: &filterconfig.MatchProperties{ + Config: filterset.Config{ + MatchType: filterset.Strict, + }, + SpanNames: []string{"spanName"}, + SpanKinds: []string{"SPAN_KIND_CLIENT"}, + Attributes: []filterconfig.Attribute{ + { + Key: "attr1", + Value: "val1", + }, + }, + }, + }, + }, + } + + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + span := ptrace.NewSpan() + span.SetName("spanName") + span.Attributes().PutStr("attr1", "val1") + span.SetKind(ptrace.SpanKindClient) + + resource := pcommon.NewResource() + resource.Attributes().PutStr("service.name", "svcA") + + scope := pcommon.NewInstrumentationScope() + scope.SetName("scope") + scope.SetVersion("0.1.0") + + tCtx := ottlspan.NewTransformContext(span, scope, resource) + + boolExpr, err := NewSkipExpr(tt.condition) + require.NoError(t, err) + expectedResult, err := boolExpr.Eval(context.Background(), tCtx) + assert.NoError(t, err) + + ottlBoolExpr, err := filterottl.NewSpanSkipExprBridge(tt.condition) + assert.NoError(t, err) + ottlResult, err := ottlBoolExpr.Eval(context.Background(), tCtx) + assert.NoError(t, err) + + assert.Equal(t, expectedResult, ottlResult) + }) + } +} + func BenchmarkFilterspan_NewSkipExpr(b *testing.B) { testCases := []struct { name string diff --git a/internal/filter/go.mod b/internal/filter/go.mod index ad288b054616..e1b909a75987 100644 --- a/internal/filter/go.mod +++ b/internal/filter/go.mod @@ -11,6 +11,7 @@ require ( github.com/stretchr/testify v1.8.2 go.opentelemetry.io/collector/component v0.78.2 go.opentelemetry.io/collector/confmap v0.78.2 + go.opentelemetry.io/collector/featuregate v1.0.0-rcv0012 go.opentelemetry.io/collector/pdata v1.0.0-rcv0012 go.opentelemetry.io/collector/semconv v0.78.2 go.uber.org/zap v1.24.0 @@ -34,7 +35,6 @@ require ( github.com/modern-go/reflect2 v1.0.2 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect go.opentelemetry.io/collector v0.78.2 // indirect - go.opentelemetry.io/collector/featuregate v1.0.0-rcv0012 // indirect go.opentelemetry.io/otel v1.15.1 // indirect go.opentelemetry.io/otel/metric v0.38.1 // indirect go.opentelemetry.io/otel/trace v1.15.1 // indirect diff --git a/processor/attributesprocessor/go.mod b/processor/attributesprocessor/go.mod index c3649ee5e988..3c7c6a16d49d 100644 --- a/processor/attributesprocessor/go.mod +++ b/processor/attributesprocessor/go.mod @@ -26,6 +26,7 @@ require ( github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/protobuf v1.5.3 // indirect + github.com/google/uuid v1.3.0 // indirect github.com/iancoleman/strcase v0.2.0 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/knadh/koanf v1.5.0 // indirect diff --git a/processor/attributesprocessor/go.sum b/processor/attributesprocessor/go.sum index 155067d277d1..1513da15acd6 100644 --- a/processor/attributesprocessor/go.sum +++ b/processor/attributesprocessor/go.sum @@ -109,6 +109,8 @@ github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8 github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/google/uuid v1.3.0 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I= +github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/hashicorp/consul/api v1.13.0/go.mod h1:ZlVrynguJKcYr54zGaDbaL3fOvKC9m72FhPvA8T35KQ= diff --git a/processor/spanprocessor/go.mod b/processor/spanprocessor/go.mod index a14be88d06ad..e3ca4f1d0363 100644 --- a/processor/spanprocessor/go.mod +++ b/processor/spanprocessor/go.mod @@ -24,6 +24,7 @@ require ( github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/protobuf v1.5.3 // indirect + github.com/google/uuid v1.3.0 // indirect github.com/iancoleman/strcase v0.2.0 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/knadh/koanf v1.5.0 // indirect diff --git a/processor/spanprocessor/go.sum b/processor/spanprocessor/go.sum index 33a63e7d260d..9e2dccb2ebb4 100644 --- a/processor/spanprocessor/go.sum +++ b/processor/spanprocessor/go.sum @@ -107,6 +107,8 @@ github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8 github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/google/uuid v1.3.0 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I= +github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/hashicorp/consul/api v1.13.0/go.mod h1:ZlVrynguJKcYr54zGaDbaL3fOvKC9m72FhPvA8T35KQ=