Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Update OTEL dependencies to v0.112.0 #234

Merged
merged 2 commits into from
Oct 28, 2024

Conversation

StefanKurek
Copy link
Collaborator

@StefanKurek StefanKurek commented Oct 22, 2024

This changes the OTEL dependencies to v0.112.0

@StefanKurek StefanKurek changed the title feat: Update OTEL dependencies to HEAD (soon to be 0.112.0) & fix discrepencies feat: Update OTEL dependencies to v0.112.0 Oct 23, 2024
Copy link
Contributor

@braydonk braydonk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Most of the changes look fine to me, just want to understand one change.

)

func TestCreateDefaultConfig(t *testing.T) {
assert.NoError(t, componenttest.CheckConfigStruct(NewFactory().CreateDefaultConfig()))
}

func TestCreateProcessor(t *testing.T) {
mp, err := createMetricsProcessor(context.Background(), processor.CreateSettings{}, createDefaultConfig(), consumertest.NewNop())
cfg := createDefaultConfig().(*Config)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you explain why this was done? I'm having trouble understanding the reason.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@braydonk Honestly I can't remember why I did this for the config...but good catch! Doesn't seem to be necessary. Might have came from a copy/paste while looking at existing factory tests within the latest release.

Pushing a change to just pass in createDefaultConfig() in the 3 files where I did this.

ConfigProviderSettings: otelcol.ConfigProviderSettings{
ResolverSettings: confmap.ResolverSettings{
ProviderFactories: []confmap.ProviderFactory{
fileprovider.NewFactory(),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason we're adding all these providers for our distro? Not sure why these are needed now

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't we only use the file provider?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There was an upstream change that forces you do explicitly list providers now, I don't have a reference at hand though

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ack, it stems from https://github.com/open-telemetry/opentelemetry-collector/pull/9513/files

We used to default to all the default providers so this change makes sense. We should separately reduce this list to just the file provider but that shouldn't block this PR

ConfigProviderSettings: otelcol.ConfigProviderSettings{
ResolverSettings: confmap.ResolverSettings{
ProviderFactories: []confmap.ProviderFactory{
fileprovider.NewFactory(),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ack, it stems from https://github.com/open-telemetry/opentelemetry-collector/pull/9513/files

We used to default to all the default providers so this change makes sense. We should separately reduce this list to just the file provider but that shouldn't block this PR

@ridwanmsharif ridwanmsharif merged commit 6326612 into GoogleCloudPlatform:master Oct 28, 2024
5 checks passed
@StefanKurek StefanKurek deleted the feat/update-otel branch October 28, 2024 20:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants