...
|
...
|
@@ -50,7 +50,7 @@ public final class LogUtils { |
|
|
|
|
|
// 3. 启动异步线程确保在指定时间之后失效
|
|
|
long delay = expireSeconds > 0 && expireSeconds < MAX_EXPIRE_SECONDS ? expireSeconds : DEFAULT_EXPIRE_SECONDS;
|
|
|
POOL.schedule(() -> logger.setLevel(srcLevel), delay, TimeUnit.SECONDS);
|
|
|
POOL.schedule(() -> logger.setLevel(sourceLevelMap.getOrDefault(loggerName, srcLevel)), delay, TimeUnit.SECONDS);
|
|
|
|
|
|
// 4. 变更日志级别
|
|
|
logger.setLevel(level);
|
...
|
...
|
|