-
-
Notifications
You must be signed in to change notification settings - Fork 10.2k
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
创建多个不同的AppId的Config有多个bug #5159
Comments
com.ctrip.framework.apollo.util.ConfigUtil#getAppId |
总结一下有两处bug 2.app.id有缓存; 创建第二个config的时候, 无法指定新的app.id; app.id是全局的, 就算能修改, 也会影响其他config |
apollo-client 还没有支持多 app.id,你这个是自己实现的吗? |
是的, 简易修改的代码; 阅读apollo-client代码之后, 感觉apollo-client更像是一个简单的实例, 如果能支持多实例就好了 |
This issue has been automatically marked as stale because it has not had activity in the last 30 days. It will be closed in 7 days unless it is tagged "help wanted" or other activity occurs. Thank you for your contributions. |
This issue has been automatically closed because it has not had activity in the last 7 days. If this issue is still valid, please ping a maintainer and ask them to label it as "help wanted". Thank you for your contributions. |
描述bug
创建多个不同的AppId的Config有多个bug
1.com.ctrip.framework.apollo.ConfigService#getConfig
通过DefaultConfigManager创建getConfig, 内置
private Map<String, Config> m_configs = Maps.newConcurrentMap();
key是namespace, 但是不同的appid下的namespace可以相同, 然而apollo中还有集群这个维度, 所以这里简单的用namespace不合理
2.手动避开namespace重复问题, 虽然能get不同的config, 但是第二个config无法获取配置
这是配置1 可以正常获取
这是配置2, 无法获取配置
这是证明只创建一个配置2, 可以正常获取配置的截图
简洁明了地描述一下bug
复现
通过如下步骤可以复现:
期望
简介明了地描述你希望正常情况下应该发生什么
截图
如果可以,附上截图来描述你的问题
额外的细节和日志
The text was updated successfully, but these errors were encountered: