Quick revision
The short answer
I would find the contexts from the business, not the code: run domain discovery such as event storming with business experts to find processes and the places where language changes, classify subdomains as core, supporting or generic, and draw boundaries around cohesive business capabilities rather than technical layers or tables. Change history from version control shows which code changes together and should stay together. Each context then gets exactly one owning team, because Conway's law means team structure will shape the system anyway, and we prove the boundaries as modules inside the monolith before extracting any service.
What to remember
In this answer, we found bounded contexts for eight teams by starting with domain discovery such as event storming to find processes and language differences, classifying subdomains as core, supporting or generic and investing most in the core, and drawing boundaries around cohesive business capabilities rather than technical layers or tables. We used change history to find code that changes together, assigned each context to one team because Conway's law means team structure shapes the system, and tested the boundaries as modules inside the monolith before extracting services.
Your turn
Answer it aloud as you would in the interview, or type your answer below. Then show one part at a time and compare.
I would find the contexts from the business, not the code: run domain discovery such as event storming with business experts to find processes and the places where language changes, classify subdomains as core, supporting or generic, and draw boundaries around cohesive business capabilities rather than technical layers or tables. Change history from version control shows which code changes together and should stay together. Each context then gets exactly one owning team, because Conway's law means team structure will shape the system anyway, and we prove the boundaries as modules inside the monolith before extracting any service.
Why this question is asked
Splitting a monolith across teams is one of the largest decisions an engineering organisation makes, and the boundaries chosen at the start tend to last for years. Draw them along technical lines, such as a front-end team, a services team and a database team, and every feature needs all teams. Draw them along business capabilities, and most features stay inside one team. Interviewers ask senior leaders this question to see whether they can run a discovery process with the business, use evidence from the code, and connect architecture to team design. In this answer, we will go through domain discovery, subdomain classification, drawing boundaries, using change history, assigning teams, and proving boundaries inside the monolith first.
1Start With Domain Discovery, Not the Code
The monolith's package structure tells us how the code was organised, often by technical layer, not how the business works. So we start with the people who know the business. Event storming is a well-known workshop format for this: domain experts and engineers put the business events on a long wall in time order, such as OrderPlaced, PaymentCaptured, ParcelShipped and ReturnRequested, then add the commands that cause them, the people or systems involved, and the rules in between.
Two things to look for emerge quickly. The first is clusters of events that belong to one business process and one group of people. The second is language changes: the point where the same word starts meaning something different, such as Order meaning a customer's purchase in one area and a purchase order to a supplier in another. Those shifts in language are strong hints of a context boundary. For eight teams, we would typically run a big-picture session over one or two days, then smaller sessions per area.
2Classify Subdomains: Core, Supporting, Generic
Not every part of the business deserves the same investment. A core subdomain is where the company differentiates itself, such as pricing and recommendations for a retailer or risk scoring for a lender. A supporting subdomain is necessary and specific to the business, but not a differentiator, such as returns handling. A generic subdomain is a problem every company has, such as authentication, invoicing or email delivery, where buying or using an off-the-shelf solution is often best.
This classification guides where the strongest teams and the most careful design go. It also guides the split: core areas deserve their own context and a dedicated team, while generic ones may be grouped or replaced by products.
| Subdomain | Type | Investment |
|---|---|---|
| Pricing and promotions | Core | Strongest team, own context, careful design |
| Catalogue and search | Core | Own context and team |
| Ordering and checkout | Supporting | Own context, solid but simple |
| Fulfilment and returns | Supporting | Own context |
| Payments | Generic, with provider | Thin context around a payment provider |
| Identity and login | Generic | Buy or use a standard product |
3Draw Boundaries Around Business Capabilities
A good bounded context covers a cohesive business capability: a thing the business does, with its own language, rules and data, such as pricing, fulfilment or customer accounts. We avoid boundaries along technical layers, because a 'data team' or an 'API team' would be involved in every feature. We also avoid drawing one context per database table, because tables are implementation details; one capability usually spans many tables, and one table in the monolith may hold data for two capabilities that should be split.
A useful test for a candidate boundary is to take the last twenty features the business asked for and see how many of them fall inside one context. If most do, the boundary fits. If most cross two or three contexts, it does not.
4Use Change History as Evidence
Workshops give us the business view; the version control history gives us the code's view. Files that are changed together in the same commits are coupled, whatever the package structure says. Analysing the last year or two of commits for co-change, with a script over git log or tools built for this, shows clusters of code that move together and the hotspots that change most often.
Notice how this complements the workshops. If the workshop suggests checkout and pricing are separate contexts but they change together in 412 commits, either the boundary is wrong or the current code mixes them and needs untangling before the split. Change history does not decide boundaries on its own, since it reflects the old design, but it is very good at revealing hidden coupling.
5Assign Each Context to One Team
Conway's law observes that systems end up mirroring the communication structure of the organisation that builds them. So if we draw boundaries and then assign teams that cut across them, the system will drift towards the team structure anyway. We use this deliberately: each bounded context is owned by exactly one team, which makes decisions and changes in it without asking others. One team may own two small contexts; a context should never be owned by two teams.
With eight teams, a plausible outcome is one team each for the two core contexts, one each for four supporting contexts, and two teams sharing several generic and platform concerns. Where the number of contexts and teams does not fit, we adjust the boundaries or the team structure, not the ownership rule.
6Prove the Boundaries as Modules First
Boundaries drawn on a wall are hypotheses. The cheapest way to test them is inside the monolith: restructure the code into modules, one per context, with explicit public APIs and no access to other modules' internals, enforced with Spring Modulith or ArchUnit tests. Each team works in its own module, and data access is restricted so each module uses only its own tables.
If a boundary is wrong, we find out when the module dependencies become circular or every feature needs changes in several modules, and moving code between modules is cheap. Once a module has been stable for a few months, extracting it into a service is a much smaller, safer step, and some modules may never need to be extracted at all.
- Event storming with business expertsprocesses, events, language changes
- Classify subdomainscore, supporting, generic
- Draft boundaries around capabilitiescheck against recent features
- Check change historyco-change and hotspots
- Assign one team per contextConway's law
- Build modules inside the monolithenforce with architecture tests
- Are module boundaries stable?YesExtract services where it pays offNoAdjust boundaries and repeat
7 steps in order. Play them, or step through them one at a time.
7Follow-up questions
What if the business experts disagree about the language?
That disagreement is useful information. It usually means two contexts meet there, each with a valid meaning. Rather than forcing agreement, we name both meanings, place them in separate contexts and decide how they translate.
How long should discovery take before teams start?
Weeks, not months. A big-picture workshop and a few focused sessions give a first map in two to four weeks. The module phase then refines it with real code, which is better evidence than more workshops.
Should we extract the core domain first?
Not necessarily. Core domains change most, so moving them first is risky. Teams often extract a well-understood supporting or generic context first to learn the mechanics, then the core once the platform and patterns are proven.
8Conclusion
In this answer, we found bounded contexts for eight teams by starting with domain discovery such as event storming to find processes and language differences, classifying subdomains as core, supporting or generic and investing most in the core, and drawing boundaries around cohesive business capabilities rather than technical layers or tables. We used change history to find code that changes together, assigned each context to one team because Conway's law means team structure shapes the system, and tested the boundaries as modules inside the monolith before extracting services.
Open with
I would start from the business rather than the code, because the monolith's packages usually reflect technical layers. So I would run event storming with domain experts and engineers: put the business events on a wall in time order, add commands, actors and rules, and look for clusters of events that belong to one process, and for places where the language changes, where the same word starts meaning something else.
Then, if they want more
Those are my candidate boundaries. Then I would classify the subdomains as core, supporting or generic, so the strongest teams and the most design effort go to the core, and generic things like identity can be bought.
I draw boundaries around business capabilities like pricing or fulfilment, never around layers or individual tables, and I test a draft by checking whether most recent features would fall inside one context.
Next I look at evidence from the code: co-change analysis of the git history shows which parts change together, and if two of my proposed contexts change together hundreds of times, either the boundary is wrong or the code needs untangling first.
Then each context gets exactly one owning team, because Conway's law says the system will follow the team structure anyway, so I would rather design both together. Finally, I would not extract services straight away.
I would restructure the monolith into modules per context with enforced boundaries, using Spring Modulith or ArchUnit, let them settle for a few months, and only then extract the ones where a separate service pays off.
About this answer
- Last updated
- 12 November 2026
- Checked
- Its structure and format are checked automatically. Use it as a carefully prepared study note: where a detail matters, confirm it against the official documentation for the version you use. What the checks cover
- Where the question comes from
- Written by Scrivio for practice. It is not taken from an interview.
Report an issue with this answer
Copy the line below and send it to the author with what you found. It carries the address of this page.
Issue with "You are splitting a large monolith across eight teams. How do you find bounded contexts...": https://scrivio-interview-library.netlify.app/java/domain-driven-design/93681dbc8e/