valkey-io / valkey-doc

Other
17 stars 25 forks source link

Create a detailed doc reference for doing rolling upgrades #115

Open madolson opened 1 month ago

madolson commented 1 month ago

For standalone, sentinel, and cluster mode, we should have crisp documentation explaining how to do a rolling upgrade in various configurations.

zuiderkwast commented 1 month ago

In the cluster tutorial, we have this:


Upgrade nodes in a Valkey Cluster

Upgrading replica nodes is easy since you just need to stop the node and restart it with an updated version of Valkey. If there are clients scaling reads using replica nodes, they should be able to reconnect to a different replica if a given one is not available.

Upgrading masters is a bit more complex, and the suggested procedure is:

  1. Use CLUSTER FAILOVER to trigger a manual failover of the master to one of its replicas. (See the Manual failover in this topic.)

  2. Wait for the master to turn into a replica.

  3. Finally upgrade the node as you do for replicas.

  4. If you want the master to be the node you just upgraded, trigger a new manual failover in order to turn back the upgraded node into a master.

Following this procedure you should upgrade one node after the other until all the nodes are upgraded.

madolson commented 1 month ago

I still think we should come up with a separate doc just for doing upgrades instead of putting it just in cluster spec. Thoughts?

zuiderkwast commented 1 month ago

Sure, I just shared what I knew I'd seen somewhere.

madolson commented 1 month ago

Thanks! It was helpful, I wasn't aware of it :) I know I had never read that before.