~/coding-interview/system-design-vocabulary-notes.md

System Design Interview Vocabulary Notes

2 min readDecember 28, 2020by Gorav Singal#coding-interview#system-design-interview
// TL;DR

Quick reference for system design terms — nodes, consistency, availability, partitioning, CAP theorem, load balancing, caching, sharding, and more.

System Design Interview Vocabulary Notes

In this post, we will see some of the frequently used concepts/vocabulary in System Design interviews preparations.

Node

This is very basic of all. An individual machine or server can be called as a node or a single container can be called as a node. Lets take it as a single unit which is running your code or microservice.

Consistency

Consistency means whatever data you have committed to your database, it should remain there. Any future read requests must return the last committed data. In a clustered environment or master/slave environment, every slave nodes must be replicated the data before any read request. i.e. You can read the last committed data from any of your cluster node.

Eventual Consistency

This has some relaxation from Consistency property. It says, all of my nodes in the cluster will eventually have the same data in near future. There might be some time window where some nodes returned the old data. But, they all will have the latest data in some time.

Thats what this term means, the nodes will be eventual consistent. And, they all will reach a state where all the nodes will have same data.

Availability

Availability in terms of data means, the data is available irrespective of some nodes going down. The system is always responding to the read or write requests.

Partition Tolerance

In a distributed environment, where there are multiple nodes working and data is replicated across multiple nodes. The system continues to work even when some nodes failed to work or communicate with each other.

Replication/Redundancy

Replication means the same data is copied across multiple nodes. This is kind of a backup, when one or more nodes dies those backups can become the primary data partition. The more the redundancy more the safety of data.

But, more redundancy means you are taking extra memory. This all depends upon the business requirements.

Scaling

Every machine or node is having a limited capacity to serve user request. A single node will have a finite set of hardware and memory. Scaling is all about designing yor system that your application can handle much larger traffic.

Scaling is of two types:

Vertical Scaling

This is the simplest of all. In this scaling, you increase the CPU/RAM/Storage of the server.

Horizontal Scaling

In this scheme, you have a finite set of computational capacity of each server. And, you increase the number of such nodes. And, such nodes will be behind some load balancer.

Sharding

This is very specific to how you save your data. With fairly large applications, you can not save all the data on a single machine. You need to split the data across multiple machines. There are various schemes of sharding depending upon the nature of data and database.

Each of those individual machines which are holding part of data are called Shards.

$ subscribe --weekly

One deep dive a week, in your inbox

System design, AI engineering, trading systems and interview prep. Tested code, real numbers. Free, and you can unsubscribe any time.

or read it on gyanbyte.substack.com

Share

Related Posts

Coding Interview - Facebook System Design Interview Types

Coding Interview - Facebook System Design Interview Types

System design interview is pretty common these days, specially if you are having…

Find the maximum sum of any continuous subarray of size K

Find the maximum sum of any continuous subarray of size K

Introduction You are given an array of integers with size N, and a number K…

What FAANG companies expect in their interview from candidates

What FAANG companies expect in their interview from candidates

Its every software engineer’s dream to work with the big FAANG companies…

Magical usage of Bitwise operators - Get optimized solutions for many arithmatic problems

Magical usage of Bitwise operators - Get optimized solutions for many arithmatic problems

Introduction I will list some of the interesting usage of bitwise operators…

How to prepare for your next Coding Interview

How to prepare for your next Coding Interview

Here are some tips while preparing for your coding interviews. 1. Do study or…

Radix Sort Algorithm

Radix Sort Algorithm

A number consists of digits. Example: 843. Its a 3-digit number. Radix sort…

Latest Posts

How to Stay Valuable as a Software Engineer in the AI Era: A Practical Playbook

How to Stay Valuable as a Software Engineer in the AI Era: A Practical Playbook

In the previous article I argued that AI is not killing software engineering…

How to Review AI-Generated Code: A Checklist for Catching What the Model Missed

How to Review AI-Generated Code: A Checklist for Catching What the Model Missed

A few months back I approved a PR that was almost entirely AI-generated. It…

How to Debug AI-Generated Code: Understand First, Fix Last

How to Debug AI-Generated Code: Understand First, Fix Last

In the last article I wrote about reviewing AI code before it goes in. This one…

The Future of Software Engineering: What AI Changes, What Stays, and Where the Jobs Go

The Future of Software Engineering: What AI Changes, What Stays, and Where the Jobs Go

Every few weeks somebody sends me a scary headline — “AI will replace all…

The Transactional Outbox Pattern: Never Lose an Event Again

The Transactional Outbox Pattern: Never Lose an Event Again

This is one of those patterns that looks like nothing until you get burnt once…

Event Sourcing, Explained: Store What Happened, Not Just the Final State

Event Sourcing, Explained: Store What Happened, Not Just the Final State

Here is a question I like to ask in interviews: your bank account shows a…