Scalability Flashcards
Scalability vs Performance
Performance:
Performance measures, how much time system takes to do single operation or for single user. If system is slow for single user we need improve performance. Which can achieved by changing flow or design of the system.
Scalability:
If system fast for single user and slow for multiple user we need to focus on Scaling. If system grows performance will degrades if system doesn’t scale or scalable.
How System Grows?
- More Users
- More Data
- More Functionality
- Complex system
- Various Geographical users
How to Scale a System?
- Vertical Scaling - Increasing single System Capacity called vertical scaling. like increasing RAM, Core and etc.
- Horizontal Scaling - Increasing no.of systems which handle the Req called Horizontal Scaling.
What are the pros & cons of Vertical scaling vs Horizontal Scaling?
Vertical Scaling | Horizontal Scaling
1. Single Point of failure | 1. Resilient
2. Won’t scale after some point | 2. Will Scale easily by ——————————————————–| increasing no.of Systems
3. communication b\w 2 process will be | 3. Uses network call slower
fast as it using inter process |
communication (like RPC) |
4. N/A | 4. Need Load balancing
5. Consistence | 5. Inconsistency
Which will work?
The Efficient scaling method is using Hybrid of both models.
First Scale single system by increasing it hardware capacities. Once it reaches it maximum limit increase the no.of system.