pandaapo commented on code in PR #4698:
URL: https://github.com/apache/eventmesh/pull/4698#discussion_r1438504051
##########
eventmesh-common/src/main/java/org/apache/eventmesh/common/file/WatchFileManager.java:
##########
@@ -62,10 +60,10 @@ private static void shutdown() {
return;
}
- LogUtils.info(log, "[WatchFileManager] start close");
+ log.atInfo().log("[WatchFileManager] start close");
Review Comment:
1.
> Better performance
Regarding "better performance", the code here does not have the same
situation as the example you provided.
> However, in many cases, removing the `ifDebugEnabled` directly would
result in a performance decrease.
Could you provide some examples to illustrate the performance decrease after
removing the `ifDebugEnabled` you mentioned here?
Also, I don't quite understand what you mean by "removing the
`ifDebugEnabled`". What is the relationship between log.debug() internal
supporting for determining log level and "removing the `ifDebugEnabled`"?
2.
> That requires obtaining the Fully Qualified Class Name (FQCN) of each
class and passing it as a parameter to LogUtils
The fact seems to be different.
---
1.
> However, in many cases, removing the `ifDebugEnabled` directly would
result in a performance decrease.
关于“性能更好”,这里的代码不存在您所举例的情况。
> However, in many cases, removing the `ifDebugEnabled` directly would
result in a performance decrease.
能否列举一些情况说明一下您这句所说的性能降低的情况?
另外,我不太明白您说的“removing the
`ifDebugEnabled`”。log.debug()内部已经支持判断日志级别,这和“removing the
`ifDebugEnabled`”有什么关系?
2.
> That requires obtaining the Fully Qualified Class Name (FQCN) of each
class and passing it as a parameter to LogUtils
好像并非如此。
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]