Skip to content

Zero-Downtime Rolling Upgrade (2.2.x → 2.3.0)

This guide defines the standard operating procedure (SOP) for upgrading live production fleets from Engula 2.1.x / 2.2.x to Engula 2.3.0 with zero write downtime. The workflow follows a five-stage closed loop: Config Pre-Flight → RDB Format Bridging → Replica-First Replacement → Controlled Primary Failover → Post-Bake v4 Activation.


1. Three Breaking Configuration Changes to Audit Before Upgrade

Before deploying 2.3.0 binaries, update your configuration templates and automation scripts for the three breaking configuration changes introduced in 2.3.0 (see Release Notes):

Parameter 2.3.0 Breaking Change Required Config Migration
engula-earena-min-set-member-size Removed and replaced by engula-earena-min-value-size (default changed from 8 to 16 bytes, range 0–1024, governing Set members, combined Hash field+value length, and compact-encoded Set/Hash blobs) Remove engula-earena-min-set-member-size from engula.conf and set engula-earena-min-value-size 16
engula-rdb-validate-max-drop-ratio Unit changed from percent to parts per million (ppm); default changed from 1 (1%) to 100 (0.01%) with a 128-record minimum floor when non-zero (0 forbids any drop) If an earlier config explicitly set 1 intending 1%, change it to 10000 (leaving 1 now means 1 ppm); otherwise adopt the recommended default 100
engula-redis7-compatibility-level Restricted to startup configuration file only; runtime CONFIG SET modification is no longer accepted Pin the identical level (default 2) statically in engula.conf across every node in the cluster and remove dynamic CONFIG SET calls

Inspect current live settings on source nodes before starting the rollout (parameters absent on older versions return an empty array):

1redis-cli -h <node> -p <port> CONFIG GET engula-rdb
2redis-cli -h <node> -p <port> CONFIG GET engula-rdb-validate-max-drop-ratio
3redis-cli -h <node> -p <port> CONFIG GET engula-earena-min-set-member-size

2. Native RDB Format Compatibility Matrix & Bridging Rules

Engula 2.3.0 writes internal native RDB format v4 by default and natively reads v3 files written by 2.2.2 / 2.2.3. Older binaries cannot read v4 files, and replication capability negotiation (capa engula-rdb) is boolean without negotiating internal RDB sub-versions.

Source Release On-Disk RDB Format Directly Readable by 2.3.0? Upgrade Bridging Requirement
2.1.0 – 2.1.4 Standard REDIS0011 RDB Yes Upgrade replicas first, then primary; enable engula-rdb 1 after the observation window
2.2.0 / 2.2.1 Early unversioned / v1 No Bridge required before binary swap: run CONFIG SET engula-rdb 0 (and persist in engula.conf) on source nodes, complete a fresh BGSAVE to write standard REDIS0011 RDB, then perform the rolling binary upgrade
2.2.2 / 2.2.3 v3 Yes (backward-compatible) Upgrading all replicas before the primary loads v3 snapshots seamlessly; to preserve instant rollback to 2.2.3 during the observation window, temporarily pin engula-rdb 0
Keep

engula-rdb 0 During the 48–72h Observation Window for Instant Rollback Across fleet rollouts, keeping engula-rdb 0 in both live runtime and engula.conf until the upgraded wave has baked cleanly for 48–72 hours guarantees that every snapshot and fullsync stream stays in standard REDIS0011 format — allowing instant binary downgrade or failback to vanilla Redis 7.2 with zero snapshot conversion.


3. Replica-First Rolling Replacement (1% → 10% → 50% → 100% Waves)

Validate the procedure on a 1% canary shard wave first, then expand through 10% → 50% → 100%. Within every shard (1 primary + N replicas), execute these five steps strictly replica-first:

Step 1: Drain Read Traffic from Target Replica & Swap to 2.3.0

  • If applications route read-only queries to replicas, drain the target replica from your proxy or service-discovery pool.
  • Confirm engula-rdb 0 bridging is completed if upgrading from 2.2.0 / 2.2.1 (or if maintaining an instant-downgrade window).
  • Stop the replica cleanly, install the Engula 2.3.0 binary plus the migrated engula.conf, and start the instance.

Step 2: Verify the Four Automated Replica Health Gates

Before proceeding to the next replica in the shard, verify all four gates pass:

1# Gate 1: Confirm engula_release is 2.3.0 while redis_version remains 7.2.14
2redis-cli -h <replica> -p <port> INFO server | grep -E 'redis_version|engula_release'
3
4# Gate 2: Confirm expected hardware SIMD features (avx2/pclmul on x86_64 or neon on ARM64)
5redis-cli -h <replica> -p <port> ENGULA INFO cpu
6
7# Gate 3: Confirm replication link is up and caught up via PSYNC2 or fullsync
8redis-cli -h <replica> -p <port> INFO replication | grep -E 'role:slave|master_link_status:up|master_repl_offset|slave_repl_offset'
9
10# Gate 4: Confirm zero dropped records on the most recent native RDB load
11redis-cli -h <replica> -p <port> ENGULA INFO health | grep 'engula_rdb_last_load_dropped:0'

Step 3: Execute Controlled Primary Failover in a Low-Traffic Window

Once all replicas in the shard are running 2.3.0 and have tracked the primary cleanly for 15–30 minutes with stable used_memory_rss and ENGULA INFO pipeline queue depths, promote an upgraded 2.3.0 replica:

  • Cluster topology: Run CLUSTER FAILOVER on the target 2.3.0 replica.
  • Sentinel topology: Run SENTINEL FAILOVER <master-name> on Sentinel.

SDK clients automatically follow topology gossip to the promoted primary within seconds.

Step 4: Upgrade the Demoted Former Primary

After failover, the former primary demotes to a replica (note: an un-upgraded 2.2.x replica cannot load a v4 native snapshot from a 2.3.0 primary, so either keep engula-rdb 0 on the new primary until the former primary is upgraded, or upgrade the former primary immediately). Swap its binary and engula.conf to 2.3.0, restart, and re-verify the four health gates in Step 2.

Step 5: Re-Enable Native v4 Whole-Block Snapshots (engula-rdb 1)

After the wave completes its 48–72 hour observation period with zero anomalies, enable native v4 whole-block snapshots and fast homogeneous fullsync across all nodes:

1redis-cli -h <node> -p <port> CONFIG SET engula-rdb 1
2redis-cli -h <node> -p <port> CONFIG REWRITE

If any rollback threshold is triggered during the observation window, promote a standby legacy or vanilla Redis 7.2 replica via FAILOVER to revert cleanly within 5 minutes (see Zero Lock-In & 5-Min Live Failback).