Exercise 3: Why 2 of 8 Boundary Functions Is Fine, But 4 of 8 Wouldn't Be — Possible Solution ==================================================================== WHY 2 OF 8 DOESN'T UNDERMINE THE ORDER/USER SPLIT ------------------------------ This chapter verified 6 of 8 functions (75%) classify with zero ambiguity into a single domain, and the 2 boundary functions (send_order_confirmation_email, update_user_loyalty_points) both represent genuine cross-domain QUESTIONS - "tell this user their order total" and "give this user credit for this order" inherently involve both an order and a user; there is no way to phrase either action using only one domain's own data. A small number of boundary functions that correspond to real, meaningful cross-domain events is exactly what a GOOD split looks like: most responsibilities sort cleanly, and the handful that don't are there because the underlying business process genuinely spans two domains, not because the split itself was drawn in the wrong place. WHAT IT WOULD MEAN IF HALF THE FUNCTIONS WERE BOUNDARY FUNCTIONS ------------------------------ If 4 of 8 functions (50%) had come back classified as boundary functions, that would be a strong signal the Order/User split itself is wrong - not that Order and User happen to interact a lot. This chapter's own cohesion test ("do the things in one candidate group share the same data?") would be failing at scale: if half of a domain's own functions need data from BOTH candidate groups just to do their job, then Order and User aren't actually two separate cohesive things - they're one cohesive thing (say, "OrderFulfillment") that got arbitrarily split down the middle, with every other function forced to reach back across the artificial line just to get its work done. THE PRACTICAL TEST THIS SUGGESTS ------------------------------ A small number of boundary functions relative to the total (this chapter's own 2-of-8, 25%) is a normal, healthy sign of two real domains that occasionally need to coordinate. A boundary-function count approaching half the total is a sign to go back and redraw the boundary itself - possibly merging the two candidate groups back into one, or finding a genuinely different line to split along, rather than accepting a high rate of cross-domain functions as normal. WHY THIS WORKS AS AN ANSWER ------------------------------ The explanation is grounded in this chapter's own actual measured ratio (2 of 8, not an arbitrary "small number") and reasons about the hypothetical (half of 8) using the same cohesion definition this chapter opened with, rather than treating "some boundary functions exist" and "too many boundary functions exist" as the same finding.