"매 작은 architectural seam 의 future change 의 unlock". 매 enabling point 의 매 system 의 specific spot — 매 intentionally placed extension hook / abstraction / boundary 의 매 later capability 의 enable. 매 Donella Meadows의 "leverage point" + Neal Ford 의 "evolutionary architecture" 의 fitness function 의 cousin.
매 핵심
매 무엇 / 무엇 X
무엇: 매 explicit 한 future-flexibility hook (interface / event / config flag / plugin).
무엇 X: 매 speculative generality (YAGNI 위반) — 매 enabling point 의 cheap / minimal.
매 indicator
매 small abstraction 의 매 large optionality 의 unlock.
매 reversible decision 의 keep — 매 매 one-way door 의 avoid.
매 cost-of-change 의 grow before it's added.
매 종류
Interface seam — 매 abstraction 의 swap.
Event hook — 매 publish / subscribe.
Feature flag — 매 runtime toggle.
Plugin point — 매 third-party extension.
Schema evolution slot — 매 versioning / optional field.
Configuration point — 매 env / DI binding.
매 응용
Strangler fig migration — 매 facade 의 enabling point.
Plugin systems (VSCode, Obsidian, Backstage).
Multi-tenant SaaS — 매 tenant-scoped extension.
💻 패턴
Pattern 1: Interface seam (TypeScript)
// 매 enabling point — payment provider 의 swap
interfacePaymentProvider{charge(amount: number,token: string):Promise<ChargeResult>;refund(chargeId: string):Promise<void>;}classStripeProviderimplementsPaymentProvider{/* ... */}classTossProviderimplementsPaymentProvider{/* ... */}// service 의 매 PaymentProvider 만 의 know
classCheckoutService{constructor(privatepayments: PaymentProvider){}}
Pattern 2: Event hook
typeHook<T>=(ctx: T)=>Promise<void>;classHookRegistry<T>{privatehooks: Hook<T>[]=[];register(h: Hook<T>){this.hooks.push(h);}asyncfire(ctx: T){for(consthofthis.hooks)awaith(ctx);}}// 매 enabling point — order placed 시 매 plugin 의 react
constorderPlaced=newHookRegistry<{orderId: string}>();orderPlaced.register(async({orderId})=>emailService.confirmation(orderId));orderPlaced.register(async({orderId})=>analytics.track("order",orderId));
Pattern 3: Feature flag (LaunchDarkly-style)
import{flags}from"./flags";asyncfunctioncheckout(req: CheckoutReq){if(awaitflags.isOn("new-checkout-flow",req.userId)){returnnewFlow(req);}returnlegacyFlow(req);}// 매 enabling point — 매 percentage rollout / kill switch / A/B.
// 매 v1 → v2 의 enabling point — optional field
interfaceOrderV1{id: string;items: Item[];}interfaceOrderV2extendsOrderV1{giftMessage?: string;// 매 backward-compatible add
shippingMethod?:"standard"|"express";}// 매 readers 의 매 둘 다 의 handle.
Pattern 6: Strangler fig facade
// 매 legacy / new 의 enabling point — facade 의 routing
asyncfunctiongetUser(id: string):Promise<User>{if(awaitisUserMigrated(id)){returnnewService.getUser(id);}returnlegacyService.getUser(id);}
Pattern 7: Fitness function (architecture test)
// 매 enabling point 의 의도된 boundary 의 verify
import{describe,it,expect}from"vitest";import{extractImports}from"./arch-test";describe("architecture",()=>{it("domain layer must not import infrastructure",()=>{constimports=extractImports("src/domain/**/*.ts");constviolations=imports.filter(i=>i.includes("/infrastructure/"));expect(violations).toEqual([]);});});
매 결정 기준
상황
Approach
매 evidence 의 future change
enabling point 의 add
매 speculative
YAGNI — skip
One-way door decision
enabling point 의 mandatory
Reversible decision
매 simple 의 ship, refactor later
Plugin ecosystem 의 plan
plugin point 의 first-class
기본값: 매 evidence-based — 매 2nd 번 같은 change 의 demand 시 enabling point 의 introduce ("Rule of three").