Skip to content

v0.9.4

Choose a tag to compare

@zcalusic zcalusic released this 28 Oct 22:29
· 42 commits to master since this release
v0.9.4

Quorum fixes for datacenters with more than 3 racks, a stats /ping that reflects the datastore, working TCP keepalive timing, and Redis commands with their newer optional arguments.

Upgrade notes

  • /ping on the stats port now answers 503 Service Unavailable ("Datastore is not connected") while the node has no connection to its datastore, instead of always OK. Health checks using it will now fail in that state, and pass again by themselves once the node reconnects.
  • A datacenter can have at most 8 racks: a node whose seeds list more doesn't start, and a peer found later in a 9th rack is left out, with an error in the log.
  • CLIENT SETINFO accepts only lib-name and lib-ver; other attributes get Redis's error.
  • Peer and datastore connections now really use a 15 second keepalive: an unresponsive peer is dropped after about 75 seconds instead of the system's default (2 hours idle on Linux).
  • The log file is created with mode 0644 and the daemon runs with umask 022 (they could end up world-writable before).
  • A client dropping a stats request before the reply is logged as a rate-limited warning (once per 10 seconds, with a count) instead of an error each time.

Fixes

  • With more than 3 racks in a datacenter, DC_QUORUM and the stricter consistency levels could hang requests, return a minority's reply, or crash the node. A quorum is now more than half of the racks giving the same reply, counted over all replies, including per element for MGET and other multi-key replies.
  • The 15 second TCP keepalive was asked for but only SO_KEEPALIVE was set, so NATs and firewalls that drop idle connections could silently cut quiet peer links. TCP_KEEPIDLE, TCP_KEEPINTVL and TCP_KEEPCNT are set now.
  • Redis commands with newer optional arguments were refused with "wrong number of arguments" or closed the connection: EXPIRE/EXPIREAT/PEXPIRE/PEXPIREAT with NX|XX|GT|LT, ZRANK/ZREVRANK with WITHSCORE, LPUSHX/RPUSHX with several elements, RESTORE with its options, multi-hash SCRIPT EXISTS, SCRIPT FLUSH ASYNC|SYNC, QUIT with an argument and multi-section INFO. Checked against Valkey 9.1.3 and 8.1.1 and Redis 8.0.2.
  • The "FORWARD FAILED" log line showed the wrong error text, and requests whose rewrite or split failed got "Unknown error -1"; they get "Unknown Error" now.
  • On 32-bit builds, log lines with request ids, timestamps and counts were printed wrong. A peer message type past the last known one is now a parse error instead of being kept or wrapped.

Build and testing

  • Warning-free builds on 32-bit and with clang.
  • New unit and functional tests for quorum with up to 8 racks, keepalive timers, /ping and dropped stats requests, the Redis optional arguments, and the log file mode; one datacenter of the DC_EACH_SAFE_QUORUM test cluster has 4 racks now.

Full Changelog: v0.9.3...v0.9.4