Skip to content

2.9.24

Choose a tag to compare

@mgravell mgravell released this 26 Sep 14:08
· 9 commits to main since this release
2.9.24
307129e

IMPORTANT: this release changes the distribution of pub/sub channels when using cluster:

(this change is specific to pub/sub with regular SUBSCRIBE channels, not "sharded" SSUBSCRIBE channels)

  • pre 2.9.24: all channels would always be routed similarly to key-like routing (and similar to SSUBSCRIBE)
  • from 2.9.24: non-SSUBSCRIBE channels are now randomly distributed to nodes by default, but can optionally use key-like routing by calling .WithKeyRouting() on the RedisChannel value

This change represents a safer, "least surprises" default; most people expect their cluster to help distribute load, including pub/sub load, between nodes. This is especially useful when there are few (or even only a single) channel(s) that dominate the pub/sub load, which is surprisingly common. Without this change, all that load would be handled only by a single server, because the channel my_notifications would be treated similarly to a key, via hash-slot sharding, and all clients would connect to the node serving that slot - when in reality, any node can be used for subscription, with the server distributing events horizontally to all nodes.

If you prefer the routed behaviour: use .WithKeyRouting() before subscribing.


What's Changed

  • Fix 2951 - Sentinel reconnect failure by @mgravell in #2956
  • Remove supported Envoyproxy commands from exclusions. by @sshumakov in #2957
  • Convert to Hex only on Encoding.UTF8.GetString possible exceptions by @jcaspes in #2954
  • eng: prefer Volatile.Read over Thread.VolatileRead by @mgravell in #2960
  • Channel routing: revert normal (non-SSUBSCRIBE) routing to random, with new WithKeyRouting() API to opt into routed by @mgravell in #2958

New Contributors

Full Changelog: 2.9.17...2.9.24