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

没有覆盖项目里的配置内容 #2

Open
Observer5 opened this issue Sep 26, 2021 · 6 comments
Open

没有覆盖项目里的配置内容 #2

Observer5 opened this issue Sep 26, 2021 · 6 comments

Comments

@Observer5
Copy link

Observer5 commented Sep 26, 2021

config_center配置:
image

阿里云对应的data-id对应的配置:
image

成功拉取了nacos里配置,config里app_name是‘test2',使用http访问到app_name结果还是test2

@Observer5
Copy link
Author

要独立好多data-id分开配置
app_name这里配置不了~

@huangzhhui
Copy link
Member

使用http访问到app_name结果还是test2

这里的代码贴一下

@Observer5
Copy link
Author

Observer5 commented Sep 29, 2021

config_center:
image

nacos qf-clue-amqp config:
image

IndexController:
image

结果输出
image

@Observer5
Copy link
Author

每个配置文件单独配置,比如nacos的配置 data-id:qf-clue-amqp,config_center 配置的listener_config 设置成amqp,然后就可以使用nacos的配置内容覆盖会这合并本地amqp的配置内容
但是 config.php 配置文件的 app_name 怎么使用通过 nacos的配置了

@limingxinleo
Copy link
Member

嗯,确实不够方便,应该加一个 root 的 key 来处理这种情况

@Observer5
Copy link
Author

期待这个特性

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants