Redis: Guides and Practical Know-how | Page 8 | mironsoft Blog
Redis
-
Apr 25, 2025
Classic Lua scripting with EVAL and EVALSHA has been the standard way to run atomic server logic in Redis for years, but it brings practical problems around maintainability, versioning, and replication behavior. Since Redis 7, Redis Functions offer a more structured alternative through FUNCTION LOAD, treating scripts as named, persistently stored libraries instead of ephemeral, hash-referenced individual scripts. What the switch looks like in practice, what advantages it brings, and where EVAL still remains the better choice, is what this article covers.
-
Apr 7, 2025
When Redis causes trouble in a Magento environment, only a handful of error patterns are really common: refused connections, OOM errors on writes, and session lock timeouts during checkout. This article walks through each of these error patterns systematically, showing the diagnostic steps and the concrete fix.
-
Apr 6, 2025
When a heavily requested Redis key expires, hundreds of concurrent requests often hit the database unchecked, because each request handles the cache miss independently. This phenomenon is called cache stampede or thundering herd and can be prevented deliberately with mutex locking or probabilistic early expiration, without giving up the benefits of the cache.
-
Mar 29, 2025
Cache invalidation rightfully counts as one of the two hard problems in computer science, because every strategy forces a trade-off between consistency, implementation effort and performance. Redis offers TTL-based, explicit and tag-based invalidation, and this article breaks down which strategy actually fits which use case.
-
Mar 28, 2025
Redis Cluster deterministically assigns every key to one of 16384 hash slots, which makes horizontal scaling possible without a central coordinator. Understanding the CRC16 slot calculation, the CROSSSLOT error on multi-key commands, and the targeted use of hash tags helps you avoid distribution problems and runtime errors before they hit production.
-
Mar 27, 2025
Anyone running Redis at thousands of commands per second eventually hits a limit that has nothing to do with the server's compute power: network latency between client and server. Pipelining solves exactly this problem by sending multiple commands as a batch, without waiting for a reply after each one.
-
Mar 23, 2025
Dragonfly is an in-memory data store introduced in 2022 that positions itself as a compatible replacement for Redis while internally pursuing a completely different architecture. Instead of a single thread, Dragonfly spreads work across multiple cores using a shared-nothing approach, uses a custom memory structure called Dashtable, and promises noticeably faster snapshots than Redis' fork-based RDB approach. This article explains how this architecture works technically, how solid the performance claims really are, and for which Magento operating scenarios a trial run already makes sense today.
-
Mar 21, 2025
Redis Geo-Commands do not store coordinates in a dedicated data structure but in a plain sorted set with a specially encoded score. Once you understand this mechanism, you can build radius searches, store locator features and distance calculations with a handful of commands, without a separate geo database.
-
Mar 19, 2025
A growing Redis Cluster sooner or later needs to move hash slots between nodes, take on new nodes, or remove old ones, all while the application keeps running uninterrupted. redis-cli --cluster reshard orchestrates this operation through the MIGRATING and IMPORTING state of individual slots, turning resharding into a controlled, live operation instead of a maintenance window.
-
Mar 13, 2025
Where Redis Pub/Sub irrevocably loses messages the moment no subscriber is listening, a Redis Stream stores every message durably in memory, with a sequential ID, consumer groups for distributed processing, and explicit acknowledgment via XACK. That makes Streams a lightweight alternative to Kafka for medium sized event logs.