3

Currently I am using Spring Cloud Consul for service discovery, and would like to use Ribbon to load balance service calls. I was able to successfully load balance across all instances of a service within the same DC (using RestTemplate), but when those services were de-registered it never saw instances of that service in another DC. From a Consul perspective, both data centers are properly connected using WAN-Gossip. Is there something I need to configure in Spring Cloud Consul to "see" other data centers / zones? My ultimate goal is to have load balancing across the service within DC1, with a switch-over to load balancing in DC2 when all instances are down in DC1.

Thanks!

g00glen00b
  • 41,995
  • 13
  • 95
  • 133
J. Saiveau
  • 33
  • 3
  • Consul queries default to the local datacenter – spencergibb Aug 19 '16 at 00:56
  • 1
    There would need to be an enhancement to spring cloud to query another data center. – spencergibb Aug 19 '16 at 00:57
  • Thanks for the response, Spencer - that is what I suspected. I had actually implemented this in the past using Apache Camel, and didn't see anything similar in the Spring Cloud Consul code.Just wanted to make sure I wasn't missing something, – J. Saiveau Aug 19 '16 at 13:33

0 Answers0