@FeignClient(value = "test", url = "${proxy.srvs.test:}")
public interface ISubSysClient {
    /**
     *  ${proxy.srvs.test:}
     *  本地测试的时候http://localhost:18081/test
     *  
     */
    @GetMapping(value = "/sys/sublib/allList", headers = {"Accept=application/json", "Content-Type=application/json"})
    List<PdSub> getSubInfoList();

}  
//此方法可以是在本项目的其他模块,或者是其他项目中,主要是看代理路径的配置
List<PdSub> getSubInfoList();

  

yml中的代理配置
proxy:
  enabled: true
  server: http://168.34.88.62:0987/test

  srvs:
    test: ${proxy.server}

  

相关文章:

  • 2021-09-19
  • 2022-12-23
  • 2021-04-26
  • 2021-10-07
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-09-14
猜你喜欢
  • 2021-06-30
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案