Skip to content

Search is only available in production builds. Try building and previewing the site to test it out locally.

Nest modular monolith designed for service extraction

0001. Nest modular monolith designed for service extraction

Section titled “0001. Nest modular monolith designed for service extraction”
  • Status: accepted
  • Date: 2025-01-01

The API could be a classic tightly coupled Nest monolith or a premature microservice fleet. Hidden cross-module imports make later extraction expensive.

Ship apps/nest as a modular monolith: hexagonal feature modules, zero cross-module imports, EventBus / @frame/events for integration, ports/adapters at boundaries — so a module can move out later without a big-bang rewrite.

  • Agents must not add direct imports between feature modules.
  • Extraction path is phased (in-process → hybrid broker → independent services); see Starlight guide.
  • Shared persistence stays in @frame/models until a module owns its data boundary.
  • Skill: apps/nest/.agents/skills/frame-nest/SKILL.md
  • App context: apps/nest/AGENTS.md