Implement failover with Kong

I’m working on a system with a central site, and some ports connected to it.
The ports uses the micro-services of the central site. But when the connection is lost with the central, it uses its local micro-services.
I would like to implement the failover between the central site and the port with Kong when the connection is lost, but even I have read several times the comments in Failover API handling, I’m a bit lost…

So far now, I have configured an upstream with 2 targets, one pointing to the central service, with weight = 100, and another one pointing to the local service, with weight = 1.

  • Can I be sure, with such configuration, that Kong will always redirect my requests to the central as long as the connection is ok?

Moreover, I have understood that the healthy check mechanism allowed to set target as healthy/unhealthy ==> With this configuration (I mean configured weight for each service) and healthy check mechanism correctly configured, will Kong switch automatically my requests to the local service in case the central one becomes unavailable ?

Lastly : I would like to set up a mixed active/passive healthy check against my services, but I have not really found relevant examples. In most examples I have found, we keep the default values for the parameters . Could you please point me to relevant examples .
Thanks a lot.

© 2019 Kong Inc.    Terms  •  Privacy  •  FAQ