Skip to content

Log4j2 升级到 2.23.1版本后,Nacos 会导致 Log4j2 日志输出异常 #12102

Open
@ldcsaa

Description

@ldcsaa

Describe the bug
Log4j2 升级到 2.23.1版本后,Nacos 会导致 Log4j2 日志输出异常:

2024-05-15T09:51:31.358800400Z main WARN The use of package scanning to locate plugins is deprecated and will be removed in a future release
2024-05-15T09:51:31.359776400Z main WARN The use of package scanning to locate plugins is deprecated and will be removed in a future release
2024-05-15T09:51:31.360752300Z main WARN The use of package scanning to locate plugins is deprecated and will be removed in a future release
2024-05-15T09:51:31.360752300Z main WARN The use of package scanning to locate plugins is deprecated and will be removed in a future release
2024-05-15T09:51:31.375392700Z main WARN No Root logger was configured, creating default ERROR-level Root logger with Console appender

是不是 Nacos 与 Log4j2 不够兼容导致的?
PS:配置了系统属性nacos.logging.default.config.enabled=false后,则不报异常警告了。或者Log4j2 回退到 2.22.1版本后也正常。

Expected behavior
nacos兼容log4j2-2.23.1.

Actually behavior
nacos不能很好兼容log4j2-2.23.1.

How to Reproduce
Steps to reproduce the behavior:

  1. 升级到log4j2-2.23.1
  2. 启动nacos应用程序

Desktop (please complete the following information):

  • OS: [e.g. win10]
  • SDK [e.g. original, spring-cloud-alibaba-nacos, dubbo]

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions