The Valkey devs announced the general availability of the brand-new version 8.0, marking a significant milestone in the project’s evolution.
As we informed you at the end of March, due to Redis changing its licensing policy and moving away from free software, the Valkey project emerged as a response to this decision, backed by major IT giants like Google, Oracle, and AWS.
While the initial version, 7.2.5, released over five months ago, focused on compatibility and license continuity, this major update introduces many new features to enhance speed, efficiency, and reliability. Here they are.
Valkey 8.0 Highlights
Valkey 8.0 introduces substantial improvements to the existing I/O threading system. Notably, asynchronous I/O threading allows the main and I/O threads to operate concurrently, maximizing throughput and minimizing bottlenecks.
Additionally, intelligent core utilization distributes I/O tasks across multiple cores based on real-time usage, reducing idle time and improving energy efficiency.
Another key enhancement is command batching, which optimizes memory access patterns by prefetching frequently accessed data. This minimizes CPU cache misses and reduces the number of memory accesses required for dictionary operations.
Altogether, these improvements enable Valkey 8.0 to handle up to 1.2 million Queries Per Second (QPS) on AWS’s r7g platform, a significant increase from the previous limit of 380K QPS.
The new major release also improves cluster scaling operations via slot migrations. Now, automatic failover for empty shards ensures high availability from the start of the scaling process.
Moreover, the replication of slot migration states synchronizes all CLUSTER SETSLOT
commands to replicas before execution on the primary node. This reduces the chance of unavailability if the primary fails.
In terms of replication, Valkey 8.0 introduces a dual-channel replication scheme. This allows the RDB (Redis Database file) and the replica backlog to be transferred simultaneously, accelerating synchronization. The primary node experiences reduced memory pressure, and the dedicated connection for RDB transfer frees up resources to handle client queries more efficiently.
Improved Observability and Efficiency
Valkey 8.0 features a comprehensive per-slot metrics infrastructure, providing detailed visibility into individual slots’ performance and resource usage.
This includes tracking each slot’s key counts, CPU usage, and network input/output bytes. Initial benchmarks indicate that enabling these detailed metrics incurs a negligible overhead of approximately 0.7% in QPS.
Efficiency gains are also realized through reductions in memory overhead. Keys are now embedded in the main dictionary, eliminating separate key pointers and significantly reducing memory usage.
For scenarios with 16-byte keys and 8โor 16-byte values, users can expect a 9-10% reduction in overall memory usage, along with performance improvements.
Additional Highlights
Valkey 8.0 also brings several other noteworthy features:
- Dual IPv4 and IPv6 Stack Support: Seamlessly operate in mixed IP environments for enhanced compatibility and flexibility.
- Improved Pub/Sub Efficiency: Lightweight cluster messages streamline communication, reducing overhead for faster operations.
- Valkey Over RDMA (Experimental): Direct memory access between clients and Valkey servers unlocks significant performance improvements, delivering up to a 275% increase in throughput.
Refer to the release announcement or review this article for in-depth information on all the improvements made in Valkey 8.0.