v2.11.4

nats-io/nats-serverv2.11.4May 22, 2025by github-actions[bot]

AI Summary

This is a maintenance release of the NATS server v2.11.4 that primarily focuses on bug fixes and performance improvements, particularly in JetStream. It updates Go to 1.24.3 and includes several important fixes for data integrity issues, deadlocks, and panics, along with enhanced TLS error logging.

Key Highlights

  • Go version updated to 1.24.3 for improved performance and security
  • TLS handshake errors now log certificate subject and SHA-256 hash for easier debugging
  • Fixed potential data loss when stream/consumer updates occur while all peers are offline
  • JetStream performance improved with faster per-subject limits enforcement and reduced allocations
  • Fixed multiple critical bugs including deadlocks, panics, and data inconsistencies in filestore and workqueue streams

New Features

  • Enhanced TLS error logging with certificate details (subject and SHA-256 hash)
  • Improved JetStream performance for filter-based message finding and interest state calculation
  • Stream and consumer updates now blocked when all peers are offline to prevent data loss
  • Reference-counted access time goroutines to prevent memory leaks
  • Fixed direct gets behavior with up_to_time or start_time parameters

Full Release Notes

## Changelog

Refer to the [2.11 Upgrade Guide](https://docs.nats.io/release-notes/whats_new/whats_new_211) for backwards compatibility notes with 2.10.x.

### Go Version

- 1.24.3 (#6876)

### Dependencies

- github.com/nats-io/nats.go v1.42.0 (#6868)
- golang.org/x/crypto v0.38.0 (#6868)
- golang.org/x/sys v0.33.0 (#6868)
- github.com/google/go-tpm v0.9.5 (#6918)

### Improved

General

- Log lines for TLS handshake errors now include the subject and SHA-256 hash of the certificate if known (#6883)

JetStream

- Enforcing per-subject limits on streams after a state rebuild or retention policy change is now considerably faster (#6871)
- Reduced allocations when finding the next message matching a filter in the filestore, which also improves the performance of calculating interest state on streams with an interest/WQ retention policy (#6908)

### Fixed

General

- Reloading the gateway TLS configuration now applies to implicit remotes (#6886)

JetStream

- Stream and consumer updates are no longer possible if all peers are offline, fixing a potential avenue for data loss (#6856)
- The stream first sequence is now adjusted correctly when purging over interior delete gaps (#6861)
- Consumer redeliveries are no longer incorrectly reported for consumers with a max deliver of 1 (#6877)
- Avoid resetting the first and last sequences of a workqueue stream to zero after a crash with unflushed data (#6882)
- Access time goroutines are now reference-counted and no longer leak (#6887)
- Fixed a deadlock that could occur when using `multi_last` direct gets or when calculating the first sequence number for a consumer with a deliver-last-per-subject deliver policy (#6899)
- A spelling error in a store error was fixed (#6895) Thanks to @cjohansen for the contribution!
- A rare panic in the filestore has been fixed (#6912)
- Direct gets will no longer return messages incorrectly with `up_to_time` or `start_time` in some configurations (#6911)
- Fixed a panic in the stree that could occur when removing subject state tracking for a short subject (#6914)

### Complete Changes
 
https://github.com/nats-io/nats-server/compare/v2.11.3...v2.11.4