Command Center

Forge mode

ํ•  ์ผ์„ ๋Š˜๋ฆฌ๋Š” ํŽ˜์ด์ง€๊ฐ€ ์•„๋‹ˆ๋‹ค. ๋„ค ๊ฐœ ๋ฌธ์„œ๋ฅผ ํ•˜๋‚˜์˜ ์‹คํ–‰ ์ˆœ์„œ๋กœ ์••์ถ•ํ•œ๋‹ค: campaign์ด ์˜ค๋Š˜ ์‚ฌ๊ณ ๋ฅผ ์ •ํ•˜๊ณ , lab์—์„œ ์ง์ ‘ ํ„ฐ๋œจ๋ฆฌ๊ณ , move๋กœ ๋‚ด ๋ง ์••์ถ•ํ•˜๊ณ , sparring์—์„œ ์˜์–ด๋กœ ๋งž๋Š”๋‹ค.

Start sparring
Only rule

์˜ค๋Š˜์€ ํ•œ stage๋งŒ ํ•œ๋‹ค. ํ•œ lab๋งŒ ํ„ฐ๋œจ๋ฆฐ๋‹ค. ํ•œ move๋งŒ ๋‚ด ๋ง๋กœ ์ฑ„์šด๋‹ค. ๊ทธ๋ฆฌ๊ณ  `/sparring`์—์„œ 5๋ฒˆ ๋งž๋Š”๋‹ค.

์ „์ฒด ๋ชฉ๋ก์€ ์ง€๋„์ผ ๋ฟ์ด๋‹ค. ์ฒดํฌ๋ฐ•์Šค ์ „์ฒด๋ฅผ ๋๋‚ด๋Š” ๊ฒŒ์ž„์ด ์•„๋‹ˆ๋ผ, ์‚ฌ๊ณ  ํ•˜๋‚˜๋ฅผ ๋ชธ์— ์ƒˆ๊ธฐ๋Š” ๊ฒŒ์ž„์ด๋‹ค.

1

Campaign

์˜ค๋Š˜ ์–ด๋–ค ์‚ฌ๊ณ ๋ฅผ ๊ฒช์„์ง€ ์ •ํ•œ๋‹ค. ์ˆœ์„œ๋ฅผ ๊ณ ๋ฏผํ•˜์ง€ ์•Š๋Š”๋‹ค.

docs/assets/CAMPAIGN.md
2

Lab

์ˆœ์ง„ํ•˜๊ฒŒ ๋งŒ๋“ค๊ณ , ๊ณต๊ฒฉํ•˜๊ณ , ๋ง๊ฐ€์ง„ ์ˆซ์ž/๋กœ๊ทธ๋ฅผ ์ง์ ‘ ๋ณธ๋‹ค.

docs/assets/EXPERIENCE_LABS.md
3

Move

๊ฒช์€ ์‚ฌ๊ณ ๋ฅผ System 15๋กœ, ์•Œ๊ณ ๋ฆฌ์ฆ˜ ๋ฌธ์ œ๋Š” Algorithm 10์œผ๋กœ ๋”ฐ๋กœ ์••์ถ•ํ•œ๋‹ค.

docs/assets/15_MOVES_MY_WORDS.md
4

Sparring

ํ™”๋ฉด์„ ๋ณด๋ฉด์„œ ์˜์–ด๋กœ ์žฌ์„ค๋ช…ํ•˜๊ณ  AIํ•œํ…Œ ๊ณต๊ฒฉ๋ฐ›๋Š”๋‹ค.

/sparring

Campaign spine

์ˆœ์„œ๋ฅผ ๊ณ ๋ฏผํ•˜์ง€ ๋ง๊ณ  ์œ„์—์„œ ์•„๋ž˜๋กœ. ๊ฐ stage๋Š” ์‚ฌ๊ณ  ํ•˜๋‚˜๋‹ค.

11 stages
0

Stage 0 - point shop baseline

Trigger: users, points, products, orders 4 tables and small Java/Spring APIs.

Symptom: It works because nothing has attacked it yet.

Lab
Build the naive version by hand.
Move
์ˆ˜1 ์ง„์‹ค์€ ํ•œ ๊ณณ์— / ์ˆ˜2 ๋ฌถ๋Š”๋‹ค
Sparring
Explain the source of truth and transaction boundary.
Metric
Basic happy-path latency + row counts.
1

Stage 1 - 1M users, slow reads

Trigger: Marketing succeeds; orders grow from small to millions.

Symptom: Order lookup becomes seconds, not milliseconds.

Lab
EXPLAIN ANALYZE, compound index, N+1, index write cost.
Move
์ˆ˜6 ๋œ ํ•œ๋‹ค / ์ˆ˜9 ๋ฏธ๋ฆฌ ํ•œ๋‹ค
Sparring
Explain index order and what p95/p99 prove.
Metric
p95/p99 query latency, rows scanned, buffers, insert cost.
2

Stage 2 - read spike, cache pain

Trigger: Sale page drives thousands of reads per second.

Symptom: DB CPU spikes; cache fixes reads but creates staleness and stampede.

Lab
Cache-aside, stale value, stampede, singleflight.
Move
์ˆ˜7 ๋ณต์‚ฌํ•œ๋‹ค / ์ˆ˜13 ํ•œ๋„๋ฅผ ๊ฑด๋‹ค
Sparring
Explain cache freshness, TTL, and stampede control.
Metric
cache hit rate, DB QPS, p95, stale response count.
3

Stage 3 - flash sale concurrency

Trigger: 100 items, 5000 buyers at once.

Symptom: Negative stock, double point deduction, deadlocks.

Lab
Lost update, CAS, lock order, isolation tour.
Move
์ˆ˜2 ๋ฌถ๋Š”๋‹ค / ์ˆ˜3 ๋ฉฑ๋“ฑํ•˜๊ฒŒ ๋ฐ˜๋ณตํ•œ๋‹ค
Sparring
Explain the invariant and how concurrent requests preserve it.
Metric
incorrect balance count, conflict rate, lock wait time.
4

Stage 4 - real money, payment webhooks

Trigger: External PG/webhook enters the system.

Symptom: Duplicate webhook double-charges or double-credits points.

Lab
Idempotency key, state machine, reconciliation.
Move
์ˆ˜3 ๋ฉฑ๋“ฑ / ์ˆ˜5 ๋Œ€์กฐ
Sparring
Explain retry safety and where the idempotency key lives.
Metric
duplicate attempts, dedup hits, reconciliation mismatch count.
5

Stage 5 - async split

Trigger: Order flow includes notification, points, stats, and takes seconds.

Symptom: DB commits but server dies before sending downstream work.

Lab
Half-state, outbox, Kafka duplicate/order/lag/poison/DLQ.
Move
์ˆ˜4 ๋จผ์ € ๊ธฐ๋กํ•˜๊ณ  ๋‚˜์ค‘ ํ–‰๋™ / ์ˆ˜10 ์ค„ ์„ธ์šด๋‹ค
Sparring
Explain outbox and why queue means latency and eventual consistency.
Metric
queue lag, DLQ count, consumer error rate, end-to-end delay.
6

Stage 6 - external dependency failure

Trigger: Shipping API hangs for 30 seconds.

Symptom: Threads pile up and unrelated endpoints slow down.

Lab
Timeout, circuit breaker, bulkhead, fallback.
Move
์ˆ˜13 ํ•œ๋„ / ์ˆ˜14 ๋ณด์ด๊ฒŒ ์‹คํŒจ
Sparring
Explain timeout budget, circuit breaker state, and fallback trade-off.
Metric
p99 latency, timeout count, open circuit count, thread pool usage.
7

Stage 7 - observability era

Trigger: Users say it is slow, but nobody knows where.

Symptom: No dashboard, no p95/p99, no trace, no root cause.

Lab
Prometheus/Grafana, memory leak, 3am diagnosis, postmortem.
Move
์ˆ˜14 ๋ณด์ด๊ฒŒ ์‹คํŒจ / ์ˆ˜5 ๋Œ€์กฐ
Sparring
Explain what you check first from metrics, logs, and traces.
Metric
RPS, error rate, p95/p99, heap, GC, pool saturation.
8

Stage 8 - search outgrows LIKE

Trigger: Product search is added on millions of rows.

Symptom: LIKE '%x%' dies; search index becomes a copy with lag.

Lab
LIKE vs Postgres FTS vs optional Elasticsearch.
Move
์ˆ˜7 ๋ณต์‚ฌํ•œ๋‹ค / ์ˆ˜9 ๋ฏธ๋ฆฌ ํ•œ๋‹ค
Sparring
Explain when FTS is enough and when ES earns its cost.
Metric
search p95, index lag, reindex time, result quality checks.
9

Stage 9 - data explosion

Trigger: orders reaches 100M rows.

Symptom: No single index makes all queries cheap; cross-partition work hurts.

Lab
Partitioning, batch inserts, CQRS-lite.
Move
์ˆ˜8 ์ชผ๊ฐ ๋‹ค / ์ˆ˜7 ๋ณต์‚ฌํ•œ๋‹ค
Sparring
Explain partition boundary and the cost of cross-boundary queries.
Metric
partition scan count, write throughput, aggregation latency.
10

Stage 10 - deployment fear

Trigger: The system is large enough that every change feels risky.

Symptom: A 200 response lies; old code may still be serving.

Lab
CI gate, Docker, rollback, running image digest verification.
Move
์ˆ˜14 ๋ณด์ด๊ฒŒ ์‹คํŒจ / ์ˆ˜5 ๋Œ€์กฐ
Sparring
Explain deploy verification and rollback with metrics.
Metric
running image digest, error rate, p99, health checks, rollback time.