Open bootc opened 4 years ago
Team, does anyone know what specifics we need to change to support this?
On the Go side, this should be rather trivial as the lib we use supports that, we'd just have to create the client: https://pkg.go.dev/github.com/go-redis/redis/v8#NewFailoverClient
However, on the C++ side, we'd have to implement all that failover stuff. I don't know how complex that would be.
Also, the current HA model for Icinga 2 + Icinga DB expects one Redis server per Icinga 2 instance, so if you want HA, you just add a second Redis instance. Also note that even if we supported this, you couldn't have two Icinga 2 instances write into the same cluster.
So I don't really see a benefit for Icinga DB in supporting this right now.
one Redis server per Icinga 2 instance
... which ideally runs on the same machine as Icinga 2, so IMAO that feature just doesn’t fit in our concept.
can an external redis cluster be used? i typically use redis-ha cluster in k8s for redis backends.
If it acts like a standard Redis server, it will be fine. I don't know if that's the case. Is redis-ha the same thing as Redis Sentinel?
it's composed of optional haproxy frontend (to manage connections from outside of k8s) and 3 nodes with sentinel.
Wait. If a Redis sentinel cluster can be frontended by a HAproxy, one could also use shuffling DNS or iptables. So we don’t necessarily have to support this by ourselves.
Our production Redis clusters use Sentinel for High Availability. Please add Sentinel support so that Icinga DB can automatically route requests to active nodes in the cluster as necessary.