Cross-Posting from Reactor core Hello Everyone,
In our webflux project we are using the publisher hooks as proposed here to populate traceIDs
which are used to trace logs across microservices. It is working very well functionally, but there are performance issues because of this. Please check below
With TraceIDs
For 1000 concurrent requests mean response time is 0.6 sec.
For 5000 concurrent requests mean response time is 1.5 sec.
For 10000 concurrent requests mean response time is 2.8 sec.
For 20000 concurrent requests mean response time is 4.8 sec.
Without traceIds
For 1000 concurrent requests mean response time is 0.8 sec.
For 5000 concurrent requests mean response time is 3.2 sec.
For 10000 concurrent requests mean response time is 6.2 sec.
For 20000 concurrent requests mean response time is 17 sec.
If you see the response time increase exponentially with the load while without traceIDs it is much better. Any suggestion if there are better ways of using traceids without hampering the performance.
Note: There is a slight change in our implementation, wee are also calling the copyToMdC
method in the onError
and onComplete
methods too, because we observed the traceIds missing in some error scenarios. The exact implementation can be found here.
Comment From: wilkinsona
Please don't cross-post issues as it runs the risk of duplicating effort and people wasting their time. Furthermore, as mentioned in the guidelines for contributing, we prefer to use GitHub issues only for bugs and enhancements.
If your comment on the existing Reactor issue does not get a response. I would recommend chatting with the Reactor community on Gitter.