LavinMQ 2.12 is here
LavinMQ 2.12 focuses on memory and reliability. Brokers with many idle queues and connections use significantly less memory, garbage collection pauses are shorter, clusters fail over more reliably, and message store errors now pause queues instead of closing them.
The headline improvement is memory. Stats now keep a history buffer only while their values change, so idle queues, exchanges, channels, and connections cost almost nothing to track. At 100,000 idle queues, this saves about 1.4 GB. Idle queues also release the write segment from memory instead of holding it mapped until full. The combined effect is a much smaller working set for brokers that mix busy and idle resources.
Garbage collection pauses are significantly shorter. LavinMQ now links a custom build of libgc that fixes a bug in 8.2.12 where every collection rescanned the whole heap when thousands of connections and queues were present. With 20,000 queues and 2,000 connections, pauses drop from roughly 240 ms to 55 ms.
Two cluster failover bugs are fixed. A node that lost etcd lease keepalives after a single “no leader” response could hang at the next failover; keepalives are now retried and the node exits cleanly if none succeed within the lease TTL. A node stopped in the second after winning a leader election no longer becomes leader, which previously left the cluster without one. Queue, stream, MQTT session, and shovel pause state is now replicated, so pauses survive failover.
When a message store error occurs, a queue, stream, or MQTT session is now paused rather than closed. A temporary error can be resolved by resuming; unreadable message data puts the resource in a new failed state visible in the HTTP API and the management UI. Pausing and resuming MQTT sessions is now also available through the HTTP API, management UI, and lavinmqctl.
MQTT deliveries are batched into one socket write per burst, cutting server CPU per QoS 0 delivery from 9.3 µs to 1.5 µs and raising throughput from roughly 110,000 to 710,000 messages per second.
This release includes several breaking changes worth reviewing before upgrading: invalid boolean config values now stop startup instead of silently defaulting to false; data directories from before LavinMQ 1.0 are refused (upgrade with 2.11 first); streams paused on 2.11 start paused on 2.12; and the queue restart endpoint and button are removed.
Read the full release notes on GitHub for all changes, fixes, and upgrade notes.
Hailay Gebremeskel