I have 2 Redis servers one master and the other slave(replication). Once the Master is down due to some reasons the slave will become Master and it continues to act as Master till something wrong happens to that server.
I have a nodeJS server from which i want to push data to the Redis which currently running as Master. I have a sentinel which monitors the Redis servers but my question is how to fetch master information from sentinel using nodeJS? and if there is a way, does it automatically push data to alternative redis server without any service restart?