Redis er (effektivt) single-threaded ved kommandoudførelse, så hver kommando udføres atomart — fuldt ud, uden interleaving fra andre klienter. Denne atomaritet, kombineret med atomare sammensat kommandoer, er fundamental for at bruge Redis korrekt til tællere, låse og concurrency-sensitive operationer.
Single-threaded → atomare kommandoer
Redis executes commands ONE AT A TIME (single-threaded command processing):
→ each command runs to completion before the next starts
→ NO two commands interleave → every command is inherently ATOMIC
→ no race conditions WITHIN a single command
→ This simplicity is a feature: predictable, atomic operations without locks.
