I'd like to measure the length of some async calls made with WebFlux. I've been reading through various sources, as I understand the @Timed annotation is working with AspectJ and basically just starts a timer before the method call and stops it after. This obviously won't work with async methods.
Are there any solutions for WebFlux or the only thing I can do is passing around execution timestamps, cluttering my application logic?
Project Reactor natively supports Micrometer, please refer to the documentation to find out more: https://projectreactor.io/docs/core/milestone/reference/#_publisher_metrics
For example, you may want to monitor reactor.flow.duration.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With