Open
Description
This issue was originally discussed in spring-projects/spring-boot#34400.
The scenario is the following: if Spring Security is used and users want to ignore /actuator
endpoints, there is no easy way to ignore Observation
s created by Spring Security because the details to make this decision are missing when the ObservationPredicate
is tested.
One potential solution would be adding the request to the Context
before the Observation is created, one example here:
Would be something like:
FilterChainObservationContext beforeContext = FilterChainObservationContext.before(request);
FilterChainObservationContext afterContext = FilterChainObservationContext.after(request);
Expected behavior: having extra details on the Observations created by Spring Security that allows the users to ignore these Observation based on the request.
There is a reproducer in the issue mentioned above.