Update module github.com/redis/go-redis/v9 to v9.20.0 #107

Merged
mfenniak merged 1 commit from renovate/github.com-redis-go-redis-v9-9.x into main 2026-06-09 01:57:55 +00:00
Member

This PR contains the following updates:

Package Change Age Confidence
github.com/redis/go-redis/v9 v9.17.3v9.20.0 age confidence

Release Notes

redis/go-redis (github.com/redis/go-redis/v9)

v9.20.0: 9.20.0

Compare Source

🚀 Highlights

Redis 8.8 Support

This release adds support for Redis 8.8. The README's supported-versions list now includes Redis 8.8 alongside 8.0/8.2/8.4, and CI exercises the 8.8 client-libs-test image across the full suite (Makefile, build workflow, doctests, run-tests action, and docker-compose).

Coverage for the new commands that ship in the 8.x line, rounded out in this release:

  • AR* array data type (#​3813) — new array data structure, exposed via the ArrayCmdable interface (see the experimental-features highlight below).
  • INCREX (#​3816) — atomic increment with expiration in a single round-trip.
  • XNACK (#​3790) — explicit negative-acknowledge of pending stream entries.
  • XAUTOCLAIM PEL deletes (#​3798) — XAUTOCLAIM/XAUTOCLAIMJUSTID now return the list of deleted message IDs from the pending entries list.
  • TS.RANGE multiple aggregators (#​3791) — TS.RANGE/TS.REVRANGE/TS.MRANGE/TS.MREVRANGE accept multiple aggregators in a single call.
  • Z(UNION|INTER|DIFF) COUNT aggregator (#​3802) — COUNT reducer for sorted-set set operations.
  • JSON.SET FPHA (#​3797) — new FPHA argument that specifies the floating-point type for homogeneous FP arrays.

CI image bump (#​3814) by @​ofekshenawa. Command coverage contributions by @​cxljs, @​elena-kolevska, @​Khukharr, @​ndyakov, and @​ofekshenawa.

Stable RESP3 for RediSearch (UnstableResp3 deprecated)

FT.SEARCH, FT.AGGREGATE, FT.INFO, FT.SPELLCHECK, and FT.SYNDUMP now parse RESP3 (map) responses into the same typed result objects as RESP2 — Val() and Result() work uniformly on both protocols, no flag required. Previously, RESP3 search responses required UnstableResp3: true and were returned as opaque maps accessible only via RawResult() / RawVal().

As a result, the UnstableResp3 option is now a no-op across every options struct (Options, ClusterOptions, UniversalOptions, FailoverOptions, RingOptions) and has been marked // Deprecated:. The field is retained for backwards compatibility — existing code that sets UnstableResp3: true will continue to compile and behave identically — but it will be removed in a future release and new code should not set it. RawResult() / RawVal() continue to work for callers that prefer the raw RESP payload.

(#​3741) by @​ndyakov

Experimental Array Data Structure Commands

Adds an experimental ArrayCmdable interface with the AR* command family (ARSet, ARGet, ARGetRange, ARMSet, ARMGet, ARDel, ARDelRange, ARScan, ARSeek, ARNext, ARLastItems, ARGrep, ARGrepWithValues, ARInfo/ARInfoFull, and typed reducers AROpSum/AROpMin/AROpMax/AROpAnd/AROpOr/AROpXor/AROpMatch/AROpUsed) for working with Redis 8.8's new array data type. API is experimental and may change in a future release.

(#​3813) by @​cxljs

New Features

  • RESP3 search parser: First-class RESP3 parsing for FT.SEARCH/FT.AGGREGATE/FT.INFO/FT.SPELLCHECK/FT.SYNDUMP responses with backwards compatibility for RESP2 (#​3741) by @​ndyakov
  • INCREX: New INCREX command support — atomic increment with expiration (#​3816) by @​ndyakov
  • XNACK: Client support for the XNACK stream command for explicitly negative-acknowledging pending entries (#​3790) by @​elena-kolevska
  • TS range multiple aggregators: TS.RANGE/TS.REVRANGE/TS.MRANGE/TS.MREVRANGE now accept multiple aggregators in a single call (#​3791) by @​elena-kolevska
  • XAutoClaim deleted IDs: XAUTOCLAIM/XAUTOCLAIMJUSTID now return the list of deleted message IDs from the PEL (#​3798) by @​Khukharr
  • JSON.SET FPHA: JSON.SET accepts a new FPHA argument that specifies the floating-point type for homogeneous floating-point arrays (#​3797) by @​ndyakov
  • Sorted-set union/intersection COUNT: ZUNION/ZINTER/ZDIFF aggregator now supports COUNT (#​3802) by @​ofekshenawa
  • FT.HYBRID vector validation: Validates hybrid-search vector input types and adds proper typed vector parameters (#​3756) by @​DengY11
  • Cluster pool wait stats: ClusterClient.PoolStats() now accumulates WaitCount and WaitDurationNs across all node pools (previously always zero) (#​3809) by @​LINKIWI

🐛 Bug Fixes

  • TLS-only Cluster PubSub: CLUSTER SLOTS port-0 entries now fall back to the origin endpoint's port, fixing dial tcp <ip>:0: connection refused on TLS-only clusters started with --port 0 --tls-port <port> (fixes #​3726) (#​3828) by @​ndyakov
  • Sharded PubSub reconnect routing: PubSub.conn() now passes both regular (c.channels) and sharded (c.schannels) channels into the per-PubSub newConn closure. Previously, ClusterClient.SSubscribe-only PubSubs reconnected to a random node (because the routing closure saw an empty channel list), the SSUBSCRIBE was sent to the wrong shard, and the resulting MOVED reply was silently dropped (#​3829) by @​ndyakov
  • ClusterClient Watch retry: User errors returned from a Watch callback are no longer subjected to cluster-retry classification; transient cluster errors still retry, but a callback returning e.g. net.ErrClosed short-circuits immediately (#​3821) by @​obiyang
  • Sentinel concurrent-probe leak: MasterAddr's concurrent sentinel probe now closes the non-winning sentinel clients instead of leaking them (#​3827) by @​cxljs
  • Sentinel rediscovery loop on master-only setups: replicaAddrs no longer tears down the cached sentinel client when the replica list is empty, eliminating a continuous rediscovery loop on master-only Sentinel deployments that flooded logs and added per-operation latency (#​3795) by @​shahyash2609
  • Pool CloseConn hooks: Pool.CloseConn now triggers registered hooks, fixing a memory leak when connections are closed explicitly rather than via the normal removal path (#​3818) by @​ndyakov
  • Dial TCP error redirection: Wrapped dial tcp errors are now correctly classified as redirectable so cluster routing can recover from a single unreachable node (#​3810) by @​vladisa88
  • Pool Close health checks: ConnPool.Close now only runs health checks against idle connections, avoiding spurious activity on connections still in use (#​3805) by @​ndyakov
  • VLinks return type: Fixed the return type of VLINKS/VLINKSWITHSCORES vector-set replies (#​3820) by @​romanpovol

🧪 Testing & Infrastructure

  • Flaky tests: Stabilized several flaky tests in the sentinel and pool suites (#​3815) by @​ndyakov
  • Sentinel failover metric race: Fixed a data race in the sentinel failover metric test (#​3824) by @​cxljs
  • waitForSentinelClusterStable post-conditions: The sentinel test harness now waits for replicas to be fully connected (not just present in the count) and is robust to randomized spec ordering after failover specs, eliminating an intermittent Expected master to equal slave flake (#​3830) by @​ndyakov
  • govulncheck workflow: New scheduled GitHub Actions workflow runs govulncheck on every push, PR, and weekly, surfacing newly disclosed Go vulnerabilities even when no code changes (#​3779) by @​solardome
  • CI Redis 8.8-rc1: CI now exercises the 8.8-rc1 Redis image (#​3814) by @​ofekshenawa

🧰 Maintenance

  • Cmd.Slot() lookup refactor: Caches the per-command CommandInfo and short-circuits keyless commands before the switch dispatch, removing redundant Peek calls (#​3804) by @​retr0-kernel
  • stdlib math/rand: Replaced internal/rand with math/rand from the standard library now that the minimum Go version is 1.24 (#​3823) by @​cxljs
  • ConnPool queue channel: Removed the unused queue channel from ConnPool, trimming the pool's footprint (#​3826) by @​cxljs
  • Extra packages LICENSE: Added a LICENSE file to each extra/* package (#​3817) by @​ndyakov
  • README & CI image: Documentation refresh and bumped the default CI image tag (#​3822) by @​ndyakov

👥 Contributors

We'd like to thank all the contributors who worked on this release!

@​cxljs, @​DengY11, @​elena-kolevska, @​Khukharr, @​LINKIWI, @​ndyakov, @​obiyang, @​ofekshenawa, @​retr0-kernel, @​romanpovol, @​shahyash2609, @​solardome, @​vladisa88


Full Changelog: https://github.com/redis/go-redis/compare/v9.19.0...v9.20.0

v9.19.0: 9.19.0

Compare Source

🚀 Highlights

FIPS-Compatible Script Helper

Script now supports a FIPS-safe execution mode that avoids client-side SHA-1 computation, which is blocked in strict FIPS environments. A new NewScriptServerSHA constructor uses SCRIPT LOAD to obtain and cache the digest from the server, then runs commands via EVALSHA/EVALSHA_RO. Falls back to EVAL/EVALRO if loading fails, and transparently retries once on NOSCRIPT. The default behavior is unchanged for existing users.

(#​3700) by @​chaitanyabodlapati

FT.AGGREGATE Step-Based Pipeline Builder

Added a new step-based FT.AGGREGATE pipeline API via FTAggregateOptions.Steps, allowing LOAD, APPLY, GROUPBY, and SORTBY (with per-step MAX) to be repeated and interleaved in arbitrary order — matching Redis's native multi-stage aggregation semantics. The legacy Load/Apply/GroupBy/SortBy/SortByMax fields are now deprecated.

(#​3782) by @​ndyakov

Raw RESP Protocol Access

Added DoRaw and DoRawWriteTo methods for executing arbitrary commands and reading the raw RESP response. Useful for proxying, custom protocol inspection, and working with commands not yet wrapped by go-redis.

(#​3713) by @​ofekshenawa

Configurable Dial Retry Backoff

Added DialerRetryBackoff option (plumbed through Options, ClusterOptions, RingOptions, FailoverOptions) to let callers customize the delay between failed dial attempts. Helpers DialRetryBackoffConstant and DialRetryBackoffExponential (with jitter and cap) are provided out of the box. Dial timeout is now also applied per attempt rather than across all retries.

(#​3706, #​3705) by @​mwhooker

New Features

  • FT.AGGREGATE Steps: Step-based pipeline builder for FT.AGGREGATE with support for repeated/interleaved LOAD, APPLY, GROUPBY, and SORTBY stages (#​3782) by @​ndyakov
  • VectorSet commands: Added VISMEMBER and WITHATTRIBS support (#​3753) by @​romanpovol
  • FIPS-safe Script: NewScriptServerSHA uses SCRIPT LOAD to obtain the digest from the server, avoiding client-side SHA-1 (#​3700) by @​chaitanyabodlapati
  • Raw RESP access: DoRaw and DoRawWriteTo for raw RESP protocol access (#​3713) by @​ofekshenawa
  • Dial retry backoff: DialerRetryBackoff function option with constant and exponential helpers (#​3706) by @​mwhooker
  • Typed NOSCRIPT error: Redis NOSCRIPT replies are now surfaced as a typed error for easier handling (#​3738) by @​LINKIWI
  • PubSub ClientSetName: Added ClientSetName method to PubSub (#​3727) by @​Flack74
  • ReplicaOf: New ReplicaOf method replaces the deprecated SlaveOf (#​3720) by @​Copilot
  • HSCAN BinaryUnmarshaler: HScan now supports types implementing encoding.BinaryUnmarshaler (#​3768) by @​Aaditya-dubey1

🐛 Bug Fixes

  • Auto hostname type detection: Improved endpoint type detection for maintenance notifications using DNS-based classification; handles empty hosts and expanded private-IP ranges (#​3789) by @​ndyakov
  • HELLO fallback: Don't send CLIENT MAINT_NOTIFICATIONS handshake when HELLO fails and connection falls back to RESP2; fail fast when explicitly enabled with RESP3 (#​3788) by @​ndyakov
  • Dial TCP retry: ShouldRetry now treats net.OpError with Op == "dial" timeout errors as safe to retry since no command was sent (#​3787) by @​vladisa88
  • wrappedOnClose leak: Fixed resource leak caused by repeatedly wrapping baseClient close logic; replaced with a bounded, concurrency-safe named-hook registry (#​3785) by @​ndyakov
  • Pool Close() on stale connections: Suppress close errors (e.g., TLS closeNotify timeouts) for connections already dropped by the server due to idle timeout (#​3778) by @​ofekshenawa
  • FIFO waiter ordering: Fixed race in ConnStateMachine.notifyWaiters that could wake multiple waiters under a single mutex hold and violate FIFO ordering (#​3777) by @​0x48core
  • Lua READONLY detection: Detect READONLY errors embedded in Lua script error messages on read-only replicas so commands are correctly retried (#​3769) by @​zhengjilei
  • VectorScoreSliceCmd RESP2: Fixed VSimWithScores, VSimWithArgsWithScores, and VLinksWithScores which were broken on RESP2 connections returning flat arrays instead of maps (#​3767) by @​Copilot
  • Closed connection handling: Two fixes for closed connection handling in the pool (#​3764) by @​cxljs
  • ZRangeArgs Rev: Fixed ZRangeArgs with Rev + ByScore/ByLex incorrectly swapping Start/Stop, breaking ZRANGESTORE (#​3751) by @​Copilot
  • OTel metric instrument types: Fixed metric instrument types in redisotel-native (#​3743) by @​ofekshenawa
  • Options.clone() data race: Fixed data race when cloning Options (#​3739) by @​rubensayshi
  • Connection closure metrics: Fixed connection closure metrics and enabled all metric groups by default in redisotel-native (#​3735) by @​ofekshenawa
  • OTel semconv v1.38.0: Use metric definition from otel/semconv/v1.38.0 in redisotel-native (#​3731) by @​wzy9607
  • SETNX semantics: Use SET ... NX instead of the deprecated SETNX command (#​3723) by @​ndyakov
  • TIME keyless routing: Mark TIME as a keyless command for correct cluster routing (#​3722) by @​fatal10110
  • Dial timeout per retry: Dial timeout now applies per attempt instead of across all retry attempts combined (#​3705) by @​mwhooker
  • Cluster metrics attributes: Fixed pool.name being appended per node, which corrupted and dropped user-provided custom attributes (#​3699) by @​Jesse-Bonfire
  • initConn nil dereference: Fixed nil pointer dereference and potential deadlock in *baseClient.initConn(); added explicit nil option guards to client constructors (#​3676) by @​olde-ducke

Performance

  • RESP reader: Optimized RESP reader by eliminating intermediate string allocations (#​3774) by @​Aaditya-dubey1
  • Inline rendezvous hashing: Replaced github.com/dgryski/go-rendezvous dependency with an in-repo implementation in internal/hashtag, reducing the dependency graph while preserving algorithm parity (#​3762) by @​bigsk05

🧪 Testing & Infrastructure

  • Release automation: Added repository, ref, and client-libs-test-image-tag inputs to the run-tests composite action; redis-version is now optional so unstable builds use REDIS_VERSION from the Makefile (#​3749) by @​dariaguy
  • Go 1.24: Updated minimum Go version to 1.24 and use -compat=1.24 in release scripts (#​3714, #​3754) by @​ndyakov, @​cxljs

🧰 Maintenance

  • Pool state machine: Removed redundant Conn.closed atomic field in favor of the state machine's StateClosed (#​3783) by @​cxljs
  • OTel SDK: Updated OpenTelemetry SDK dependencies in redisotel/redisotel-native (#​3770) by @​ndyakov
  • Go 1.21+ built-ins: Use maps.Keys, slices.Collect, slices.Contains, clear(), and slices.SortFunc instead of custom helpers (#​3758, #​3746) by @​cxljs
  • HGetAll docs: Added Go doc comment to HGetAll describing behavior and complexity (#​3776) by @​0x48core
  • Docs links: Fixed irrelevant docs links (#​3724) by @​olzhas-sabiyev
  • Examples cleanup: Removed throughput binary from examples (#​3733) by @​ndyakov

👥 Contributors

We'd like to thank all the contributors who worked on this release!

@​0x48core, @​Aaditya-dubey1, @​Copilot, @​Flack74, @​Jesse-Bonfire, @​LINKIWI, @​bigsk05, @​chaitanyabodlapati, @​cxljs, @​dariaguy, @​fatal10110, @​mwhooker, @​ndyakov, @​ofekshenawa, @​olde-ducke, @​olzhas-sabiyev, @​romanpovol, @​rubensayshi, @​vladisa88, @​wzy9607, @​zhengjilei


Full Changelog: https://github.com/redis/go-redis/compare/v9.18.0...v9.19.0

v9.18.0: 9.18.0

Compare Source

Redis 8.6 Support

Added support for Redis 8.6, including new commands and features for streams idempotent production and HOTKEYS.

Smart Client Handoff (Maintenance Notifications) for Cluster

This release introduces comprehensive support for Redis Enterprise Cluster maintenance notifications via SMIGRATING/SMIGRATED push notifications. The client now automatically handles slot migrations by:

  • Relaxing timeouts during migration (SMIGRATING) to prevent false failures
  • Triggering lazy cluster state reloads upon completion (SMIGRATED)
  • Enabling seamless operations during Redis Enterprise maintenance windows

(#​3643) by @​ndyakov

OpenTelemetry Native Metrics Support

Added comprehensive OpenTelemetry metrics support following the OpenTelemetry Database Client Semantic Conventions. The implementation uses a Bridge Pattern to keep the core library dependency-free while providing optional metrics instrumentation through the new extra/redisotel-native package.

Metric groups include:

  • Command metrics: Operation duration with retry tracking
  • Connection basic: Connection count and creation time
  • Resiliency: Errors, handoffs, timeout relaxation
  • Connection advanced: Wait time and use time
  • Pubsub metrics: Published and received messages
  • Stream metrics: Processing duration and maintenance notifications

(#​3637) by @​ofekshenawa

New Features

  • HOTKEYS Commands: Added support for Redis HOTKEYS feature for identifying hot keys based on CPU consumption and network utilization (#​3695) by @​ofekshenawa
  • Streams Idempotent Production: Added support for Redis 8.6+ Streams Idempotent Production with ProducerID, IdempotentID, IdempotentAuto in XAddArgs and new XCFGSET command (#​3693) by @​ofekshenawa
  • NaN Values for TimeSeries: Added support for NaN (Not a Number) values in Redis time series commands (#​3687) by @​ofekshenawa
  • DialerRetries Options: Added DialerRetries and DialerRetryTimeout to ClusterOptions, RingOptions, and FailoverOptions (#​3686) by @​naveenchander30
  • ConnMaxLifetimeJitter: Added jitter configuration to distribute connection expiration times and prevent thundering herd (#​3666) by @​cyningsun
  • Digest Helper Functions: Added DigestString and DigestBytes helper functions for client-side xxh3 hashing compatible with Redis DIGEST command (#​3679) by @​ofekshenawa
  • SMIGRATED New Format: Updated SMIGRATED parser to support new format and remember original host:port (#​3697) by @​ndyakov
  • Cluster State Reload Interval: Added cluster state reload interval option for maintenance notifications (#​3663) by @​ndyakov

🐛 Bug Fixes

  • PubSub nil pointer dereference: Fixed nil pointer dereference in PubSub after WithTimeout() - pubSubPool is now properly cloned (#​3710) by @​Copilot
  • MaintNotificationsConfig nil check: Guard against nil MaintNotificationsConfig in initConn (#​3707) by @​veeceey
  • wantConnQueue zombie elements: Fixed zombie wantConn elements accumulation in wantConnQueue (#​3680) by @​cyningsun
  • XADD/XTRIM approx flag: Fixed XADD and XTRIM to use = when approx is false (#​3684) by @​ndyakov
  • Sentinel timeout retry: When connection to a sentinel times out, attempt to connect to other sentinels (#​3654) by @​cxljs

Performance

  • Fuzz test optimization: Eliminated repeated string conversions, used functional approach for cleaner operation selection (#​3692) by @​feiguoL
  • Pre-allocate capacity: Pre-allocate slice capacity to prevent multiple capacity expansions (#​3689) by @​feelshu

🧪 Testing

  • Comprehensive TLS tests: Added comprehensive TLS tests and example for standalone, cluster, and certificate authentication (#​3681) by @​ndyakov
  • Redis 8.6: Updated CI to use Redis 8.6-pre (#​3685) by @​ndyakov

🧰 Maintenance

  • Deprecation warnings: Added deprecation warnings for commands based on Redis documentation (#​3673) by @​ndyakov
  • Use errors.Join(): Replaced custom error join function with standard library errors.Join() (#​3653) by @​cxljs
  • Use Go 1.21 min/max: Use Go 1.21's built-in min/max functions (#​3656) by @​cxljs
  • Proper formatting: Code formatting improvements (#​3670) by @​12ya
  • Set commands documentation: Added comprehensive documentation to all set command methods (#​3642) by @​iamamirsalehi
  • MaxActiveConns docs: Added default value documentation for MaxActiveConns (#​3674) by @​codykaup
  • README example update: Updated README example (#​3657) by @​cxljs
  • Cluster maintnotif example: Added example application for cluster maintenance notifications (#​3651) by @​ndyakov

👥 Contributors

We'd like to thank all the contributors who worked on this release!

@​12ya, @​Copilot, @​codykaup, @​cxljs, @​cyningsun, @​feelshu, @​feiguoL, @​iamamirsalehi, @​naveenchander30, @​ndyakov, @​ofekshenawa, @​veeceey


Configuration

📅 Schedule: (UTC)

  • Branch creation
    • Between 12:00 AM and 03:59 AM (* 0-3 * * *)
  • Automerge
    • Between 12:00 AM and 03:59 AM (* 0-3 * * *)

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Mend Renovate.

This PR contains the following updates: | Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) | |---|---|---|---| | [github.com/redis/go-redis/v9](https://github.com/redis/go-redis) | `v9.17.3` → `v9.20.0` | ![age](https://developer.mend.io/api/mc/badges/age/go/github.com%2fredis%2fgo-redis%2fv9/v9.20.0?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/go/github.com%2fredis%2fgo-redis%2fv9/v9.17.3/v9.20.0?slim=true) | --- ### Release Notes <details> <summary>redis/go-redis (github.com/redis/go-redis/v9)</summary> ### [`v9.20.0`](https://github.com/redis/go-redis/releases/tag/v9.20.0): 9.20.0 [Compare Source](https://github.com/redis/go-redis/compare/v9.19.0...v9.20.0) #### 🚀 Highlights ##### Redis 8.8 Support This release adds support for **Redis 8.8**. The README's supported-versions list now includes Redis 8.8 alongside 8.0/8.2/8.4, and CI exercises the `8.8` client-libs-test image across the full suite (Makefile, build workflow, doctests, run-tests action, and docker-compose). Coverage for the new commands that ship in the 8.x line, rounded out in this release: - **`AR*` array data type** ([#&#8203;3813](https://github.com/redis/go-redis/pull/3813)) — new array data structure, exposed via the `ArrayCmdable` interface (see the experimental-features highlight below). - **`INCREX`** ([#&#8203;3816](https://github.com/redis/go-redis/pull/3816)) — atomic increment with expiration in a single round-trip. - **`XNACK`** ([#&#8203;3790](https://github.com/redis/go-redis/pull/3790)) — explicit negative-acknowledge of pending stream entries. - **`XAUTOCLAIM` PEL deletes** ([#&#8203;3798](https://github.com/redis/go-redis/pull/3798)) — `XAUTOCLAIM`/`XAUTOCLAIMJUSTID` now return the list of deleted message IDs from the pending entries list. - **`TS.RANGE` multiple aggregators** ([#&#8203;3791](https://github.com/redis/go-redis/pull/3791)) — `TS.RANGE`/`TS.REVRANGE`/`TS.MRANGE`/`TS.MREVRANGE` accept multiple aggregators in a single call. - **`Z(UNION|INTER|DIFF)` `COUNT` aggregator** ([#&#8203;3802](https://github.com/redis/go-redis/pull/3802)) — `COUNT` reducer for sorted-set set operations. - **`JSON.SET FPHA`** ([#&#8203;3797](https://github.com/redis/go-redis/pull/3797)) — new `FPHA` argument that specifies the floating-point type for homogeneous FP arrays. CI image bump ([#&#8203;3814](https://github.com/redis/go-redis/pull/3814)) by [@&#8203;ofekshenawa](https://github.com/ofekshenawa). Command coverage contributions by [@&#8203;cxljs](https://github.com/cxljs), [@&#8203;elena-kolevska](https://github.com/elena-kolevska), [@&#8203;Khukharr](https://github.com/Khukharr), [@&#8203;ndyakov](https://github.com/ndyakov), and [@&#8203;ofekshenawa](https://github.com/ofekshenawa). ##### Stable RESP3 for RediSearch (`UnstableResp3` deprecated) `FT.SEARCH`, `FT.AGGREGATE`, `FT.INFO`, `FT.SPELLCHECK`, and `FT.SYNDUMP` now parse RESP3 (map) responses into the same typed result objects as RESP2 — `Val()` and `Result()` work uniformly on both protocols, no flag required. Previously, RESP3 search responses required `UnstableResp3: true` and were returned as opaque maps accessible only via `RawResult()` / `RawVal()`. As a result, the `UnstableResp3` option is now a **no-op** across every options struct (`Options`, `ClusterOptions`, `UniversalOptions`, `FailoverOptions`, `RingOptions`) and has been marked `// Deprecated:`. The field is retained for backwards compatibility — existing code that sets `UnstableResp3: true` will continue to compile and behave identically — but it will be removed in a future release and new code should not set it. `RawResult()` / `RawVal()` continue to work for callers that prefer the raw RESP payload. ([#&#8203;3741](https://github.com/redis/go-redis/pull/3741)) by [@&#8203;ndyakov](https://github.com/ndyakov) ##### Experimental Array Data Structure Commands Adds an experimental `ArrayCmdable` interface with the `AR*` command family (`ARSet`, `ARGet`, `ARGetRange`, `ARMSet`, `ARMGet`, `ARDel`, `ARDelRange`, `ARScan`, `ARSeek`, `ARNext`, `ARLastItems`, `ARGrep`, `ARGrepWithValues`, `ARInfo`/`ARInfoFull`, and typed reducers `AROpSum`/`AROpMin`/`AROpMax`/`AROpAnd`/`AROpOr`/`AROpXor`/`AROpMatch`/`AROpUsed`) for working with Redis 8.8's new array data type. **API is experimental and may change in a future release.** ([#&#8203;3813](https://github.com/redis/go-redis/pull/3813)) by [@&#8203;cxljs](https://github.com/cxljs) #### ✨ New Features - **RESP3 search parser**: First-class RESP3 parsing for `FT.SEARCH`/`FT.AGGREGATE`/`FT.INFO`/`FT.SPELLCHECK`/`FT.SYNDUMP` responses with backwards compatibility for RESP2 ([#&#8203;3741](https://github.com/redis/go-redis/pull/3741)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **INCREX**: New `INCREX` command support — atomic increment with expiration ([#&#8203;3816](https://github.com/redis/go-redis/pull/3816)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **XNACK**: Client support for the `XNACK` stream command for explicitly negative-acknowledging pending entries ([#&#8203;3790](https://github.com/redis/go-redis/pull/3790)) by [@&#8203;elena-kolevska](https://github.com/elena-kolevska) - **TS range multiple aggregators**: `TS.RANGE`/`TS.REVRANGE`/`TS.MRANGE`/`TS.MREVRANGE` now accept multiple aggregators in a single call ([#&#8203;3791](https://github.com/redis/go-redis/pull/3791)) by [@&#8203;elena-kolevska](https://github.com/elena-kolevska) - **`XAutoClaim` deleted IDs**: `XAUTOCLAIM`/`XAUTOCLAIMJUSTID` now return the list of deleted message IDs from the PEL ([#&#8203;3798](https://github.com/redis/go-redis/pull/3798)) by [@&#8203;Khukharr](https://github.com/Khukharr) - **`JSON.SET FPHA`**: `JSON.SET` accepts a new `FPHA` argument that specifies the floating-point type for homogeneous floating-point arrays ([#&#8203;3797](https://github.com/redis/go-redis/pull/3797)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **Sorted-set union/intersection COUNT**: `ZUNION`/`ZINTER`/`ZDIFF` aggregator now supports `COUNT` ([#&#8203;3802](https://github.com/redis/go-redis/pull/3802)) by [@&#8203;ofekshenawa](https://github.com/ofekshenawa) - **`FT.HYBRID` vector validation**: Validates hybrid-search vector input types and adds proper typed vector parameters ([#&#8203;3756](https://github.com/redis/go-redis/pull/3756)) by [@&#8203;DengY11](https://github.com/DengY11) - **Cluster pool wait stats**: `ClusterClient.PoolStats()` now accumulates `WaitCount` and `WaitDurationNs` across all node pools (previously always zero) ([#&#8203;3809](https://github.com/redis/go-redis/pull/3809)) by [@&#8203;LINKIWI](https://github.com/LINKIWI) #### 🐛 Bug Fixes - **TLS-only Cluster PubSub**: `CLUSTER SLOTS` port-0 entries now fall back to the origin endpoint's port, fixing `dial tcp <ip>:0: connection refused` on TLS-only clusters started with `--port 0 --tls-port <port>` (fixes [#&#8203;3726](https://github.com/redis/go-redis/issues/3726)) ([#&#8203;3828](https://github.com/redis/go-redis/pull/3828)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **Sharded PubSub reconnect routing**: `PubSub.conn()` now passes both regular (`c.channels`) and sharded (`c.schannels`) channels into the per-PubSub `newConn` closure. Previously, `ClusterClient.SSubscribe`-only PubSubs reconnected to a random node (because the routing closure saw an empty channel list), the `SSUBSCRIBE` was sent to the wrong shard, and the resulting `MOVED` reply was silently dropped ([#&#8203;3829](https://github.com/redis/go-redis/pull/3829)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **ClusterClient `Watch` retry**: User errors returned from a `Watch` callback are no longer subjected to cluster-retry classification; transient cluster errors still retry, but a callback returning e.g. `net.ErrClosed` short-circuits immediately ([#&#8203;3821](https://github.com/redis/go-redis/pull/3821)) by [@&#8203;obiyang](https://github.com/obiyang) - **Sentinel concurrent-probe leak**: `MasterAddr`'s concurrent sentinel probe now closes the non-winning sentinel clients instead of leaking them ([#&#8203;3827](https://github.com/redis/go-redis/pull/3827)) by [@&#8203;cxljs](https://github.com/cxljs) - **Sentinel rediscovery loop on master-only setups**: `replicaAddrs` no longer tears down the cached sentinel client when the replica list is empty, eliminating a continuous rediscovery loop on master-only Sentinel deployments that flooded logs and added per-operation latency ([#&#8203;3795](https://github.com/redis/go-redis/pull/3795)) by [@&#8203;shahyash2609](https://github.com/shahyash2609) - **Pool `CloseConn` hooks**: `Pool.CloseConn` now triggers registered hooks, fixing a memory leak when connections are closed explicitly rather than via the normal removal path ([#&#8203;3818](https://github.com/redis/go-redis/pull/3818)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **Dial TCP error redirection**: Wrapped `dial tcp` errors are now correctly classified as redirectable so cluster routing can recover from a single unreachable node ([#&#8203;3810](https://github.com/redis/go-redis/pull/3810)) by [@&#8203;vladisa88](https://github.com/vladisa88) - **Pool `Close` health checks**: `ConnPool.Close` now only runs health checks against idle connections, avoiding spurious activity on connections still in use ([#&#8203;3805](https://github.com/redis/go-redis/pull/3805)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **VLinks return type**: Fixed the return type of `VLINKS`/`VLINKSWITHSCORES` vector-set replies ([#&#8203;3820](https://github.com/redis/go-redis/pull/3820)) by [@&#8203;romanpovol](https://github.com/romanpovol) #### 🧪 Testing & Infrastructure - **Flaky tests**: Stabilized several flaky tests in the sentinel and pool suites ([#&#8203;3815](https://github.com/redis/go-redis/pull/3815)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **Sentinel failover metric race**: Fixed a data race in the sentinel failover metric test ([#&#8203;3824](https://github.com/redis/go-redis/pull/3824)) by [@&#8203;cxljs](https://github.com/cxljs) - **`waitForSentinelClusterStable` post-conditions**: The sentinel test harness now waits for replicas to be fully connected (not just present in the count) and is robust to randomized spec ordering after failover specs, eliminating an intermittent `Expected master to equal slave` flake ([#&#8203;3830](https://github.com/redis/go-redis/pull/3830)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **`govulncheck` workflow**: New scheduled GitHub Actions workflow runs `govulncheck` on every push, PR, and weekly, surfacing newly disclosed Go vulnerabilities even when no code changes ([#&#8203;3779](https://github.com/redis/go-redis/pull/3779)) by [@&#8203;solardome](https://github.com/solardome) - **CI Redis 8.8-rc1**: CI now exercises the 8.8-rc1 Redis image ([#&#8203;3814](https://github.com/redis/go-redis/pull/3814)) by [@&#8203;ofekshenawa](https://github.com/ofekshenawa) #### 🧰 Maintenance - **`Cmd.Slot()` lookup refactor**: Caches the per-command `CommandInfo` and short-circuits keyless commands before the switch dispatch, removing redundant `Peek` calls ([#&#8203;3804](https://github.com/redis/go-redis/pull/3804)) by [@&#8203;retr0-kernel](https://github.com/retr0-kernel) - **stdlib `math/rand`**: Replaced `internal/rand` with `math/rand` from the standard library now that the minimum Go version is 1.24 ([#&#8203;3823](https://github.com/redis/go-redis/pull/3823)) by [@&#8203;cxljs](https://github.com/cxljs) - **ConnPool queue channel**: Removed the unused queue channel from `ConnPool`, trimming the pool's footprint ([#&#8203;3826](https://github.com/redis/go-redis/pull/3826)) by [@&#8203;cxljs](https://github.com/cxljs) - **Extra packages LICENSE**: Added a LICENSE file to each `extra/*` package ([#&#8203;3817](https://github.com/redis/go-redis/pull/3817)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **README & CI image**: Documentation refresh and bumped the default CI image tag ([#&#8203;3822](https://github.com/redis/go-redis/pull/3822)) by [@&#8203;ndyakov](https://github.com/ndyakov) #### 👥 Contributors We'd like to thank all the contributors who worked on this release! [@&#8203;cxljs](https://github.com/cxljs), [@&#8203;DengY11](https://github.com/DengY11), [@&#8203;elena-kolevska](https://github.com/elena-kolevska), [@&#8203;Khukharr](https://github.com/Khukharr), [@&#8203;LINKIWI](https://github.com/LINKIWI), [@&#8203;ndyakov](https://github.com/ndyakov), [@&#8203;obiyang](https://github.com/obiyang), [@&#8203;ofekshenawa](https://github.com/ofekshenawa), [@&#8203;retr0-kernel](https://github.com/retr0-kernel), [@&#8203;romanpovol](https://github.com/romanpovol), [@&#8203;shahyash2609](https://github.com/shahyash2609), [@&#8203;solardome](https://github.com/solardome), [@&#8203;vladisa88](https://github.com/vladisa88) *** **Full Changelog**: <https://github.com/redis/go-redis/compare/v9.19.0...v9.20.0> ### [`v9.19.0`](https://github.com/redis/go-redis/releases/tag/v9.19.0): 9.19.0 [Compare Source](https://github.com/redis/go-redis/compare/v9.18.0...v9.19.0) #### 🚀 Highlights ##### FIPS-Compatible Script Helper `Script` now supports a FIPS-safe execution mode that avoids client-side SHA-1 computation, which is blocked in strict FIPS environments. A new `NewScriptServerSHA` constructor uses `SCRIPT LOAD` to obtain and cache the digest from the server, then runs commands via `EVALSHA`/`EVALSHA_RO`. Falls back to `EVAL`/`EVALRO` if loading fails, and transparently retries once on `NOSCRIPT`. The default behavior is unchanged for existing users. ([#&#8203;3700](https://github.com/redis/go-redis/pull/3700)) by [@&#8203;chaitanyabodlapati](https://github.com/chaitanyabodlapati) ##### FT.AGGREGATE Step-Based Pipeline Builder Added a new step-based `FT.AGGREGATE` pipeline API via `FTAggregateOptions.Steps`, allowing `LOAD`, `APPLY`, `GROUPBY`, and `SORTBY` (with per-step `MAX`) to be repeated and interleaved in arbitrary order — matching Redis's native multi-stage aggregation semantics. The legacy `Load`/`Apply`/`GroupBy`/`SortBy`/`SortByMax` fields are now deprecated. ([#&#8203;3782](https://github.com/redis/go-redis/pull/3782)) by [@&#8203;ndyakov](https://github.com/ndyakov) ##### Raw RESP Protocol Access Added `DoRaw` and `DoRawWriteTo` methods for executing arbitrary commands and reading the raw RESP response. Useful for proxying, custom protocol inspection, and working with commands not yet wrapped by go-redis. ([#&#8203;3713](https://github.com/redis/go-redis/pull/3713)) by [@&#8203;ofekshenawa](https://github.com/ofekshenawa) ##### Configurable Dial Retry Backoff Added `DialerRetryBackoff` option (plumbed through `Options`, `ClusterOptions`, `RingOptions`, `FailoverOptions`) to let callers customize the delay between failed dial attempts. Helpers `DialRetryBackoffConstant` and `DialRetryBackoffExponential` (with jitter and cap) are provided out of the box. Dial timeout is now also applied **per attempt** rather than across all retries. ([#&#8203;3706](https://github.com/redis/go-redis/pull/3706), [#&#8203;3705](https://github.com/redis/go-redis/pull/3705)) by [@&#8203;mwhooker](https://github.com/mwhooker) #### ✨ New Features - **FT.AGGREGATE Steps**: Step-based pipeline builder for `FT.AGGREGATE` with support for repeated/interleaved `LOAD`, `APPLY`, `GROUPBY`, and `SORTBY` stages ([#&#8203;3782](https://github.com/redis/go-redis/pull/3782)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **VectorSet commands**: Added `VISMEMBER` and `WITHATTRIBS` support ([#&#8203;3753](https://github.com/redis/go-redis/pull/3753)) by [@&#8203;romanpovol](https://github.com/romanpovol) - **FIPS-safe Script**: `NewScriptServerSHA` uses `SCRIPT LOAD` to obtain the digest from the server, avoiding client-side SHA-1 ([#&#8203;3700](https://github.com/redis/go-redis/pull/3700)) by [@&#8203;chaitanyabodlapati](https://github.com/chaitanyabodlapati) - **Raw RESP access**: `DoRaw` and `DoRawWriteTo` for raw RESP protocol access ([#&#8203;3713](https://github.com/redis/go-redis/pull/3713)) by [@&#8203;ofekshenawa](https://github.com/ofekshenawa) - **Dial retry backoff**: `DialerRetryBackoff` function option with constant and exponential helpers ([#&#8203;3706](https://github.com/redis/go-redis/pull/3706)) by [@&#8203;mwhooker](https://github.com/mwhooker) - **Typed NOSCRIPT error**: Redis `NOSCRIPT` replies are now surfaced as a typed error for easier handling ([#&#8203;3738](https://github.com/redis/go-redis/pull/3738)) by [@&#8203;LINKIWI](https://github.com/LINKIWI) - **PubSub ClientSetName**: Added `ClientSetName` method to `PubSub` ([#&#8203;3727](https://github.com/redis/go-redis/pull/3727)) by [@&#8203;Flack74](https://github.com/Flack74) - **ReplicaOf**: New `ReplicaOf` method replaces the deprecated `SlaveOf` ([#&#8203;3720](https://github.com/redis/go-redis/pull/3720)) by [@&#8203;Copilot](https://github.com/apps/copilot-swe-agent) - **HSCAN BinaryUnmarshaler**: `HScan` now supports types implementing `encoding.BinaryUnmarshaler` ([#&#8203;3768](https://github.com/redis/go-redis/pull/3768)) by [@&#8203;Aaditya-dubey1](https://github.com/Aaditya-dubey1) #### 🐛 Bug Fixes - **Auto hostname type detection**: Improved endpoint type detection for maintenance notifications using DNS-based classification; handles empty hosts and expanded private-IP ranges ([#&#8203;3789](https://github.com/redis/go-redis/pull/3789)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **HELLO fallback**: Don't send `CLIENT MAINT_NOTIFICATIONS` handshake when `HELLO` fails and connection falls back to RESP2; fail fast when explicitly enabled with RESP3 ([#&#8203;3788](https://github.com/redis/go-redis/pull/3788)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **Dial TCP retry**: `ShouldRetry` now treats `net.OpError` with `Op == "dial"` timeout errors as safe to retry since no command was sent ([#&#8203;3787](https://github.com/redis/go-redis/pull/3787)) by [@&#8203;vladisa88](https://github.com/vladisa88) - **wrappedOnClose leak**: Fixed resource leak caused by repeatedly wrapping `baseClient` close logic; replaced with a bounded, concurrency-safe named-hook registry ([#&#8203;3785](https://github.com/redis/go-redis/pull/3785)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **Pool Close() on stale connections**: Suppress close errors (e.g., TLS `closeNotify` timeouts) for connections already dropped by the server due to idle timeout ([#&#8203;3778](https://github.com/redis/go-redis/pull/3778)) by [@&#8203;ofekshenawa](https://github.com/ofekshenawa) - **FIFO waiter ordering**: Fixed race in `ConnStateMachine.notifyWaiters` that could wake multiple waiters under a single mutex hold and violate FIFO ordering ([#&#8203;3777](https://github.com/redis/go-redis/pull/3777)) by [@&#8203;0x48core](https://github.com/0x48core) - **Lua READONLY detection**: Detect `READONLY` errors embedded in Lua script error messages on read-only replicas so commands are correctly retried ([#&#8203;3769](https://github.com/redis/go-redis/pull/3769)) by [@&#8203;zhengjilei](https://github.com/zhengjilei) - **VectorScoreSliceCmd RESP2**: Fixed `VSimWithScores`, `VSimWithArgsWithScores`, and `VLinksWithScores` which were broken on RESP2 connections returning flat arrays instead of maps ([#&#8203;3767](https://github.com/redis/go-redis/pull/3767)) by [@&#8203;Copilot](https://github.com/apps/copilot-swe-agent) - **Closed connection handling**: Two fixes for closed connection handling in the pool ([#&#8203;3764](https://github.com/redis/go-redis/pull/3764)) by [@&#8203;cxljs](https://github.com/cxljs) - **ZRangeArgs Rev**: Fixed `ZRangeArgs` with `Rev` + `ByScore`/`ByLex` incorrectly swapping `Start`/`Stop`, breaking `ZRANGESTORE` ([#&#8203;3751](https://github.com/redis/go-redis/pull/3751)) by [@&#8203;Copilot](https://github.com/apps/copilot-swe-agent) - **OTel metric instrument types**: Fixed metric instrument types in `redisotel-native` ([#&#8203;3743](https://github.com/redis/go-redis/pull/3743)) by [@&#8203;ofekshenawa](https://github.com/ofekshenawa) - **Options.clone() data race**: Fixed data race when cloning `Options` ([#&#8203;3739](https://github.com/redis/go-redis/pull/3739)) by [@&#8203;rubensayshi](https://github.com/rubensayshi) - **Connection closure metrics**: Fixed connection closure metrics and enabled all metric groups by default in `redisotel-native` ([#&#8203;3735](https://github.com/redis/go-redis/pull/3735)) by [@&#8203;ofekshenawa](https://github.com/ofekshenawa) - **OTel semconv v1.38.0**: Use metric definition from `otel/semconv/v1.38.0` in `redisotel-native` ([#&#8203;3731](https://github.com/redis/go-redis/pull/3731)) by [@&#8203;wzy9607](https://github.com/wzy9607) - **SETNX semantics**: Use `SET ... NX` instead of the deprecated `SETNX` command ([#&#8203;3723](https://github.com/redis/go-redis/pull/3723)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **TIME keyless routing**: Mark `TIME` as a keyless command for correct cluster routing ([#&#8203;3722](https://github.com/redis/go-redis/pull/3722)) by [@&#8203;fatal10110](https://github.com/fatal10110) - **Dial timeout per retry**: Dial timeout now applies per attempt instead of across all retry attempts combined ([#&#8203;3705](https://github.com/redis/go-redis/pull/3705)) by [@&#8203;mwhooker](https://github.com/mwhooker) - **Cluster metrics attributes**: Fixed `pool.name` being appended per node, which corrupted and dropped user-provided custom attributes ([#&#8203;3699](https://github.com/redis/go-redis/pull/3699)) by [@&#8203;Jesse-Bonfire](https://github.com/Jesse-Bonfire) - **initConn nil dereference**: Fixed nil pointer dereference and potential deadlock in `*baseClient.initConn()`; added explicit nil option guards to client constructors ([#&#8203;3676](https://github.com/redis/go-redis/pull/3676)) by [@&#8203;olde-ducke](https://github.com/olde-ducke) #### ⚡ Performance - **RESP reader**: Optimized RESP reader by eliminating intermediate string allocations ([#&#8203;3774](https://github.com/redis/go-redis/pull/3774)) by [@&#8203;Aaditya-dubey1](https://github.com/Aaditya-dubey1) - **Inline rendezvous hashing**: Replaced `github.com/dgryski/go-rendezvous` dependency with an in-repo implementation in `internal/hashtag`, reducing the dependency graph while preserving algorithm parity ([#&#8203;3762](https://github.com/redis/go-redis/pull/3762)) by [@&#8203;bigsk05](https://github.com/bigsk05) #### 🧪 Testing & Infrastructure - **Release automation**: Added `repository`, `ref`, and `client-libs-test-image-tag` inputs to the `run-tests` composite action; `redis-version` is now optional so unstable builds use `REDIS_VERSION` from the Makefile ([#&#8203;3749](https://github.com/redis/go-redis/pull/3749)) by [@&#8203;dariaguy](https://github.com/dariaguy) - **Go 1.24**: Updated minimum Go version to 1.24 and use `-compat=1.24` in release scripts ([#&#8203;3714](https://github.com/redis/go-redis/pull/3714), [#&#8203;3754](https://github.com/redis/go-redis/pull/3754)) by [@&#8203;ndyakov](https://github.com/ndyakov), [@&#8203;cxljs](https://github.com/cxljs) #### 🧰 Maintenance - **Pool state machine**: Removed redundant `Conn.closed` atomic field in favor of the state machine's `StateClosed` ([#&#8203;3783](https://github.com/redis/go-redis/pull/3783)) by [@&#8203;cxljs](https://github.com/cxljs) - **OTel SDK**: Updated OpenTelemetry SDK dependencies in `redisotel`/`redisotel-native` ([#&#8203;3770](https://github.com/redis/go-redis/pull/3770)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **Go 1.21+ built-ins**: Use `maps.Keys`, `slices.Collect`, `slices.Contains`, `clear()`, and `slices.SortFunc` instead of custom helpers ([#&#8203;3758](https://github.com/redis/go-redis/pull/3758), [#&#8203;3746](https://github.com/redis/go-redis/pull/3746)) by [@&#8203;cxljs](https://github.com/cxljs) - **HGetAll docs**: Added Go doc comment to `HGetAll` describing behavior and complexity ([#&#8203;3776](https://github.com/redis/go-redis/pull/3776)) by [@&#8203;0x48core](https://github.com/0x48core) - **Docs links**: Fixed irrelevant docs links ([#&#8203;3724](https://github.com/redis/go-redis/pull/3724)) by [@&#8203;olzhas-sabiyev](https://github.com/olzhas-sabiyev) - **Examples cleanup**: Removed throughput binary from examples ([#&#8203;3733](https://github.com/redis/go-redis/pull/3733)) by [@&#8203;ndyakov](https://github.com/ndyakov) #### 👥 Contributors We'd like to thank all the contributors who worked on this release! [@&#8203;0x48core](https://github.com/0x48core), [@&#8203;Aaditya-dubey1](https://github.com/Aaditya-dubey1), [@&#8203;Copilot](https://github.com/apps/copilot-swe-agent), [@&#8203;Flack74](https://github.com/Flack74), [@&#8203;Jesse-Bonfire](https://github.com/Jesse-Bonfire), [@&#8203;LINKIWI](https://github.com/LINKIWI), [@&#8203;bigsk05](https://github.com/bigsk05), [@&#8203;chaitanyabodlapati](https://github.com/chaitanyabodlapati), [@&#8203;cxljs](https://github.com/cxljs), [@&#8203;dariaguy](https://github.com/dariaguy), [@&#8203;fatal10110](https://github.com/fatal10110), [@&#8203;mwhooker](https://github.com/mwhooker), [@&#8203;ndyakov](https://github.com/ndyakov), [@&#8203;ofekshenawa](https://github.com/ofekshenawa), [@&#8203;olde-ducke](https://github.com/olde-ducke), [@&#8203;olzhas-sabiyev](https://github.com/olzhas-sabiyev), [@&#8203;romanpovol](https://github.com/romanpovol), [@&#8203;rubensayshi](https://github.com/rubensayshi), [@&#8203;vladisa88](https://github.com/vladisa88), [@&#8203;wzy9607](https://github.com/wzy9607), [@&#8203;zhengjilei](https://github.com/zhengjilei) *** **Full Changelog**: <https://github.com/redis/go-redis/compare/v9.18.0...v9.19.0> ### [`v9.18.0`](https://github.com/redis/go-redis/releases/tag/v9.18.0): 9.18.0 [Compare Source](https://github.com/redis/go-redis/compare/v9.17.3...v9.18.0) ##### Redis 8.6 Support Added support for Redis 8.6, including new commands and features for streams idempotent production and HOTKEYS. ##### Smart Client Handoff (Maintenance Notifications) for Cluster This release introduces comprehensive support for Redis Enterprise Cluster maintenance notifications via SMIGRATING/SMIGRATED push notifications. The client now automatically handles slot migrations by: - **Relaxing timeouts during migration** (SMIGRATING) to prevent false failures - **Triggering lazy cluster state reloads** upon completion (SMIGRATED) - Enabling seamless operations during Redis Enterprise maintenance windows ([#&#8203;3643](https://github.com/redis/go-redis/pull/3643)) by [@&#8203;ndyakov](https://github.com/ndyakov) ##### OpenTelemetry Native Metrics Support Added comprehensive OpenTelemetry metrics support following the [OpenTelemetry Database Client Semantic Conventions](https://opentelemetry.io/docs/specs/semconv/database/database-metrics/). The implementation uses a Bridge Pattern to keep the core library dependency-free while providing optional metrics instrumentation through the new `extra/redisotel-native` package. **Metric groups include:** - Command metrics: Operation duration with retry tracking - Connection basic: Connection count and creation time - Resiliency: Errors, handoffs, timeout relaxation - Connection advanced: Wait time and use time - Pubsub metrics: Published and received messages - Stream metrics: Processing duration and maintenance notifications ([#&#8203;3637](https://github.com/redis/go-redis/pull/3637)) by [@&#8203;ofekshenawa](https://github.com/ofekshenawa) #### ✨ New Features - **HOTKEYS Commands**: Added support for Redis HOTKEYS feature for identifying hot keys based on CPU consumption and network utilization ([#&#8203;3695](https://github.com/redis/go-redis/pull/3695)) by [@&#8203;ofekshenawa](https://github.com/ofekshenawa) - **Streams Idempotent Production**: Added support for Redis 8.6+ Streams Idempotent Production with `ProducerID`, `IdempotentID`, `IdempotentAuto` in `XAddArgs` and new `XCFGSET` command ([#&#8203;3693](https://github.com/redis/go-redis/pull/3693)) by [@&#8203;ofekshenawa](https://github.com/ofekshenawa) - **NaN Values for TimeSeries**: Added support for NaN (Not a Number) values in Redis time series commands ([#&#8203;3687](https://github.com/redis/go-redis/pull/3687)) by [@&#8203;ofekshenawa](https://github.com/ofekshenawa) - **DialerRetries Options**: Added `DialerRetries` and `DialerRetryTimeout` to `ClusterOptions`, `RingOptions`, and `FailoverOptions` ([#&#8203;3686](https://github.com/redis/go-redis/pull/3686)) by [@&#8203;naveenchander30](https://github.com/naveenchander30) - **ConnMaxLifetimeJitter**: Added jitter configuration to distribute connection expiration times and prevent thundering herd ([#&#8203;3666](https://github.com/redis/go-redis/pull/3666)) by [@&#8203;cyningsun](https://github.com/cyningsun) - **Digest Helper Functions**: Added `DigestString` and `DigestBytes` helper functions for client-side xxh3 hashing compatible with Redis DIGEST command ([#&#8203;3679](https://github.com/redis/go-redis/pull/3679)) by [@&#8203;ofekshenawa](https://github.com/ofekshenawa) - **SMIGRATED New Format**: Updated SMIGRATED parser to support new format and remember original host:port ([#&#8203;3697](https://github.com/redis/go-redis/pull/3697)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **Cluster State Reload Interval**: Added cluster state reload interval option for maintenance notifications ([#&#8203;3663](https://github.com/redis/go-redis/pull/3663)) by [@&#8203;ndyakov](https://github.com/ndyakov) #### 🐛 Bug Fixes - **PubSub nil pointer dereference**: Fixed nil pointer dereference in PubSub after `WithTimeout()` - `pubSubPool` is now properly cloned ([#&#8203;3710](https://github.com/redis/go-redis/pull/3710)) by [@&#8203;Copilot](https://github.com/apps/copilot-swe-agent) - **MaintNotificationsConfig nil check**: Guard against nil `MaintNotificationsConfig` in `initConn` ([#&#8203;3707](https://github.com/redis/go-redis/pull/3707)) by [@&#8203;veeceey](https://github.com/veeceey) - **wantConnQueue zombie elements**: Fixed zombie `wantConn` elements accumulation in `wantConnQueue` ([#&#8203;3680](https://github.com/redis/go-redis/pull/3680)) by [@&#8203;cyningsun](https://github.com/cyningsun) - **XADD/XTRIM approx flag**: Fixed XADD and XTRIM to use `=` when approx is false ([#&#8203;3684](https://github.com/redis/go-redis/pull/3684)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **Sentinel timeout retry**: When connection to a sentinel times out, attempt to connect to other sentinels ([#&#8203;3654](https://github.com/redis/go-redis/pull/3654)) by [@&#8203;cxljs](https://github.com/cxljs) #### ⚡ Performance - **Fuzz test optimization**: Eliminated repeated string conversions, used functional approach for cleaner operation selection ([#&#8203;3692](https://github.com/redis/go-redis/pull/3692)) by [@&#8203;feiguoL](https://github.com/feiguoL) - **Pre-allocate capacity**: Pre-allocate slice capacity to prevent multiple capacity expansions ([#&#8203;3689](https://github.com/redis/go-redis/pull/3689)) by [@&#8203;feelshu](https://github.com/feelshu) #### 🧪 Testing - **Comprehensive TLS tests**: Added comprehensive TLS tests and example for standalone, cluster, and certificate authentication ([#&#8203;3681](https://github.com/redis/go-redis/pull/3681)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **Redis 8.6**: Updated CI to use Redis 8.6-pre ([#&#8203;3685](https://github.com/redis/go-redis/pull/3685)) by [@&#8203;ndyakov](https://github.com/ndyakov) #### 🧰 Maintenance - **Deprecation warnings**: Added deprecation warnings for commands based on Redis documentation ([#&#8203;3673](https://github.com/redis/go-redis/pull/3673)) by [@&#8203;ndyakov](https://github.com/ndyakov) - **Use errors.Join()**: Replaced custom error join function with standard library `errors.Join()` ([#&#8203;3653](https://github.com/redis/go-redis/pull/3653)) by [@&#8203;cxljs](https://github.com/cxljs) - **Use Go 1.21 min/max**: Use Go 1.21's built-in min/max functions ([#&#8203;3656](https://github.com/redis/go-redis/pull/3656)) by [@&#8203;cxljs](https://github.com/cxljs) - **Proper formatting**: Code formatting improvements ([#&#8203;3670](https://github.com/redis/go-redis/pull/3670)) by [@&#8203;12ya](https://github.com/12ya) - **Set commands documentation**: Added comprehensive documentation to all set command methods ([#&#8203;3642](https://github.com/redis/go-redis/pull/3642)) by [@&#8203;iamamirsalehi](https://github.com/iamamirsalehi) - **MaxActiveConns docs**: Added default value documentation for `MaxActiveConns` ([#&#8203;3674](https://github.com/redis/go-redis/pull/3674)) by [@&#8203;codykaup](https://github.com/codykaup) - **README example update**: Updated README example ([#&#8203;3657](https://github.com/redis/go-redis/pull/3657)) by [@&#8203;cxljs](https://github.com/cxljs) - **Cluster maintnotif example**: Added example application for cluster maintenance notifications ([#&#8203;3651](https://github.com/redis/go-redis/pull/3651)) by [@&#8203;ndyakov](https://github.com/ndyakov) #### 👥 Contributors We'd like to thank all the contributors who worked on this release! [@&#8203;12ya](https://github.com/12ya), [@&#8203;Copilot](https://github.com/apps/copilot-swe-agent), [@&#8203;codykaup](https://github.com/codykaup), [@&#8203;cxljs](https://github.com/cxljs), [@&#8203;cyningsun](https://github.com/cyningsun), [@&#8203;feelshu](https://github.com/feelshu), [@&#8203;feiguoL](https://github.com/feiguoL), [@&#8203;iamamirsalehi](https://github.com/iamamirsalehi), [@&#8203;naveenchander30](https://github.com/naveenchander30), [@&#8203;ndyakov](https://github.com/ndyakov), [@&#8203;ofekshenawa](https://github.com/ofekshenawa), [@&#8203;veeceey](https://github.com/veeceey) </details> --- ### Configuration 📅 **Schedule**: (UTC) - Branch creation - Between 12:00 AM and 03:59 AM (`* 0-3 * * *`) - Automerge - Between 12:00 AM and 03:59 AM (`* 0-3 * * *`) 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0My4yMDguMiIsInVwZGF0ZWRJblZlciI6IjQzLjIwOC4yIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->
viceice-bot force-pushed renovate/github.com-redis-go-redis-v9-9.x from b6801add37
All checks were successful
test / test (pull_request) Successful in 1m12s
to a1f592e111
All checks were successful
test / test (pull_request) Successful in 1m20s
2026-06-05 06:35:43 +00:00
Compare
viceice-bot force-pushed renovate/github.com-redis-go-redis-v9-9.x from a1f592e111
All checks were successful
test / test (pull_request) Successful in 1m20s
to 1a96d5d5fc
All checks were successful
test / test (pull_request) Successful in 1m16s
2026-06-08 20:59:32 +00:00
Compare
mfenniak approved these changes 2026-06-09 01:57:52 +00:00
mfenniak deleted branch renovate/github.com-redis-go-redis-v9-9.x 2026-06-09 01:57:55 +00:00
Sign in to join this conversation.
No labels
No milestone
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
go-chi/session!107
No description provided.