Skip to content

Relocate OpenTelemetryLoggingAutoConfiguration and SdkLoggerProviderBuilderCustomizer to an OpenTelemetry-specific package #44647

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

Open
wilkinsona opened this issue Mar 7, 2025 · 6 comments
Labels
type: enhancement A general enhancement
Milestone

Comments

@wilkinsona
Copy link
Member

wilkinsona commented Mar 7, 2025

OpenTelemetryLoggingAutoConfiguration and SdkLoggerProviderBuilderCustomizer are in org.springframework.boot.actuate.autoconfigure.logging. I think they should be in an OpenTelemetry-specific package as none of other code in org.springframework.boot.actuate.autoconfigure.logging has any third-party dependencies.

If we were just the auto-configuration class, we could make this change fairly easily in 3.5 however there's the customizer to consider too.

@wilkinsona wilkinsona added type: enhancement A general enhancement status: pending-design-work Needs design work before any code can be developed for: team-meeting An issue we'd like to discuss as a team to make progress labels Mar 7, 2025
@philwebb philwebb removed the for: team-meeting An issue we'd like to discuss as a team to make progress label Apr 7, 2025
@philwebb
Copy link
Member

philwebb commented Apr 7, 2025

We discussed this today and we'd like to relocate them. We'd like to aim for 3.5, but if the customizer causes too much of an issue we'll push this back to 4.0.0

@philwebb philwebb added this to the 3.5.x milestone Apr 7, 2025
@mhalbritter
Copy link
Contributor

I've moved them to org.springframework.boot.actuate.autoconfigure.logging.opentelemetry.OpenTelemetryLoggingAutoConfiguration and org.springframework.boot.actuate.autoconfigure.logging.opentelemetry.SdkLoggerProviderBuilderCustomizer.

The moved OpenTelemetryLoggingAutoConfiguration takes care of the moved SdkLoggerProviderBuilderCustomizer and the old, deprecated one.

@mhalbritter mhalbritter removed the status: pending-design-work Needs design work before any code can be developed label Apr 8, 2025
@mhalbritter mhalbritter modified the milestones: 3.5.x, 3.5.0-RC1 Apr 8, 2025
@wilkinsona
Copy link
Member Author

Was org.springframework.boot.actuate.autoconfigure.opentelemetry.logging considered for the new package? I wonder if that might have been better as it would then sit alongside the existing org.springframework.boot.actuate.autoconfigure.opentelemetry package. The opentelemtry.logging package name would also align with the OpenTelemetryLoggingAutoConfiguration class name.

I know that we have org.springframework.boot.actuate.autoconfigure.logging.otlp but its management.otlp.logging properties suggest that it should perhaps have been named org.springframework.boot.actuate.autoconfigure.otlp.logging.

@mhalbritter
Copy link
Contributor

I tried mirroring the existing OpenTelemetry support for tracing.

Tracing is in org.springframework.boot.actuate.autoconfigure.tracing.OpenTelemetryTracingAutoConfiguration, that's why the original class for logging was located in org.springframework.boot.actuate.autoconfigure.logging.

If we move OpenTelemetryLoggingAutoConfiguration to org.springframework.boot.actuate.autoconfigure.opentelemetry.logging, should we also move OpenTelemetryTracingAutoConfiguration to org.springframework.boot.actuate.autoconfigure.opentelemetry.tracing?

Our usual package structure is org.springframework.boot.actuate.autoconfigure.<domain>.<technology>, at least for metrics and tracing.

@wilkinsona wilkinsona added the for: team-meeting An issue we'd like to discuss as a team to make progress label Apr 14, 2025
@wilkinsona
Copy link
Member Author

I guess it comes down to whether we consider the auto-configuration to primarily be a logging-related feature or an OpenTelemetry-related feature. It feels like the latter to me.

@mhalbritter mhalbritter removed the for: team-meeting An issue we'd like to discuss as a team to make progress label Apr 16, 2025
@mhalbritter mhalbritter modified the milestones: 3.5.0-RC1, 4.0.x Apr 16, 2025
@mhalbritter mhalbritter reopened this Apr 16, 2025
@wilkinsona
Copy link
Member Author

We discussed this today and decided to revert the change in 3.5 and deal with it in 4.0 instead.

@mhalbritter mhalbritter removed their assignment Apr 16, 2025
mhalbritter added a commit that referenced this issue Apr 17, 2025
…roviderBuilderCustomizer to an OpenTelemetry-specific package"

This reverts commit 2ca0897.

See gh-44647
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

3 participants