Software Architecture

Architecture dictates structure. It defines components, connectors, and constraints. Good architecture supports maintainability, scalability, and performance. You organize logic into layers, microservices, or modules. Compare this to Algorithms, which solve finite sub-problems. Architecture frames the whole application over its entire lifespan.

Architectural Patterns

Monolith: A single, unified application. It simplifies initial development. It hinders scaling at massive user loads.

Microservices: Distinct, decoupled services. Scaling is simple. Deployment demands orchestration. Communication requires network protocols.

Event-Driven: Services react to state changes. This decouples producers and consumers. The system needs message brokers.

Design Principles

Separation of Concerns: Isolate distinct logic into dedicated sections.

Dependency Inversion: High-level modules rely on interface abstractions.

Single Responsibility: A module does one thing. It has one reason for change.