Skip to content
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

org/slf4j/impl/StaticLoggerBinder not found #9860

Closed
Bin1993 opened this issue Jan 17, 2023 · 4 comments
Closed

org/slf4j/impl/StaticLoggerBinder not found #9860

Bin1993 opened this issue Jan 17, 2023 · 4 comments
Assignees
Labels
area/Client Related to Nacos Client SDK kind/research
Milestone

Comments

@Bin1993
Copy link

Bin1993 commented Jan 17, 2023

Describe the bug
I am using springboot 3.0.1 , nacos 2.2.1 RC, when i startup , the console print "NacosLogging Load Logback Configuration of Nacos fail, message: org/slf4j/impl/StaticLoggerBinder", I have inspect nacos code, I found that StaticLoggerBinder usually offers by Logback or Log4J, but the springboot 3.0.1 default import logback 1.4.5, it doesn‘t offer StaticLoggerBinder. So I think, nacos should adapter for logback 1.4.5

Expected behavior
"NacosLogging Load Logback Configuration of Nacos fail, message: org/slf4j/impl/StaticLoggerBinder", this warning dong't show again.

How to Reproduce
Steps to reproduce the behavior:
use springboot 3.0.1

@KomachiSion KomachiSion added kind/research area/Client Related to Nacos Client SDK labels Jan 28, 2023
@hujun-w-2 hujun-w-2 self-assigned this Feb 1, 2023
@YunWZ
Copy link
Contributor

YunWZ commented Feb 5, 2023

refer this issue :

spring-boot 3.0 dependencyLogback 1.4, so you needed to explicitly downgrade logback-core and logback-classic to 1.2.10.

@PRANRAVEE
Copy link

PRANRAVEE commented Feb 5, 2023 via email

@Torboxin
Copy link

Torboxin commented Feb 6, 2023

我尝试依靠jvm的类加载机制解决,就像logback提供StaticLoggerBinder的时一样但效果并不理想,项目中多个模块都需要添加com.alibaba.nacos.client.logging.logback.LogbackNacosLogging包与类并重写loadConfigurationOnStart()方法获取LoggerContext对象的片段代码,这让我感到非常的繁琐。

@hujun-w-2
Copy link
Collaborator

正在适配中

KomachiSion pushed a commit that referenced this issue Feb 22, 2023
…oblem between different version (#9934)

* logback update

* update comment

* ident update

* comment update

* judge version

* remove logback-adapter
@KomachiSion KomachiSion added this to the 2.2.1 milestone Feb 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/Client Related to Nacos Client SDK kind/research
Projects
None yet
Development

No branches or pull requests

6 participants