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

Nacos升级至2.4.0版本报错 #12541

Closed
17818004048 opened this issue Aug 23, 2024 · 3 comments
Closed

Nacos升级至2.4.0版本报错 #12541

17818004048 opened this issue Aug 23, 2024 · 3 comments

Comments

@17818004048
Copy link

java.lang.RuntimeException: Can not create registry nacos://172.23.250.51:31547/org.apache.dubbo.registry.RegistryService?REGISTRY_CLUSTER=default&application=zxy-cloud-paas-rpc-server&client=curator&dubbo=2.0.2&executor-management-mode=isolation&file-cache=true&group=test&interface=org.apache.dubbo.registry.RegistryService&pid=24884&qos.enable=false&register=false&register-mode=interface&release=3.2.15
at org.apache.dubbo.registry.support.AbstractRegistryFactory.getRegistry(AbstractRegistryFactory.java:105) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.registry.RegistryFactoryWrapper.getRegistry(RegistryFactoryWrapper.java:33) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.registry.RegistryFactory$Adaptive.getRegistry(RegistryFactory$Adaptive.java) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.registry.integration.RegistryProtocol.getRegistry(RegistryProtocol.java:459) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.registry.integration.RegistryProtocol.export(RegistryProtocol.java:266) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.rpc.protocol.ProtocolSecurityWrapper.export(ProtocolSecurityWrapper.java:84) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.rpc.protocol.ProtocolListenerWrapper.export(ProtocolListenerWrapper.java:66) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.qos.protocol.QosProtocolWrapper.export(QosProtocolWrapper.java:79) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.rpc.cluster.filter.ProtocolFilterWrapper.export(ProtocolFilterWrapper.java:58) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.rpc.protocol.ProtocolSerializationWrapper.export(ProtocolSerializationWrapper.java:50) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.rpc.protocol.InvokerCountWrapper.export(InvokerCountWrapper.java:42) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.rpc.Protocol$Adaptive.export(Protocol$Adaptive.java) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.config.ServiceConfig.doExportUrl(ServiceConfig.java:947) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.config.ServiceConfig.exportRemote(ServiceConfig.java:917) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.config.ServiceConfig.exportUrl(ServiceConfig.java:857) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.config.ServiceConfig.doExportUrlsFor1Protocol(ServiceConfig.java:602) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.config.ServiceConfig.doExportUrls(ServiceConfig.java:583) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.config.ServiceConfig.doExport(ServiceConfig.java:540) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.config.ServiceConfig.export(ServiceConfig.java:340) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.config.deploy.DefaultModuleDeployer.exportServiceInternal(DefaultModuleDeployer.java:477) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.config.deploy.DefaultModuleDeployer.exportServices(DefaultModuleDeployer.java:424) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.config.deploy.DefaultModuleDeployer.startSync(DefaultModuleDeployer.java:174) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.config.deploy.DefaultModuleDeployer.start(DefaultModuleDeployer.java:156) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.config.spring.context.DubboDeployApplicationListener.onContextRefreshedEvent(DubboDeployApplicationListener.java:157) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.config.spring.context.DubboDeployApplicationListener.onApplicationEvent(DubboDeployApplicationListener.java:143) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.config.spring.context.DubboDeployApplicationListener.onApplicationEvent(DubboDeployApplicationListener.java:52) ~[dubbo-3.2.15.jar:3.2.15]
at org.springframework.context.event.SimpleApplicationEventMulticaster.doInvokeListener(SimpleApplicationEventMulticaster.java:178) ~[spring-context-5.3.31.jar:5.3.31]
at org.springframework.context.event.SimpleApplicationEventMulticaster.invokeListener(SimpleApplicationEventMulticaster.java:171) ~[spring-context-5.3.31.jar:5.3.31]
at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:145) ~[spring-context-5.3.31.jar:5.3.31]
at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:429) ~[spring-context-5.3.31.jar:5.3.31]
at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:386) ~[spring-context-5.3.31.jar:5.3.31]
at org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:949) ~[spring-context-5.3.31.jar:5.3.31]
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:594) ~[spring-context-5.3.31.jar:5.3.31]
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:147) ~[spring-boot-2.7.18.jar:2.7.18]
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:732) ~[spring-boot-2.7.18.jar:2.7.18]
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:409) ~[spring-boot-2.7.18.jar:2.7.18]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:308) ~[spring-boot-2.7.18.jar:2.7.18]
at com.zxy.cloud.paas.PaaSApplication.main(PaaSApplication.java:28) [classes/:na]
Caused by: java.lang.IllegalStateException: Failed to create nacos naming service client. Reason: server status check failed.
at org.apache.dubbo.registry.nacos.NacosConnectionManager.createNamingService(NacosConnectionManager.java:162) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.registry.nacos.NacosConnectionManager.(NacosConnectionManager.java:69) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.registry.nacos.util.NacosNamingServiceUtils.createNamingService(NacosNamingServiceUtils.java:117) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.registry.nacos.NacosRegistryFactory.createRegistry(NacosRegistryFactory.java:48) ~[dubbo-3.2.15.jar:3.2.15]
at org.apache.dubbo.registry.support.AbstractRegistryFactory.getRegistry(AbstractRegistryFactory.java:95) ~[dubbo-3.2.15.jar:3.2.15]
... 37 common frames omitted
本地相关依赖:
image

@wz826
Copy link

wz826 commented Aug 24, 2024

和hessian关系不大,主要是因为nacos配置为JDK1.8,而JDK17+开始使用按模块引入包语法,不兼容之前的语法,不过一定要运行的话可以加入以下命令:
文件:nacos/bin/startup.sh
JAVA_OPT="${JAVA_OPT} --add-opens java.base/java.lang=ALL-UNNAMED "

@KomachiSion
Copy link
Collaborator

Reason: server status check failed. server的启动状态应该有问题,建议看一下部署的server是否有报错。

@KomachiSion
Copy link
Collaborator

#12573 优化了一下对Server Status的校验逻辑, 再不使用到raft相关的接口上不再直接拦截请求,以保证核心功能的可用性。

但如果一直保持jraft无法选主的情况下, 对应依赖raft的功能仍然会有问题无法使用, 需要介入修复raft选主问题.

@KomachiSion KomachiSion closed this as not planned Won't fix, can't repro, duplicate, stale Sep 2, 2024
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

3 participants