dubbo消费端报错
我把dubbo的服务提供方启动成功了,而且在dubbo管控台里面都看到服务提供方了,但是在执行服务消费方时报错了,报错如下:
Exception in thread "main" org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'demoService': FactoryBean threw exception on object creation; nested exception is java.lang.IllegalStateException: Failed to check the status of the service com.dubbo.provider.DemoService. No provider available for the service com.dubbo.provider.DemoService from the url zookeeper://119.29.169.51:2181/com.alibaba.dubbo.registry.RegistryService?anyhost=true&application=consumer-of-webapp&check=false&default.timeout=5000&dubbo=2.5.4-SNAPSHOT&generic=false&interface=com.dubbo.provider.DemoService&methods=build&pid=5760&side=consumer×tamp=1473523258002 to the consumer 192.168.1.100 use dubbo version 2.5.4-SNAPSHOT
at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.doGetObjectFromFactoryBean(FactoryBeanRegistrySupport.java:173)
at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.getObjectFromFactoryBean(FactoryBeanRegistrySupport.java:102)
at org.springframework.beans.factory.support.AbstractBeanFactory.getObjectForBeanInstance(AbstractBeanFactory.java:1467)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:246)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:191)
at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:1119)
at com.dubbo.provider.Main.main(Main.java:13)
Caused by: java.lang.IllegalStateException: Failed to check the status of the service com.dubbo.provider.DemoService. No provider available for the service com.dubbo.provider.DemoService from the url zookeeper://119.29.169.51:2181/com.alibaba.dubbo.registry.RegistryService?anyhost=true&application=consumer-of-webapp&check=false&default.timeout=5000&dubbo=2.5.4-SNAPSHOT&generic=false&interface=com.dubbo.provider.DemoService&methods=build&pid=5760&side=consumer×tamp=1473523258002 to the consumer 192.168.1.100 use dubbo version 2.5.4-SNAPSHOT
at com.alibaba.dubbo.config.ReferenceConfig.createProxy(ReferenceConfig.java:420)
at com.alibaba.dubbo.config.ReferenceConfig.init(ReferenceConfig.java:300)
at com.alibaba.dubbo.config.ReferenceConfig.get(ReferenceConfig.java:138)
at com.alibaba.dubbo.config.spring.ReferenceBean.getObject(ReferenceBean.java:65)
at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.doGetObjectFromFactoryBean(FactoryBeanRegistrySupport.java:166)
... 6 more
请问是什么原因?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(7)
双网卡的原因??
提供者指定网卡 配置个host http://m.myexception.cn/open-source/2050431.html
只需要讲提供方的接口和javabean打包放到消费方即可。具体还得看下你的消费方dubbo的具体配置。可贴下你的配置代码看看
引用来自“代码天下”的评论
消费端dubbo配置错误,应该是接口bean配置的地方
引用来自“Guest_Main”的评论
之前遇到过 双网卡时找不到提供者
消费端dubbo配置错误,应该是接口bean配置的地方
之前遇到过 双网卡时找不到提供者