开发者

Log TraceNo for each request in web application using Log4j

开发者 https://www.devze.com 2023-03-28 10:29 出处:网络
I have a class named TraceNoGenerator that works like a Sequence in an Oracle Database; I want to use this class to assign a trace number for each request that comes to my web application to log in a

I have a class named TraceNoGenerator that works like a Sequence in an Oracle Database; I want to use this class to assign a trace number for each request that comes to my web application to log in a log file. When my application received an error, this trace number will display on a web page so that I can easily find the bug开发者_如何学Go using this trace number in the log file.

How can I do this in Log4j?

0

精彩评论

暂无评论...
验证码 换一张
取 消