Refine the recently introduced `EndpointRequest` matcher `toString()`
to use lower-case item names. Also applied the same logic to the
reactive variant.
See gh-33690
This commit declares an `@Order` for the `ServerHttpObservationFilter`
bean declaration in the Observation WebFlux auto-configuration.
This allows developers to consistently order other `WebFilter` instances
relatively to this one. Here, `@Order(Ordered.HIGHEST_PRECEDENCE + 1)`
has been chosen to align with the order of its MVC counterpart.
Fixes gh-33444
As of spring-projects/spring-graphql#547, Spring GraphQL introduced a
`PropagationWebGraphQlInterceptor` that propagates the incoming tracing
information in HTTP request headers into the GraphQL context.
This commit auto-configures the propagation interceptor if the
application exposes a GraphQL HTTP endpoint and if it is configured for
Tracing support.
Fixes gh-33542
Prior to this commit, the `ClientObservationConventionAdapter` would
fail with an `IllegalArgumentException` when the observation is first
started: at this point, the carrier (the request builder here) is
present, but the full request not yet fully built.
This commit ensures that the convention adapter uses the request and, if
not available, the request builder to adapt to the
`WebClientExchangeTagsProvider`.
Fixes gh-33483
Prior to this commit, we would advise developers, as migration path from
Spring Boot 2.0-x metrics, to create `GlobalObservationConvention` beans
for the observations they want to customize (observation name or key
values).
`GlobalObservationConvention` are currently applied **in addition** to
the chosen convention in some cases, so this does not work well with
this migration path.
Instead, instrumentations always provide a default convention but also a
way to configure a custom convention for their observations. Spring Boot
should inject custom convention beans in the relevant
auto-configurations.
Fixes gh-33285
Relocate `ApplicationTags` `@Bean` method from
`WavefrontTracingAutoConfiguration` to `WavefrontAutoConfiguration`
since it is now shared between tracing and metrics.
The `application-name`, `service-name`, `cluster-name` and `shard-name`
have also been relocated from `management.wavefront.tracing` to
`management.wavefront`.
Fixes gh-33244
Update `application-name` and `service-name` `management.wavefront`
properties to align with Spring Boot 2.x support. The properties now
use the wavefront terminology where `application` refers to an a
collection of (micro)`services`.
This commit also adds `cluster-name` and `shard-name` properties that
can be used to add additional items to the `ApplicationTags`.
See gh-32844
Update `ManagementContextFactory` implementations to create an
appropriate `Environment` type and to apply the `ConversionService`
from the parent context.
Prior to this commit, the management context `Environment` would not
be able to convert values from a `configtree:` source due to a missing
converter.
Fixes gh-32941
Returning a private class from a package-private method causes the
AOT-generated source files to fail to compile as the private class is
not visible.
Closes gh-33106
Update `MeterRegistryPostProcessor` to configure `MeterRegistry` beans
in two distinct sweeps. The first sweep applies customizers and filters
as the `MeterRegistry` bean is initialized, the second sweep applies
`MeterBinder` beans once all singletons have been instantiated.
Prior to this commit, it was not possible for a `MeterBinder` bean to
directly or indirectly use a `MeterRegistry`. It was also possible for
bound meters to cause a deadlock during refresh processing if those
meters could be updated on a thread other than main, such as GC
notifications.
Fixes gh-30636
Fixes gh-33070
Update types returned from endpoints to implement the
`OperationResponseBody` interface. This ensures that they will be
serialized using the isolated actuator `ObjectMapper`.
See gh-20291
Add `OperationResponseBody` tagging interface that can be used
to trigger the use of an isolated ObjectMapper specifically for
actuator responses.
The isolated mapper is provided by an `EndpointObjectMapper`
bean which is auto-configured unless specifically disabled
by the user.
WebMVC, WebFlux and Jersey integrations have been updated
to provide a link between the `OperationResponseBody` type
and the endpoint `ObjectMapper`.
See gh-20291
Rename `/actuator/httptrace` to `/actuator/httpexchanges` to better
describe its purpose and to remove confusion with distribute tracing.
This change also takes the opportunity to improve the code by making
the `HttpExchange` class (previously `HttpTrace`) fully immutable.
Closes gh-32885
Co-authored-by: Andy Wilkinson <wilkinsona@vmware.com>
Without this change we're missing the BaggageTextMapPropagator for
OTel. This means that we're not propagating remote-fields
(only baggage via the 'baggage' field).
With this change we're adding the missing propagator as
THE LAST entry in the composite TextMapPropagator. It has to be
last cause with the latest Snapshots of Micrometer Tracing it
will append the remote field baggage to existing baggage in the
context extracted via the W3CBaggagePropagator.
See gh-32898