spring-projects / spring-ws

Spring Web Services
https://spring.io/projects/spring-ws
Apache License 2.0
322 stars 311 forks source link

Add Observation implementation #1438

Open johkin opened 2 weeks ago

johkin commented 2 weeks ago

Initial implementation of observation for spring-ws.

Please feel free to comment and provide feedback.

1094

johkin commented 2 weeks ago

Ping @corneil

corneil commented 2 weeks ago

@johkin Thanks for this great contribution. I would suggest adding something like: Assert.notNull(observation, "Expected observation in messageContext"); at appropriate places.

johkin commented 1 week ago

I did some minor restructuring of the code to improve readability and error-handling/logging.

The method used to find the root element is identical in both interceptors, could be and improvement to refactor this to a helper-class? On the other hand, this requires the helper to be injected in the interceptors and creates another dependency.