System Design and Scaleability Questions

Get Started. It's Free
or sign up with your email address
System Design and Scaleability Questions by Mind Map: System Design and Scaleability Questions

1. Key Concepts

1.1. Horizontal vs. Vertical Scaling

1.1.1. Vertical increasing the resources of a specific node

1.1.2. Horizontal increasing number of nodes

1.2. Load Balancer

1.2.1. software application DNS based

1.2.2. hardware routers

1.3. Database Denormalization and NoSQL

1.3.1. to avoid joins

1.4. Database Partitioning (Sharding)

1.4.1. Vertical Partitioning by feature if one db gets very large you might need to repartition db

1.4.2. Key-Based (or Hash-Based) Partitioning adding new servers means reallocating all data

1.4.3. Directory-Based Partitioning lookup table can be a single point of failure consider ranges and duplicating the table accessing the table impacts performance

1.5. Caching

1.5.1. in-memory between your app layer and your data store

1.6. Asynchronous Processing & Queues

1.6.1. pre-process notifying when the process is done

1.7. Networking Metrics

1.7.1. Bandwidth (bit/s, Gbits/s) Max amount of data that can be transferred in a unit of time Best conditions

1.7.2. Throughput Actual amount of data that is transferred in time In real

1.7.3. Latency How long it takes data to go from one end to the other Delay between the sender and receiver

1.8. MapReduce

1.8.1. Map Takes in some data and emits a <key,value> pair

1.8.2. Reduce Takes a key and a set of associated values and "reduces" them, emitting a new key and value The result can be reduced again

2. Considerations (FARS-RW)

2.1. Failures

2.1.1. Plan for many or all of them

2.2. Availability

2.2.1. Uptime / Total time operational availability-> function of the percentage of time the system is operational

2.3. Reliability

2.3.1. Mean Time Between Failure (MTBF) = total time in service / number of failures

2.3.2. Failure Rate = number of failures / total time in service

2.3.3. a reliable machine has high availability but an available machine may or may not be very reliable

2.4. Security

2.5. Read-heavy vs. Write-heavy

2.5.1. caching vs queuing up the writes

3. Demonstrate you can analyse the problems

4. Handling the Questions

4.1. Communicate

4.2. Go broad first

4.2.1. consider easy to use clients owners flexibility scalability and efficiency

4.3. Use the whiteboard

4.3.1. help interviewer follow your proposed design

4.4. Acknowledge interviewer concerns

4.4.1. validate them make changes accordingly

4.5. Be careful about assumptions

4.5.1. State them explicitly

4.6. Estimate when necessary

4.7. Drive

4.7.1. ask questions be open about tradeoffs go deeper

5. Design

5.1. Systems (SMraDIR)

5.1.1. Scope the Problem what exactly you need to implement list major features

5.1.2. Make Reasonable Assumptions Evaluate "product sense"

5.1.3. Draw the Major Components What the system might look like Walk through from end-to-end to provide a flow Pretend to ignore major scaleability challenges at the moment

5.1.4. Identify the Key Issues What will be the bottlenecks or major challenges?

5.1.5. Redesign for the Key Issues Be open about limitations in your design

5.2. Algorithms (AMaGS)

5.2.1. Ask Questions

5.2.2. Make Believe pretend that data can fit on one machine provide the general outline for your solution

5.2.3. Get Real How much data can fit on one machine? What problems will occur when you split up the data?

5.2.4. Solve problems a solution can remove or mitigate an issue Mind iterative approach Solve problems as they emerge