redis

  • Redis modules exist now, and mostly you do not need one

    4.0 added a C module API, and the ecosystem that follows — search, JSON, time series, filters — is genuinely capable. It also means running a Redis that…

  • MEMORY USAGE tells you which key is the problem

    –bigkeys reports the largest key by element count, which is not the same as the largest by memory — a hash with 500 short fields is smaller than…

  • A cache stampede on a single hot key

    A cached value expiring under load means every request that arrives in the next few hundred milliseconds recomputes it simultaneously — so the moment of highest cost is…

  • withoutOverlapping on a scheduled command

    A scheduled task that occasionally runs longer than its interval will be started again while the first is still going, which for an import means two processes writing…

  • Find the biggest key in Redis by memory

  • The DEL that blocked the server, and UNLINK

    A 400ms pause on every request, once an hour, caused by a cache cleanup nobody thought of as expensive. Redis is single-threaded, and freeing memory is work.

  • Probabilistic early expiry beats a lock

    Rather than coordinating who recomputes, let each reader decide independently with a probability that rises as the expiry approaches — so one request refreshes early and the rest…

  • Redis 4.0 UNLINK frees in the background

    Redis is single-threaded, so DEL on a structure with a million members blocks every other client for as long as freeing it takes — which is milliseconds for…

  • Queues, workers and the jobs that fail twice

    The email that arrived four times and the charge that arrived twice. What makes a job safe to run again, and keeping workers alive without them serving stale…

  • Redis beyond caching: locks, counters and rate limits

    The cache server was already there doing one job out of four. A lock that expires, a release that checks it still owns the lock, and a sliding-window…