50 cards
Scaling is the practice of increasing a system's capacity to handle growing demand. The two fundamental approaches are vertical scaling, which adds more power (CPU, RAM, disk) to an existing machine, and horizontal scaling, which adds more machines to the resource pool. Vertical scaling is simpler because it avoids dis...
Caching accelerates data access by storing frequently used information closer to where it is needed. Redis (Remote Dictionary Server) is a popular open-source, in-memory key-value data store that delivers sub-millisecond latency and supports rich data structures including strings, hashes, lists, sets, sorted sets, and...
As data volumes grow, distributing them across multiple database nodes becomes necessary. Sharding is a horizontal partitioning strategy that splits data across multiple database instances, with each shard holding a subset of total data. A shard key, such as user_id modulo the number of shards, determines where each re...
Monolithic architectures package all application functionality into a single deployable unit, which is simpler to develop and deploy initially but harder to scale individual components and ties the entire system to a single codebase and deployment. Microservices decompose the application into small, independently deplo...
Rate limiting controls the number of requests a client can make to a service within a given time window, protecting against abuse and ensuring fair resource usage. When limits are exceeded, services typically respond with HTTP 429 Too Many Requests along with a Retry-After header. Rate limits can be enforced per user,...
Asynchronous messaging decouples services and enables reliable communication at scale. Apache Kafka is a distributed event streaming platform used for building real-time data pipelines and streaming applications. Its core concepts include topics (named feeds of messages), partitions (which split topics for parallelism)...
Distributed systems face inherent trade-offs that shape every design decision. The CAP theorem states that a distributed data store can guarantee at most two of three properties simultaneously: consistency (every read receives the most recent write), availability (every request receives a response), and partition toler...