Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases now! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
System Design Guide for Software Professionals

You're reading from   System Design Guide for Software Professionals Build scalable solutions – from fundamental concepts to cracking top tech company interviews

Arrow left icon
Product type Paperback
Published in Aug 2024
Publisher Packt
ISBN-13 9781805124993
Length 384 pages
Edition 1st Edition
Arrow right icon
Authors (2):
Arrow left icon
Dhirendra Sinha Dhirendra Sinha
Author Profile Icon Dhirendra Sinha
Dhirendra Sinha
Tejas Chopra Tejas Chopra
Author Profile Icon Tejas Chopra
Tejas Chopra
Arrow right icon
View More author details
Toc

Table of Contents (21) Chapters Close

Preface 1. Part 1: Foundations of System Design
2. Chapter 1: Basics of System Design FREE CHAPTER 3. Chapter 2: Distributed System Attributes 4. Chapter 3: Distributed Systems Theorems and Data Structures 5. Part 2: Core Components of Distributed Systems
6. Chapter 4: Distributed Systems Building Blocks: DNS, Load Balancers, and Application Gateways 7. Chapter 5: Design and Implementation of System Components –Databases and Storage 8. Chapter 6: Distributed Cache 9. Chapter 7: Pub/Sub and Distributed Queues 10. Part 3: System Design in Practice
11. Chapter 8: Design and Implementation of System Components: API, Security, and Metrics 12. Chapter 9: System Design – URL Shortener 13. Chapter 10: System Design – Proximity Service 14. Chapter 11: Designing a Service Like Twitter 15. Chapter 12: Designing a Service Like Instagram 16. Chapter 13: Designing a Service Like Google Docs 17. Chapter 14: Designing a Service Like Netflix 18. Chapter 15: Tips for Interviewees 19. Chapter 16: System Design Cheat Sheet 20. Index

Enhancing scalability and data replication

In this section, we will explore how consistent hashing can bolster scalability and how to replicate partitioned data efficiently.

Boosting scalability

One of the essential design requirements for our system is scalability. We store key-value data across multiple storage nodes. Depending on demand, we might need to augment or diminish these storage nodes. This implies that we must distribute data across all nodes in the system to evenly distribute the load.

For instance, consider a scenario where we have four nodes, and we aim to balance the load equally by directing 25% of requests to each node. Traditionally, we would use the modulus operator to achieve this. Each incoming request comes with an associated key. On receiving a request, we calculate the hash of the key and then find the remainder when the hashed value is divided by the number of nodes (m). The remainder value (x) indicates the node number to which we route the request...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at AU $24.99/month. Cancel anytime