You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by GitBox <gi...@apache.org> on 2021/07/27 08:35:27 UTC

[GitHub] [dubbo] yipixiaofeiyang opened a new issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

yipixiaofeiyang opened a new issue #8359:
URL: https://github.com/apache/dubbo/issues/8359


   - [ ] I have searched the [issues](https://github.com/apache/dubbo/issues) of this repository and believe that this is not a duplicate.
   - [ ] I have checked the [FAQ](https://github.com/apache/dubbo/blob/master/FAQ.md) of this repository and believe that this is not a duplicate.
   
   ### Environment
   
   * Dubbo version: 3.0.1
   * Spring 5.3.9
   * Java version: 1.8
   
   ### Steps to reproduce this issue
   最近发现dubbo3.0已经发布好久了,而且也已经第三个版本了. 遂考虑将本地的dubbo-2.7.8升级到3.0.1, 可再项目启动的收报
   `Caused by: java.lang.IllegalArgumentException: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"
   	at org.springframework.util.PropertyPlaceholderHelper.parseStringValue(PropertyPlaceholderHelper.java:174)
   	at org.springframework.util.PropertyPlaceholderHelper.replacePlaceholders(PropertyPlaceholderHelper.java:126)
   	at org.springframework.core.env.AbstractPropertyResolver.doResolvePlaceholders(AbstractPropertyResolver.java:236)
   	at org.springframework.core.env.AbstractPropertyResolver.resolveRequiredPlaceholders(AbstractPropertyResolver.java:210)
   	at org.springframework.core.env.AbstractEnvironment.resolveRequiredPlaceholders(AbstractEnvironment.java:572)
   	at org.apache.dubbo.config.spring.schema.DubboBeanDefinitionParser.resolvePlaceholders(DubboBeanDefinitionParser.java:519)
   	at org.apache.dubbo.config.spring.schema.DubboBeanDefinitionParser.parse(DubboBeanDefinitionParser.java:101)
   	at org.apache.dubbo.config.spring.schema.DubboBeanDefinitionParser.parse(DubboBeanDefinitionParser.java:505)
   	at org.springframework.beans.factory.xml.NamespaceHandlerSupport.parse(NamespaceHandlerSupport.java:74)
   	at org.apache.dubbo.config.spring.schema.DubboNamespaceHandler.parse(DubboNamespaceHandler.java:90)
   	at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustomElement(BeanDefinitionParserDelegate.java:1435)
   	at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustomElement(BeanDefinitionParserDelegate.java:1419)
   	at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.parseBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:172)
   	at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.doRegisterBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:142)
   	at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.registerBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:94)
   	at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.registerBeanDefinitions(XmlBeanDefinitionReader.java:508)
   	at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:392)`
   将dubbo降到2.7.8又能正常启动, 有谁碰到这个问题没? 可以排除的问题:
   1:key值拼写错误
   2:本地自定义spring-*.xml中有多套PropertySources被初始化
   
   Pls. provide [GitHub address] to reproduce this issue.
   
   ### Expected Result
   
   What do you expected from the above steps?
   
   ### Actual Result
   
   What actually happens?
   
   If there is an exception, please attach the exception trace:
   
   ```
   Just put your stack trace here!
   ```
   


-- 
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] kevinw66 commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
kevinw66 commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-887364952


   > > 项目中dubbo相关的配置是怎么样的?
   > > spring-dubbo.xml
   > > `<dubbo:application name="${dubbo.application}">
   > > <dubbo:parameter key="qos.enable" value="false" />
   > > </dubbo:application>
   > > 
   > > <dubbo:registry address="${dubbo.address}"/>
   > > 
   > > <dubbo:metadata-report address="${dubbo.metadata}"/>
   > > <dubbo:config-center address="${dubbo.address}" check="false" timeout="60000"/>
   > 
   > ```
   > <!-- 基础组件 -->
   > <dubbo:reference interface="com.wqh.common.service.CodeGroupService" id="codeGroupService" retries="${dubbo.retries}" check="${dubbo.check}"/>`
   > ```
   > 
   > dubbo.properties
   > `dubbo.application=wqh-app dubbo.address=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181 dubbo.retries=3 dubbo.check=false dubbo.metadata=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181`
   > 
   > ```
   > @kevinw66 
   > ```
   
   用法有点怪。。建议3.0中直接使用注解配置或者properties配置


-- 
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] yipixiaofeiyang commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-888122174


   > > > 项目中dubbo相关的配置是怎么样的?
   > > > spring-dubbo.xml
   > > > `<dubbo:application name="${dubbo.application}">
   > > > <dubbo:parameter key="qos.enable" value="false" />
   > > > </dubbo:application>
   > > > <dubbo:registry address="${dubbo.address}"/>
   > > > <dubbo:metadata-report address="${dubbo.metadata}"/>
   > > > <dubbo:config-center address="${dubbo.address}" check="false" timeout="60000"/>
   > > 
   > > 
   > > ```
   > > <!-- 基础组件 -->
   > > <dubbo:reference interface="com.wqh.common.service.CodeGroupService" id="codeGroupService" retries="${dubbo.retries}" check="${dubbo.check}"/>`
   > > ```
   > > 
   > > 
   > >     
   > >       
   > >     
   > > 
   > >       
   > >     
   > > 
   > >     
   > >   
   > > dubbo.properties
   > > `dubbo.application=wqh-app dubbo.address=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181 dubbo.retries=3 dubbo.check=false dubbo.metadata=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181`
   > > ```
   > > @kevinw66 
   > > ```
   > 
   > 本地也尝试了一下,没办法复现,能否麻烦提供一个demo呢?
   抱歉, 现在才回消息, 我做了个简易的demo, 详情见附件, 方便的话, 帮忙看下
   [dobbo3.zip](https://github.com/apache/dubbo/files/6891489/dobbo3.zip)
   
   感觉是因为dubbo提前加载了PropertyPlaceholder, 导致了spring的PropertySourcesPlaceholderConfigurer没起作用
   


-- 
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] yipixiaofeiyang closed issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"(dubbo 3.0+)

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang closed issue #8359:
URL: https://github.com/apache/dubbo/issues/8359


   


-- 
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] yipixiaofeiyang commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"(dubbo 3.0+)

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-889669426


   @kevinw66 @kylixs 我今天在继续探索3.0的升级过程中, 又发现了个问题. 也和PropertySourcesPropertyResolver相关, 在原有的简易demo上引入了三方sdk, 比如aliyun-oss, 其中也有变量引入${aaa}, 如果采用
   <bean id="propertiesUtil" class="org.springframework.context.support.PropertySourcesPlaceholderConfigurer"></bena>的方式不会报错, 但是采用自定义类集成PropertySourcesPlaceholderConfigurer,如:
   <bean id="propertiesUtil" class="com.wqh.demo.dobbo3.PropertiesUtil">
    又会引发上面的(Could not resolve placeholder)问题, 
    同样, 我把版本回到2.7.8  程序又能正常运行! 请原谅我三番五次的对比和折磨!  因为这对我的项目很重要!
    详情可以参考下面改进后的demo
   [dobbo3-1.zip](https://github.com/apache/dubbo/files/6905569/dobbo3-1.zip)
   


-- 
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] yipixiaofeiyang commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-888271877


   > > > > > > > 项目中dubbo相关的配置是怎么样的?
   > > > > > > > spring-dubbo.xml
   > > > > > > > `<dubbo:application name="${dubbo.application}">
   > > > > > > > <dubbo:parameter key="qos.enable" value="false" />
   > > > > > > > </dubbo:application>
   > > > > > > > <dubbo:registry address="${dubbo.address}"/>
   > > > > > > > <dubbo:metadata-report address="${dubbo.metadata}"/>
   > > > > > > > <dubbo:config-center address="${dubbo.address}" check="false" timeout="60000"/>
   > > > > > > 
   > > > > > > 
   > > > > > > ```
   > > > > > > <!-- 基础组件 -->
   > > > > > > <dubbo:reference interface="com.wqh.common.service.CodeGroupService" id="codeGroupService" retries="${dubbo.retries}" check="${dubbo.check}"/>`
   > > > > > > ```
   > > > > > > 
   > > > > > > 
   > > > > > >     
   > > > > > >       
   > > > > > >     
   > > > > > > 
   > > > > > >       
   > > > > > >     
   > > > > > > 
   > > > > > >     
   > > > > > >   
   > > > > > > dubbo.properties
   > > > > > > `dubbo.application=wqh-app dubbo.address=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181 dubbo.retries=3 dubbo.check=false dubbo.metadata=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181`
   > > > > > > ```
   > > > > > > @kevinw66 
   > > > > > > ```
   > > > > > 
   > > > > > 
   > > > > > 本地也尝试了一下,没办法复现,能否麻烦提供一个demo呢?
   > > > > > 抱歉, 现在才回消息, 我做了个简易的demo, 详情见附件, 方便的话, 帮忙看下
   > > > > > [dobbo3.zip](https://github.com/apache/dubbo/files/6891489/dobbo3.zip)
   > > > > 
   > > > > 
   > > > > 感觉是因为dubbo提前加载了PropertyPlaceholder, 导致了spring的PropertySourcesPlaceholderConfigurer没起作用
   > > > 
   > > > 
   > > > 看了一下,这种用法一直是有问题的。2.7.8不会报错是因为注册的时候直接把beanName设置成了`${dubbo.application}`,而3.0.1里去尝试解析这个变量,发现解析不了就报错了
   > > > ![image](https://user-images.githubusercontent.com/31196226/127297461-6546f7bb-3fa1-4c54-be56-4f168e1492a9.png)
   > > 
   > > 
   > > 这也是spring的标准玩法, 其它框架和spring整合这样是没问题的, 基于这种情况, 用什么方式可以过渡或者运行起来呢?
   > 
   > id或者name配置直接写上,别使用占位符应该是可以的
   
   好的感谢了! 这对于springmvc用户将是个硬伤, 多环境下的properies变量就需要改造了, 这个问题, 要是后续版本能解决, 将会使现有系统升级更加平滑!


-- 
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] yipixiaofeiyang removed a comment on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang removed a comment on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-888198093


   其它框架和spring整合这样是没问题的, 这也是spring的标准玩法, 基于这种情况, 用什么方式可以过渡或者可以运行起来呢?


-- 
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] yipixiaofeiyang closed issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang closed issue #8359:
URL: https://github.com/apache/dubbo/issues/8359


   


-- 
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] kylixs commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"(dubbo 3.0+)

Posted by GitBox <gi...@apache.org>.
kylixs commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-888767092


   @yipixiaofeiyang 这是一个bug,下个版本解决,请指定一个id或者用属性配置方法: 
   ```xml
   <dubbo:application id="application1" name="${dubbo.application}">
     <dubbo:parameter key="qos.enable" value="false" />
   </dubbo:application>
   ```
   或者改为属性配置:
   ```
   dubbo.application.name=wqh-app
   dubbo.application.qos-enable=false
   ```


-- 
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] kevinw66 commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
kevinw66 commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-887344283


   项目中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


[GitHub] [dubbo] kevinw66 commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
kevinw66 commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-888152526


   > > > > 项目中dubbo相关的配置是怎么样的?
   > > > > spring-dubbo.xml
   > > > > `<dubbo:application name="${dubbo.application}">
   > > > > <dubbo:parameter key="qos.enable" value="false" />
   > > > > </dubbo:application>
   > > > > <dubbo:registry address="${dubbo.address}"/>
   > > > > <dubbo:metadata-report address="${dubbo.metadata}"/>
   > > > > <dubbo:config-center address="${dubbo.address}" check="false" timeout="60000"/>
   > > > 
   > > > 
   > > > ```
   > > > <!-- 基础组件 -->
   > > > <dubbo:reference interface="com.wqh.common.service.CodeGroupService" id="codeGroupService" retries="${dubbo.retries}" check="${dubbo.check}"/>`
   > > > ```
   > > > 
   > > > 
   > > >     
   > > >       
   > > >     
   > > > 
   > > >       
   > > >     
   > > > 
   > > >     
   > > >   
   > > > dubbo.properties
   > > > `dubbo.application=wqh-app dubbo.address=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181 dubbo.retries=3 dubbo.check=false dubbo.metadata=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181`
   > > > ```
   > > > @kevinw66 
   > > > ```
   > > 
   > > 
   > > 本地也尝试了一下,没办法复现,能否麻烦提供一个demo呢?
   > > 抱歉, 现在才回消息, 我做了个简易的demo, 详情见附件, 方便的话, 帮忙看下
   > > [dobbo3.zip](https://github.com/apache/dubbo/files/6891489/dobbo3.zip)
   > 
   > 感觉是因为dubbo提前加载了PropertyPlaceholder, 导致了spring的PropertySourcesPlaceholderConfigurer没起作用
   
   看了一下,这种用法一直是有问题的。2.7.8不会报错是因为注册的时候直接把beanName设置成了`${dubbo.application}`,而3.0.1里去尝试解析这个变量,发现解析不了就报错了
   ![image](https://user-images.githubusercontent.com/31196226/127297461-6546f7bb-3fa1-4c54-be56-4f168e1492a9.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


[GitHub] [dubbo] kevinw66 commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
kevinw66 commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-888131840


   > > > > 项目中dubbo相关的配置是怎么样的?
   > > > > spring-dubbo.xml
   > > > > `<dubbo:application name="${dubbo.application}">
   > > > > <dubbo:parameter key="qos.enable" value="false" />
   > > > > </dubbo:application>
   > > > > <dubbo:registry address="${dubbo.address}"/>
   > > > > <dubbo:metadata-report address="${dubbo.metadata}"/>
   > > > > <dubbo:config-center address="${dubbo.address}" check="false" timeout="60000"/>
   > > > 
   > > > 
   > > > ```
   > > > <!-- 基础组件 -->
   > > > <dubbo:reference interface="com.wqh.common.service.CodeGroupService" id="codeGroupService" retries="${dubbo.retries}" check="${dubbo.check}"/>`
   > > > ```
   > > > 
   > > > 
   > > >     
   > > >       
   > > >     
   > > > 
   > > >       
   > > >     
   > > > 
   > > >     
   > > >   
   > > > dubbo.properties
   > > > `dubbo.application=wqh-app dubbo.address=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181 dubbo.retries=3 dubbo.check=false dubbo.metadata=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181`
   > > > ```
   > > > @kevinw66 
   > > > ```
   > > 
   > > 
   > > 本地也尝试了一下,没办法复现,能否麻烦提供一个demo呢?
   > > 抱歉, 现在才回消息, 我做了个简易的demo, 详情见附件, 方便的话, 帮忙看下
   > > [dobbo3.zip](https://github.com/apache/dubbo/files/6891489/dobbo3.zip)
   > 
   > 感觉是因为dubbo提前加载了PropertyPlaceholder, 导致了spring的PropertySourcesPlaceholderConfigurer没起作用
   
   好的,我先看看


-- 
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] kylixs closed issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"(dubbo 3.0+)

Posted by GitBox <gi...@apache.org>.
kylixs closed issue #8359:
URL: https://github.com/apache/dubbo/issues/8359


   


-- 
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] yipixiaofeiyang edited a comment on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang edited a comment on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-887348195


   > 项目中dubbo相关的配置是怎么样的?
   spring-dubbo.xml
   `<dubbo:application name="${dubbo.application}">
       	<dubbo:parameter key="qos.enable" value="false" />
       </dubbo:application>
       <!--使用 zookeeper 注册中心暴露服务,注意要先开启 zookeeper-->
       <dubbo:registry address="${dubbo.address}"/>
       <!-- 元数据 -->
       <dubbo:metadata-report address="${dubbo.metadata}"/>
       <dubbo:config-center address="${dubbo.address}" check="false" timeout="60000"/>
       
       <!-- 基础组件 -->
       <dubbo:reference interface="com.wqh.common.service.CodeGroupService" id="codeGroupService" retries="${dubbo.retries}" check="${dubbo.check}"/>`
   
   dubbo.properties
   `dubbo.application=wqh-app
   dubbo.address=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181
   dubbo.retries=3
   dubbo.check=false
   dubbo.metadata=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181`
   
       
       


-- 
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] yipixiaofeiyang commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-888093328


   - [ ] 
   
   - [ ] 
   
   - [ ] 


-- 
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] yipixiaofeiyang commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"(dubbo 3.0+)

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-888900254


   Waiting upgrade


-- 
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] yipixiaofeiyang removed a comment on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang removed a comment on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-888093328


   - [ ] 
   
   - [ ] 
   
   - [ ] 


-- 
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] yipixiaofeiyang edited a comment on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang edited a comment on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-887348195


   > 项目中dubbo相关的配置是怎么样的?
   spring-dubbo.xml
   `<dubbo:application name="${dubbo.application}">
       	<dubbo:parameter key="qos.enable" value="false" />
       </dubbo:application>
       <!--使用 zookeeper 注册中心暴露服务,注意要先开启 zookeeper-->
       <dubbo:registry address="${dubbo.address}"/>
       <!-- 元数据 -->
       <dubbo:metadata-report address="${dubbo.metadata}"/>
       <dubbo:config-center address="${dubbo.address}" check="false" timeout="60000"/>
       
       <!-- 基础组件 -->
       <dubbo:reference interface="com.wqh.common.service.CodeGroupService" id="codeGroupService" retries="${dubbo.retries}" check="${dubbo.check}"/>`
   
   dubbo.properties
   `dubbo.application=wqh-app
   dubbo.address=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181
   dubbo.retries=3
   dubbo.check=false
   dubbo.metadata=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181`
   
       
       @kevinw66 


-- 
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] yipixiaofeiyang edited a comment on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"(dubbo 3.0+)

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang edited a comment on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-889669426


   @kevinw66 @kylixs 我今天在继续探索3.0的升级过程中, 又发现了个问题. 也和PropertySourcesPropertyResolver相关, 在原有的简易demo上引入了三方sdk, 比如aliyun-oss, 其中也有变量引入${aaa}, 如果采用
   `<bean id="propertiesUtil" class="org.springframework.context.support.PropertySourcesPlaceholderConfigurer"></bena>`
   的方式不会报错, 但是采用自定义类集成PropertySourcesPlaceholderConfigurer,如:
   `<bean id="propertiesUtil" class="com.wqh.demo.dobbo3.PropertiesUtil">`
    又会引发上面的(Could not resolve placeholder)问题, 
    同样, 我把版本回到2.7.8  程序又能正常运行! 请原谅我三番五次的对比和折磨!  因为这对我的项目很重要!
    详情可以参考下面改进后的demo
   [dobbo3-1.zip](https://github.com/apache/dubbo/files/6905569/dobbo3-1.zip)
   


-- 
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] kevinw66 commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
kevinw66 commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-888231627


   > > > > > > 项目中dubbo相关的配置是怎么样的?
   > > > > > > spring-dubbo.xml
   > > > > > > `<dubbo:application name="${dubbo.application}">
   > > > > > > <dubbo:parameter key="qos.enable" value="false" />
   > > > > > > </dubbo:application>
   > > > > > > <dubbo:registry address="${dubbo.address}"/>
   > > > > > > <dubbo:metadata-report address="${dubbo.metadata}"/>
   > > > > > > <dubbo:config-center address="${dubbo.address}" check="false" timeout="60000"/>
   > > > > > 
   > > > > > 
   > > > > > ```
   > > > > > <!-- 基础组件 -->
   > > > > > <dubbo:reference interface="com.wqh.common.service.CodeGroupService" id="codeGroupService" retries="${dubbo.retries}" check="${dubbo.check}"/>`
   > > > > > ```
   > > > > > 
   > > > > > 
   > > > > >     
   > > > > >       
   > > > > >     
   > > > > > 
   > > > > >       
   > > > > >     
   > > > > > 
   > > > > >     
   > > > > >   
   > > > > > dubbo.properties
   > > > > > `dubbo.application=wqh-app dubbo.address=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181 dubbo.retries=3 dubbo.check=false dubbo.metadata=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181`
   > > > > > ```
   > > > > > @kevinw66 
   > > > > > ```
   > > > > 
   > > > > 
   > > > > 本地也尝试了一下,没办法复现,能否麻烦提供一个demo呢?
   > > > > 抱歉, 现在才回消息, 我做了个简易的demo, 详情见附件, 方便的话, 帮忙看下
   > > > > [dobbo3.zip](https://github.com/apache/dubbo/files/6891489/dobbo3.zip)
   > > > 
   > > > 
   > > > 感觉是因为dubbo提前加载了PropertyPlaceholder, 导致了spring的PropertySourcesPlaceholderConfigurer没起作用
   > > 
   > > 
   > > 看了一下,这种用法一直是有问题的。2.7.8不会报错是因为注册的时候直接把beanName设置成了`${dubbo.application}`,而3.0.1里去尝试解析这个变量,发现解析不了就报错了
   > > ![image](https://user-images.githubusercontent.com/31196226/127297461-6546f7bb-3fa1-4c54-be56-4f168e1492a9.png)
   > 
   > 这也是spring的标准玩法, 其它框架和spring整合这样是没问题的, 基于这种情况, 用什么方式可以过渡或者运行起来呢?
   
   id或者name配置直接写上,别使用占位符应该是可以的


-- 
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] yipixiaofeiyang commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-887348195


   > 项目中dubbo相关的配置是怎么样的?
   spring-dubbo.xml
   `<dubbo:application name="${dubbo.application}">
       	<dubbo:parameter key="qos.enable" value="false" />
       </dubbo:application>
       <!--使用 zookeeper 注册中心暴露服务,注意要先开启 zookeeper-->
       <dubbo:registry address="${dubbo.address}"/>
       <!-- 元数据 -->
       <dubbo:metadata-report address="${dubbo.metadata}"/>
       <dubbo:annotation/>
       <dubbo:config-center address="${dubbo.address}" check="false" timeout="60000"/>
       
       <!-- 基础组件 -->
       <dubbo:reference interface="com.wqh.common.service.CodeGroupService" id="codeGroupService" retries="${dubbo.retries}" check="${dubbo.check}"/>`
   
   dubbo.properties
   `dubbo.application=wqh-app
   dubbo.address=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181
   dubbo.retries=3
   dubbo.check=false
   dubbo.metadata=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181`
   
       
       


-- 
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] yipixiaofeiyang commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-888198093


   其它框架和spring整合这样是没问题的, 这也是spring的标准玩法, 基于这种情况, 用什么方式可以过渡或者可以运行起来呢?


-- 
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] kevinw66 commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
kevinw66 commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-887379768


   > > 项目中dubbo相关的配置是怎么样的?
   > > spring-dubbo.xml
   > > `<dubbo:application name="${dubbo.application}">
   > > <dubbo:parameter key="qos.enable" value="false" />
   > > </dubbo:application>
   > > 
   > > <dubbo:registry address="${dubbo.address}"/>
   > > 
   > > <dubbo:metadata-report address="${dubbo.metadata}"/>
   > > <dubbo:config-center address="${dubbo.address}" check="false" timeout="60000"/>
   > 
   > ```
   > <!-- 基础组件 -->
   > <dubbo:reference interface="com.wqh.common.service.CodeGroupService" id="codeGroupService" retries="${dubbo.retries}" check="${dubbo.check}"/>`
   > ```
   > 
   > dubbo.properties
   > `dubbo.application=wqh-app dubbo.address=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181 dubbo.retries=3 dubbo.check=false dubbo.metadata=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181`
   > 
   > ```
   > @kevinw66 
   > ```
   
   本地也尝试了一下,没办法复现,能否麻烦提供一个demo呢?


-- 
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] yipixiaofeiyang commented on issue #8359: Could not resolve placeholder 'dubbo.application' in value "${dubbo.application}"

Posted by GitBox <gi...@apache.org>.
yipixiaofeiyang commented on issue #8359:
URL: https://github.com/apache/dubbo/issues/8359#issuecomment-888198774


   > > > > > 项目中dubbo相关的配置是怎么样的?
   > > > > > spring-dubbo.xml
   > > > > > `<dubbo:application name="${dubbo.application}">
   > > > > > <dubbo:parameter key="qos.enable" value="false" />
   > > > > > </dubbo:application>
   > > > > > <dubbo:registry address="${dubbo.address}"/>
   > > > > > <dubbo:metadata-report address="${dubbo.metadata}"/>
   > > > > > <dubbo:config-center address="${dubbo.address}" check="false" timeout="60000"/>
   > > > > 
   > > > > 
   > > > > ```
   > > > > <!-- 基础组件 -->
   > > > > <dubbo:reference interface="com.wqh.common.service.CodeGroupService" id="codeGroupService" retries="${dubbo.retries}" check="${dubbo.check}"/>`
   > > > > ```
   > > > > 
   > > > > 
   > > > >     
   > > > >       
   > > > >     
   > > > > 
   > > > >       
   > > > >     
   > > > > 
   > > > >     
   > > > >   
   > > > > dubbo.properties
   > > > > `dubbo.application=wqh-app dubbo.address=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181 dubbo.retries=3 dubbo.check=false dubbo.metadata=zookeeper://192.168.11.100:2181?backup=192.168.11.101:2181`
   > > > > ```
   > > > > @kevinw66 
   > > > > ```
   > > > 
   > > > 
   > > > 本地也尝试了一下,没办法复现,能否麻烦提供一个demo呢?
   > > > 抱歉, 现在才回消息, 我做了个简易的demo, 详情见附件, 方便的话, 帮忙看下
   > > > [dobbo3.zip](https://github.com/apache/dubbo/files/6891489/dobbo3.zip)
   > > 
   > > 
   > > 感觉是因为dubbo提前加载了PropertyPlaceholder, 导致了spring的PropertySourcesPlaceholderConfigurer没起作用
   > 
   > 看了一下,这种用法一直是有问题的。2.7.8不会报错是因为注册的时候直接把beanName设置成了`${dubbo.application}`,而3.0.1里去尝试解析这个变量,发现解析不了就报错了
   > ![image](https://user-images.githubusercontent.com/31196226/127297461-6546f7bb-3fa1-4c54-be56-4f168e1492a9.png)
   
   这也是spring的标准玩法, 其它框架和spring整合这样是没问题的,  基于这种情况, 用什么方式可以过渡或者运行起来呢?


-- 
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