You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by "11huangxing (via GitHub)" <gi...@apache.org> on 2023/03/14 08:11:23 UTC

[GitHub] [dubbo] 11huangxing opened a new issue, #11822: springboot+dubbo项目,dubbo从2.7.19升级至3.1.7后启动报错,找不到ApplicationConfig类

11huangxing opened a new issue, #11822:
URL: https://github.com/apache/dubbo/issues/11822

   dubbo从2.7.19升级到3.1.7,报启动失败, component required a bean of type 'org.apache.dubbo.config.ApplicationConfig' that could not be found;
   恢复到2.7.19版本又可以正常启动;求教各位大神如何解决


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] teleJa commented on issue #11822: springboot+dubbo项目,dubbo从2.7.19升级至3.1.7后启动报错,找不到ApplicationConfig类

Posted by "teleJa (via GitHub)" <gi...@apache.org>.
teleJa commented on issue #11822:
URL: https://github.com/apache/dubbo/issues/11822#issuecomment-1566615816

   ## getApplicationConfig
   getBean(ApplicationModel.class).getCurrentConfig();
   
   ## getProtocolConfig
   getBean(ConfigManager.class).getProtocol(DUBBO_PROTOCOL);
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] songxiaosheng commented on issue #11822: springboot+dubbo项目,dubbo从2.7.19升级至3.1.7后启动报错,找不到ApplicationConfig类

Posted by "songxiaosheng (via GitHub)" <gi...@apache.org>.
songxiaosheng commented on issue #11822:
URL: https://github.com/apache/dubbo/issues/11822#issuecomment-1467901642

   > > 项目中哪里注入了ApplicationConfig吗 version:2.7.19 ApplicationConfig会默认给Spring管理
   > 
   > 引用到的地方挺多的,都是类似这样引用的;
   > ![image](https://user-images.githubusercontent.com/127729798/224978301-78ec2870-801b-4ec2-b5f2-b646a0c947e1.png)
   > 
   
   spring配置文件中的dubbo application这个标签还在么


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] KamToHung commented on issue #11822: springboot+dubbo项目,dubbo从2.7.19升级至3.1.7后启动报错,找不到ApplicationConfig类

Posted by "KamToHung (via GitHub)" <gi...@apache.org>.
KamToHung commented on issue #11822:
URL: https://github.com/apache/dubbo/issues/11822#issuecomment-1467818481

   项目中哪里注入了ApplicationConfig吗


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] AlbumenJ commented on issue #11822: springboot+dubbo项目,dubbo从2.7.19升级至3.1.7后启动报错,找不到ApplicationConfig类

Posted by "AlbumenJ (via GitHub)" <gi...@apache.org>.
AlbumenJ commented on issue #11822:
URL: https://github.com/apache/dubbo/issues/11822#issuecomment-1473143415

   > > > > 项目中哪里注入了ApplicationConfig吗 version:2.7.19 ApplicationConfig会默认给Spring管理
   > > > 
   > > > 
   > > > 引用到的地方挺多的,都是类似这样引用的;
   > > > ![image](https://user-images.githubusercontent.com/127729798/224978301-78ec2870-801b-4ec2-b5f2-b646a0c947e1.png)
   > > 
   > > 
   > > spring配置文件中的dubbo application这个标签还在么
   > 
   > 在的,是不是在dubbo3.x版本不能像2.7.19里面那么使用才导致的问题? 我是个程序员小白,不知道应该怎么去用他,项目中好多地方用到了dubbo的原生类,现在升了版本都不能用 ,还请大神指导一下
   
   注入 ApplicationConfig 的行为能不能删除,这个是 Dubbo 内置的配置对象,如果不是通过 Spring 注入的,不应该通过 Resource 去获取


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] 11huangxing commented on issue #11822: springboot+dubbo项目,dubbo从2.7.19升级至3.1.7后启动报错,找不到ApplicationConfig类

Posted by "11huangxing (via GitHub)" <gi...@apache.org>.
11huangxing commented on issue #11822:
URL: https://github.com/apache/dubbo/issues/11822#issuecomment-1467912537

   > > > 项目中哪里注入了ApplicationConfig吗 version:2.7.19 ApplicationConfig会默认给Spring管理
   > > 
   > > 
   > > 引用到的地方挺多的,都是类似这样引用的;
   > > ![image](https://user-images.githubusercontent.com/127729798/224978301-78ec2870-801b-4ec2-b5f2-b646a0c947e1.png)
   > 
   > spring配置文件中的dubbo application这个标签还在么
   
   在的,是不是在dubbo3.x版本不能像2.7.19里面那么使用才导致的问题?  我是个程序员小白,不知道应该怎么去用他,项目中好多地方用到了dubbo的原生类,现在升了版本都不能用 ,还请大神指导一下


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


Re: [I] springboot+dubbo项目,dubbo从2.7.19升级至3.1.7后启动报错,找不到ApplicationConfig类 [dubbo]

Posted by "wxbty (via GitHub)" <gi...@apache.org>.
wxbty closed issue #11822: springboot+dubbo项目,dubbo从2.7.19升级至3.1.7后启动报错,找不到ApplicationConfig类
URL: https://github.com/apache/dubbo/issues/11822


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] teleJa commented on issue #11822: springboot+dubbo项目,dubbo从2.7.19升级至3.1.7后启动报错,找不到ApplicationConfig类

Posted by "teleJa (via GitHub)" <gi...@apache.org>.
teleJa commented on issue #11822:
URL: https://github.com/apache/dubbo/issues/11822#issuecomment-1567083280

   1.代码变更如图
   ![image](https://github.com/apache/dubbo/assets/48516499/9b58bd49-3567-41d9-8609-9d5d527fba05)
   ![image](https://github.com/apache/dubbo/assets/48516499/7f9d4cb5-25ff-45b6-9aef-b1c2ad48fd21)
   除了获取ConfigManager,也可以使用注入DubboConfigurationProperties获取dubbo的config
   2.兼容方式,可以自己写个类实现BeanDefinitionRegistryPostProcessor,ApplicationContextAware获取DubboConfigurationProperties后再获取ApplicationConfig注入到容器中


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] KamToHung commented on issue #11822: springboot+dubbo项目,dubbo从2.7.19升级至3.1.7后启动报错,找不到ApplicationConfig类

Posted by "KamToHung (via GitHub)" <gi...@apache.org>.
KamToHung commented on issue #11822:
URL: https://github.com/apache/dubbo/issues/11822#issuecomment-1467816157

   在项目注入了ApplicationConfig


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] KamToHung commented on issue #11822: springboot+dubbo项目,dubbo从2.7.19升级至3.1.7后启动报错,找不到ApplicationConfig类

Posted by "KamToHung (via GitHub)" <gi...@apache.org>.
KamToHung commented on issue #11822:
URL: https://github.com/apache/dubbo/issues/11822#issuecomment-1467946081

   > 
   
   
   
   > > > > 项目中哪里注入了ApplicationConfig吗 version:2.7.19 ApplicationConfig会默认给Spring管理
   > > > 
   > > > 
   > > > 引用到的地方挺多的,都是类似这样引用的;
   > > > ![image](https://user-images.githubusercontent.com/127729798/224978301-78ec2870-801b-4ec2-b5f2-b646a0c947e1.png)
   > > 
   > > 
   > > spring配置文件中的dubbo application这个标签还在么
   > 
   > 在的,是不是在dubbo3.x版本不能像2.7.19里面那么使用才导致的问题? 我是个程序员小白,不知道应该怎么去用他,项目中好多地方用到了dubbo的原生类,现在升了版本都不能用 ,还请大神指导一下
   
   <dubbo:application name="demo-provider"/> 这个配置在吗,这个标签就是自己定义了一个Bean了


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo] 11huangxing commented on issue #11822: springboot+dubbo项目,dubbo从2.7.19升级至3.1.7后启动报错,找不到ApplicationConfig类

Posted by "11huangxing (via GitHub)" <gi...@apache.org>.
11huangxing commented on issue #11822:
URL: https://github.com/apache/dubbo/issues/11822#issuecomment-1467860219

   > 项目中哪里注入了ApplicationConfig吗 version:2.7.19 ApplicationConfig会默认给Spring管理
   
   引用到的地方挺多的,都是想这样引用的;
   ![image](https://user-images.githubusercontent.com/127729798/224977952-d0abc87d-cd0d-4a36-b1ed-b39aaaff5628.png)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org