-
Notifications
You must be signed in to change notification settings - Fork 13k
Nacos LoggerContext Using Slf4j LoggerFactory #9970
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
relatied with #9860 |
If change to new api, whether the old version can't be work? |
@hujun-w-2 discuss together. |
Older versions are still usable, and |
It seems #9934 can fix and use spi to extension is better. |
Okay, I will close it. |
自己打个包吗? |
logback-adapter will release with 2.2.1 together. |
Describe the bug
在使用Spring Boot 3.0 版本时 ,
logback-classic
版本为1.4.5
已经不再提供StaticLoggerBinder
这个类 , 导致nacos-logback.xml
没法正常加载.LogbackNacosLogging.java
:其中
LoggerContext
使用org.slf4j.impl.StaticLoggerBinder
类进行获取 , 但是以slf4j-api 2.x
为目标的logback 1.3
及更高版本等后端不随org.slf4j.impl.StaticLoggerBinder
一起提供。见 https://www.slf4j.org/codes.html#StaticLoggerBinde 原文:
例如Spring Boot 3.0 默认管理的
logback-classic-1.2.9
已经不再自带StaticLoggerBinder
这里直接基于原有的逻辑不变 , 增加一个使用
LoggerFactory
方式获取即可The text was updated successfully, but these errors were encountered: