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

nacos3.0按照官网的说明启动不了,报错(win11系统) #13036

Open
CKKLIN opened this issue Jan 13, 2025 · 1 comment
Open

nacos3.0按照官网的说明启动不了,报错(win11系统) #13036

CKKLIN opened this issue Jan 13, 2025 · 1 comment

Comments

@CKKLIN
Copy link

CKKLIN commented Jan 13, 2025

22:23:22:546 ERROR 1240 --- [ main] o.s.boot.SpringApplication : Application run failed

java.lang.NoClassDefFoundError: com/alibaba/nacos/client/logging/NacosLogging
at com.alibaba.cloud.nacos.discovery.logging.NacosLoggingListener.onApplicationEvent(NacosLoggingListener.java:46) ~[spring-cloud-starter-alibaba-nacos-discovery-2021.0.4.0.jar:2021.0.4.0]
at org.springframework.context.event.SimpleApplicationEventMulticaster.doInvokeListener(SimpleApplicationEventMulticaster.java:176) ~[spring-context-5.3.27.jar:5.3.27]
at org.springframework.context.event.SimpleApplicationEventMulticaster.invokeListener(SimpleApplicationEventMulticaster.java:169) ~[spring-context-5.3.27.jar:5.3.27]
at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:143) ~[spring-context-5.3.27.jar:5.3.27]
at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:131) ~[spring-context-5.3.27.jar:5.3.27]
at org.springframework.boot.context.event.EventPublishingRunListener.environmentPrepared(EventPublishingRunListener.java:85) ~[spring-boot-2.7.12.jar:2.7.12]
at org.springframework.boot.SpringApplicationRunListeners.lambda$environmentPrepared$2(SpringApplicationRunListeners.java:66) ~[spring-boot-2.7.12.jar:2.7.12]
at java.base/java.util.ArrayList.forEach(ArrayList.java:1540) ~[na:na]
at org.springframework.boot.SpringApplicationRunListeners.doWithListeners(SpringApplicationRunListeners.java:120) ~[spring-boot-2.7.12.jar:2.7.12]
at org.springframework.boot.SpringApplicationRunListeners.doWithListeners(SpringApplicationRunListeners.java:114) ~[spring-boot-2.7.12.jar:2.7.12]
at org.springframework.boot.SpringApplicationRunListeners.environmentPrepared(SpringApplicationRunListeners.java:65) ~[spring-boot-2.7.12.jar:2.7.12]
at org.springframework.boot.SpringApplication.prepareEnvironment(SpringApplication.java:343) ~[spring-boot-2.7.12.jar:2.7.12]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:301) ~[spring-boot-2.7.12.jar:2.7.12]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1303) ~[spring-boot-2.7.12.jar:2.7.12]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1292) ~[spring-boot-2.7.12.jar:2.7.12]
at com.hmall.item.ItemApplication.main(ItemApplication.java:13) ~[classes/:na]
Caused by: java.lang.ClassNotFoundException: com.alibaba.nacos.client.logging.NacosLogging
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:581) ~[na:na]
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178) ~[na:na]
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521) ~[na:na]
... 16 common frames omitted

进程已结束,退出代码为 1

@KomachiSion
Copy link
Collaborator

Caused by: java.lang.ClassNotFoundException: com.alibaba.nacos.client.logging.NacosLogging

找不到这个类, 应该是你引入的依赖有问题,缺少内容, 我本地启动了一下,3.0的客户端这个类是存在的。

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants