3

docker 容器化部署与 feign 服务调用问题

 1 year ago
source link: https://www.v2ex.com/t/874958
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

V2EX  ›  问与答

docker 容器化部署与 feign 服务调用问题

  overthemoon · 2 小时 11 分钟前 · 397 次点击

原来项目使用 feign 进行服务调用的,现在用原来的代码给甲方公司进行二次开发,甲方需要通过 docker-swarm 进行容器化部署和服务治理。
现在问题是,甲方需要我们服务之间调用需要通过 resttemplate ,就是传一个域名,通过 docker 进行 dns 解析然后进行服务调用。
原来项目里面充斥着大量的 feign 调用的业务代码,如果通过 resttemplate 调用需要手动拼接各种东西。
请问,有没有一种办法,既兼容甲方的 docker 容器化部署方式,又兼容 feign 的负载均衡的调用方式呢?

第 1 条附言  ·  24 分钟前

我们架构师说容器化部署后,naocs 地址会变,不能用 nacos

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK