SSourav Saha
HomeExperienceSoftware DesignSystem DesignLearningBooksToolsContact
SSourav Saha

Building scalable backend systems, distributed infrastructure, and cloud-native applications.

Navigation

  • Home
  • Experience
  • Software Design
  • System Design
  • Learning

More

  • Books
  • Tools
  • Contact

Connect

  • LinkedIn
  • Email

© 2026 Sourav Saha. All rights reserved.

Built with using Next.js

Software Design

Core principles and patterns for building maintainable, resilient, and evolvable software systems.

This collection bridges the gap between writing code and designing software. We start with Clean Code and Code Smells, move into OOP and SOLID principles, and finish with Design Patterns. Each article uses practical Java examples, showing bad code, refactoring steps, and the final elegant solution.

Clean Code

Clean Code Principles: Why Good Software Design Matters

Master the foundational rules of Clean Code. Learn how to write maintainable, scalable, and readable Java code by focusing on meaningful names, small functions, and eliminating technical debt.

#clean-code#java#best-practices
May 14, 20245 min read
Read
Anti-Patterns

Recognizing Bad Code

Learn to identify long methods, god classes, feature envy, primitive obsession, and switch explosions in your Java applications — with refactoring examples.

#clean-code#refactoring#java
May 15, 20246 min read
Read
Refactoring

Refactoring Techniques That Actually Work

Master extract method, extract class, replace conditionals, and introduce parameter objects — practical refactoring techniques with Java examples.

#clean-code#refactoring#java
May 16, 20246 min read
Read
SOLID

The SOLID Principles Explained with Java Examples

A deep dive into SRP, OCP, LSP, ISP, and DIP — the five principles that make object-oriented systems scalable, testable, and maintainable.

#solid#oop#architecture
May 17, 20246 min read
Read
OOP

Core OOP Principles for Scalable Systems

Favor composition over inheritance, program to interfaces, encapsulate correctly, and build systems with high cohesion and low coupling — with Java examples.

#oop#java#best-practices
May 18, 20245 min read
Read
Design Patterns

Practical Design Patterns for Real-World Applications

Learn when to use design patterns and when NOT to. Covering Strategy, Factory, and Builder patterns with progressive Java/Spring Boot examples.

#design-patterns#java#spring-boot
May 19, 20246 min read
Read
Best Practices

Java & Spring Boot Best Practices

Master DRY vs WET vs AHA, KISS, YAGNI, and Dependency Injection from scratch — practical engineering principles every Java developer should know.

#java#spring-boot#clean-code
June 30, 20246 min read
Read
Behavioral Patterns

Memento Pattern

Capture and restore an object's internal state without violating encapsulation — the foundation of undo/redo.

#design-patterns#java#memento
July 19, 20245 min read
Read
Behavioral Patterns

Mediator Pattern

Define a central object that encapsulates how a set of objects interact — reduce chaotic many-to-many dependencies.

#design-patterns#java#mediator
July 24, 20245 min read
Read
Behavioral Patterns

State Pattern

Allow an object to alter its behavior when its internal state changes — appearing as if it changed its class.

#design-patterns#java#state
August 28, 20245 min read
Read
Structural Patterns

Adapter Pattern

Convert one interface into another that the client expects — bridge incompatible classes without modifying their source code.

#design-patterns#java#adapter
September 4, 20245 min read
Read
Behavioral Patterns

Interpreter Pattern

Define a grammar for a language and build an interpreter that processes sentences in that language.

#design-patterns#java#interpreter
September 8, 20245 min read
Read
Structural Patterns

Bridge Pattern

Decouple an abstraction from its implementation so both can vary independently — avoid a class explosion.

#design-patterns#java#bridge
September 19, 20245 min read
Read
Creational Patterns

Factory Pattern

Create objects without exposing the client to the concrete implementation being instantiated.

#design-patterns#java#factory
October 1, 20244 min read
Read
Structural Patterns

Decorator Pattern

Add behavior to objects dynamically by wrapping them — a flexible alternative to subclassing.

#design-patterns#java#decorator
October 19, 20245 min read
Read
Behavioral Patterns

Template Method Pattern

Define the skeleton of an algorithm in a superclass but let subclasses override specific steps without changing the overall structure.

#design-patterns#java#template-method
October 20, 20245 min read
Read
Structural Patterns

Composite Pattern

Compose objects into tree structures to treat individual objects and compositions uniformly.

#design-patterns#java#composite
November 1, 20245 min read
Read
Behavioral Patterns

Command Pattern

Encapsulate a request as an object — enabling undo, queuing, logging, and macro recording.

#design-patterns#java#command
December 18, 20245 min read
Read
Behavioral Patterns

Strategy Pattern

Define a family of algorithms, encapsulate each one, and make them interchangeable at runtime.

#design-patterns#java#strategy
December 25, 20245 min read
Read
Behavioral Patterns

Iterator Pattern

Sequentially access elements of a collection without exposing its underlying structure.

#design-patterns#java#iterator
December 28, 20245 min read
Read
Creational Patterns

Singleton Pattern

Ensure a class has exactly one instance and provide a global access point — the most used (and misused) design pattern.

#design-patterns#java#singleton
January 4, 20254 min read
Read
Creational Patterns

Prototype Pattern

Create new objects by cloning an existing instance instead of constructing from scratch — ideal for expensive or pre-configured objects.

#design-patterns#java#prototype
January 13, 20255 min read
Read
Creational Patterns

Abstract Factory Pattern

Create families of related objects without specifying their concrete classes — swap entire product families at once.

#design-patterns#java#abstract-factory
January 15, 20255 min read
Read
Behavioral Patterns

Observer Pattern

Define a one-to-many dependency so that when one object changes state, all its dependents are notified automatically.

#design-patterns#java#observer
January 20, 20255 min read
Read
Behavioral Patterns

Visitor Pattern

Separate algorithms from the objects on which they operate — add new operations without modifying the object structure.

#design-patterns#java#visitor
February 8, 20256 min read
Read
Structural Patterns

Proxy Pattern

Provide a surrogate that controls access to another object — add security, caching, or lazy loading transparently.

#design-patterns#java#proxy
February 25, 20255 min read
Read
Creational Patterns

Builder Pattern

Construct complex objects step by step, separating construction from representation to avoid telescoping constructors.

#design-patterns#java#builder
March 11, 20255 min read
Read
Structural Patterns

Flyweight Pattern

Share common state among many fine-grained objects to drastically reduce memory usage.

#design-patterns#java#flyweight
March 15, 20255 min read
Read
Behavioral Patterns

Chain of Responsibility Pattern

Pass a request along a chain of handlers until one handles it — decouple sender from receiver.

#design-patterns#java#chain-of-responsibility
April 14, 20255 min read
Read
Structural Patterns

Facade Pattern

Provide a simplified interface to a complex subsystem — hide the mess behind a clean API.

#design-patterns#java#facade
May 4, 20255 min read
Read