Skip to content

Auto-configuration ignores user-provided ObservationConventions #33285

@braunsonm

Description

@braunsonm

With the move to micrometer observability, the WebClientExchangeTagsProvider and RestTemplateExchangeTagsProvicer have both been deprecated in favour of ObservationConventions.

The configuration (in this case the reactive but also affects the servlet) is not customizable enough to allow users to move off the deprecated classes.

The configuration should have means to accept a custom implementation of the ObservationConvention. Right now you would have to exclude this configuration class completely as the default convention is created in the bean method. See here:
https://github.com/spring-projects/spring-boot/blob/main/spring-boot-project/spring-boot-actuator-autoconfigure/src/main/java/org/springframework/boot/actuate/autoconfigure/observation/web/client/WebClientObservationConfiguration.java#L53

Additional Context

I would like to migrate away from deprecated classes, but without being able to create my own ObservationConvention I cannot cleanly stop using the old TagsProvider's.

cc @bclozel excuse the tag, but mentioned as you created these configuration classes

Metadata

Metadata

Assignees

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions