I hope you help me.
I have a web service that should log transactions. Since there are many hits, the log file contains log statements that do not intersect / fragment.
I considered passing a StringBuilder instance through layers and adding statements to that instance, after which I return its contents once at the very end (the finally clause in the main controller) before returning the response to the client. This seems unnecessary, and I'm sure there is a cleaner way to do this with Log4J.
Can anyone shed some light on the problem?
thanks
source
share