SOLID Principles
The SOLID principles are a set of five design principles in object-oriented programming intended to make software designs more understandable, flexible, and maintainable. This principle is an acronym of the five principles which are given below:
- Single Responsibility Principle
- This principle states that “A class should have only one reason to change” which means every class should have a single responsibility or single job or single purpose. In other words, a class should have only one job or purpose within the software system.
- Open/Closed Principle
- This principle states that “Software entities (classes, modules, functions, etc.) should be open for extension, but closed for modification” which means you should be able to extend a class behavior, without modifying it.
- Liskov’s Substitution Principle
- The principle was introduced by Barbara Liskov in 1987 and according to this principle “Derived or child classes must be substitutable for their base or parent classes“. This principle ensures that any class that is the child of a parent class should be usable in place of its parent without any unexpected behavior.
- Interface Segregation Principle
- This principle is the first principle that applies to Interfaces instead of classes in SOLID and it is similar to the single responsibility principle. It states that “do not force any client to implement an interface which is irrelevant to them“. Here your main goal is to focus on avoiding fat interface and give preference to many small client-specific interfaces. You should prefer many client interfaces rather than one general interface and each interface should have a specific responsibility.
- Dependency Inversion Principle
- The Dependency Inversion Principle (DIP) is a principle in object-oriented design that states that “High-level modules should not depend on low-level modules. Both should depend on abstractions“. Additionally, abstractions should not depend on details. Details should depend on abstractions.
Guide to System Design for Freshers
Starting your journey into the system design domain can be exciting and difficult, especially for freshers. In this article, we’ll provide a simplified model of system design aimed specifically at freshers/new grads. Whether you’re a new grad or transitioning into a tech career, understanding system design fundamentals is crucial for building scalable, efficient, and reliable software solutions.
So, let’s start with the guide for system design in a way that’s easy to learn and apply.
Important Topics of System Design for Freshers
- What is System Design?
- How to Design a System?
- System Design Life Cycle
- SOLID Principles
- What is Monolith Architecture?
- What is Microservices Architecture?
- Content Delivery Network (CDN)
- Object-Oriented Programming(OOP) for System Design
- Object-Oriented Analysis and Design(OOAD)
- What is High-Level Design(HLD)?
- What is Availability?
- What is Scalability?
- What is Reliability?
- CAP Theorem
- What is Latency?
- What is a Load Balancer?
- SQL vs NoSQL: Which Database to Choose in System Design?
- What is Caching?
- What is Low-Level Design(LLD)?
- Unified Modeling Language(UML)
- Structural UML Diagrams
- Behavioral UML Diagrams
- Design Patterns
- Design a URL Shortening Service (TinyURL)