Course · 16 lessons

Architecture & Boundaries

Build Clean, Onion, and Hexagonal boundaries, inspect real project dependencies, and distinguish local models from storage and cluster guarantees.

  1. Dependency direction versus runtime calls

    Inject an inner-owned port and verify the real project reference graph.

    Architecture & Boundaries · 16 min
  2. Clean entities use cases and presenters

    Keep domain arithmetic separate from orchestration and text presentation.

    Architecture & Boundaries · 16 min
  3. Onion policy at the center

    Make an outer discount implementation depend on a domain-owned capability.

    Architecture & Boundaries · 16 min
  4. Hexagonal inbound and outbound ports

    Separate the driving operation from the capacity adapter it drives.

    Architecture & Boundaries · 16 min
  5. Aggregate invariants and domain services

    Protect basket state and keep cross-entity policy independent of formatting.

    Architecture & Boundaries · 16 min
  6. Repository and unit-of-work tradeoffs

    Model an explicit staged session without inventing EF Core behavior.

    Architecture & Boundaries · 16 min
  7. CQRS without a mandatory mediator

    Give commands and queries separate contracts in one process and one state model.

    Architecture & Boundaries · 16 min
  8. Vertical slices alongside dependency boundaries

    Group feature behavior without turning folders into architectural enforcement.

    Architecture & Boundaries · 16 min
  9. Validation results across boundaries

    Return a typed decision and keep presentation outside domain policy.

    Architecture & Boundaries · 16 min
  10. Strategy selection and explicit factories

    Choose a pricing policy visibly rather than hiding global service lookup.

    Architecture & Boundaries · 16 min
  11. Decorators and adapters solve different problems

    Translate a legacy API then add an observable boundary concern by composition.

    Architecture & Boundaries · 16 min
  12. Domain events and the outbox commit boundary

    Create an immutable transition and publish intent through one persistence port.

    Architecture & Boundaries · 16 min
  13. Modular monolith contracts and private state

    Expose a module facade while hiding its implementation behind assembly access rules.

    Architecture & Boundaries · 16 min
  14. Check actual project dependency direction

    Compare a declared graph fixture with a checker that reads real project files externally.

    Architecture & Boundaries · 16 min
  15. Local singleton state is not cluster coordination

    Recognize a state-scope anti-pattern without pretending two objects are a deployed cluster.

    Architecture & Boundaries · 16 min
  16. Capstone a bounded reservation architecture

    Compose domain transitions, application ports, in-memory persistence, and graph checks honestly.

    Architecture & Boundaries · 16 min