Skip to content

Commit

Permalink
Merge pull request #2748 from aws-observability/chore/updateOtel
Browse files Browse the repository at this point in the history
Update OTel dependencies to v0.102.[01]
  • Loading branch information
Aneurysm9 authored Jun 14, 2024
2 parents ed3f2c4 + 952c3b3 commit cc1ea01
Show file tree
Hide file tree
Showing 3,326 changed files with 419,003 additions and 300,595 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
586 changes: 323 additions & 263 deletions go.mod

Large diffs are not rendered by default.

1,458 changes: 786 additions & 672 deletions go.sum

Large diffs are not rendered by default.

118 changes: 0 additions & 118 deletions patches/configgrpc.patch

This file was deleted.

80 changes: 0 additions & 80 deletions patches/confighttp.patch

This file was deleted.

25 changes: 10 additions & 15 deletions pkg/config/config_factory.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,26 +43,21 @@ func GetConfigProviderSettings(flags *flag.FlagSet) otelcol.ConfigProviderSettin
}

// generate the MapProviders for the Config Provider Settings
providers := []confmap.Provider{
fileprovider.NewWithSettings(confmap.ProviderSettings{}),
envprovider.NewWithSettings(confmap.ProviderSettings{}),
yamlprovider.NewWithSettings(confmap.ProviderSettings{}),
httpprovider.NewWithSettings(confmap.ProviderSettings{}),
httpsprovider.NewWithSettings(confmap.ProviderSettings{}),
s3provider.New(),
}

mapProviders := make(map[string]confmap.Provider, len(providers))
for _, provider := range providers {
mapProviders[provider.Scheme()] = provider
providers := []confmap.ProviderFactory{
fileprovider.NewFactory(),
envprovider.NewFactory(),
yamlprovider.NewFactory(),
httpprovider.NewFactory(),
httpsprovider.NewFactory(),
s3provider.NewFactory(),
}

// create Config Provider Settings
configProviderSettings := otelcol.ConfigProviderSettings{
ResolverSettings: confmap.ResolverSettings{
URIs: loc,
Providers: mapProviders,
Converters: []confmap.Converter{expandconverter.New(confmap.ConverterSettings{})},
URIs: loc,
ProviderFactories: providers,
ConverterFactories: []confmap.ConverterFactory{expandconverter.NewFactory()},
},
}

Expand Down
6 changes: 3 additions & 3 deletions pkg/defaultcomponents/defaults.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,15 +78,15 @@ var datadogExporterFeatureGateDeprecation = featuregate.GlobalRegistry().MustReg
featuregate.WithRegisterDescription("Removes the Datadog exporter from the set of configurable exporters "))

var logzioExporterFeatureGateDeprecation = featuregate.GlobalRegistry().MustRegister("adot.exporter.logzioexporter.deprecation",
featuregate.StageAlpha,
featuregate.StageBeta,
featuregate.WithRegisterDescription("Removes the Logzio Exporter from the set of configurable exporters "))

var sapmExporterFeatureGateDeprecation = featuregate.GlobalRegistry().MustRegister("adot.exporter.sapmexporter.deprecation",
featuregate.StageAlpha,
featuregate.StageBeta,
featuregate.WithRegisterDescription("Removes the SAPM Exporter from the set of configurable exporters"))

var signalfxExporterFeatureGateDeprecation = featuregate.GlobalRegistry().MustRegister("adot.exporter.signalfxexporter.deprecation",
featuregate.StageAlpha,
featuregate.StageBeta,
featuregate.WithRegisterDescription("Removes the SignalFx Metrics Exporter from the set of configurable exporters"))

// Components register OTel components for ADOT-collector distribution
Expand Down
23 changes: 3 additions & 20 deletions pkg/defaultcomponents/defaults_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,16 @@
package defaultcomponents

import (
"testing"

"go.opentelemetry.io/collector/component"
"go.opentelemetry.io/collector/featuregate"
"testing"

"github.com/stretchr/testify/assert"
)

const (
exportersCount = 15
exportersCount = 12
receiversCount = 10
extensionsCount = 8
processorCount = 15
Expand Down Expand Up @@ -105,9 +106,6 @@ func TestComponents(t *testing.T) {

// Ensure that the components behind feature gates are included
assert.NotNil(t, exporters[component.MustNewType("datadog")])
assert.NotNil(t, exporters[component.MustNewType("sapm")])
assert.NotNil(t, exporters[component.MustNewType("signalfx")])
assert.NotNil(t, exporters[component.MustNewType("logzio")])
}

func TestEnableFeatureGate(t *testing.T) {
Expand All @@ -122,21 +120,6 @@ func TestEnableFeatureGate(t *testing.T) {
featureName: "adot.exporter.datadogexporter.deprecation",
component: component.MustNewType("datadog"),
},
{
desc: "disable logzio exporter",
featureName: "adot.exporter.logzioexporter.deprecation",
component: component.MustNewType("logzio"),
},
{
desc: "disable sapm exporter",
featureName: "adot.exporter.sapmexporter.deprecation",
component: component.MustNewType("sapm"),
},
{
desc: "disable signalfx exporter",
featureName: "adot.exporter.signalfxexporter.deprecation",
component: component.MustNewType("signalfx"),
},
}
expectedLen := exportersCount

Expand Down
Loading

0 comments on commit cc1ea01

Please sign in to comment.