SA-301b · Module 1

Bounded Contexts as Service Boundaries

4 min read

Domain-driven design gives us the concept of bounded contexts — areas of the business where a specific model and language apply consistently. The order context uses "order" to mean a customer purchase with line items and a shipping address. The warehouse context uses "order" to mean a pick list with bin locations and a shipping label. Same word, different models, different behaviors. A bounded context is the boundary within which a term has exactly one meaning.

Bounded contexts are natural service boundaries because they encapsulate a coherent model that can evolve independently. The order service and the warehouse service can each change their internal model without coordinating, as long as the contract between them — the events they share or the APIs they expose — remains stable. This is the operational definition of a good service boundary: the services on each side can be deployed, scaled, and modified independently.