Cheat sheet (morning of)¶
Read this in the last 15 minutes. Nothing new; only recall.
Me in one breath¶
Full-stack engineer, 5 years at J.P. Morgan, Java + Spring Boot + React. Portfolio Insights (Model Portfolios for financial advisors) since May 2025; Index Research (client reporting) 2021–2025. Built Prayog, a simulated exchange. "I make complex systems visible."
Numbers to say¶
| What | Number |
|---|---|
| Years at J.P. Morgan | 5 (Jul 2021 – now) |
| Prayog matching | ~100 ns per command (JMH: 60–120 ns), one thread |
| Prayog throughput with fsync | 20,000 orders/s sustained (group commit) |
| Prayog order path median | ~12 ms on the Mac SSD (fsync); 0.8 ms fsync in Docker volume |
| Live stack steady state | p50 2.8 ms, p99 14 ms, p99.9 25 ms |
| GC incident | p99 445 ms, spikes 3.5 s; Serial GC in a 768 MiB container |
| Allocation cut | 12–21% per operation (boxing-free order index) |
| Decision records | 23 ADRs |
| Hackathon | Top 700 of 57,000+ developers |
| DeepRacer | 2nd place, team of 6 (2023); co-led for 700+ (2024) |
Prayog in 6 words each¶
- Single-writer matching: no locks, deterministic, ~100 ns.
- Answer after fsync: nothing acknowledged is ever lost.
- Deterministic replay: recovery, snapshots, standby, CI check.
- Kafka off order path: outage delays stream, never trading.
- Idempotent ledger: one transaction per batch, dedupe ids.
- Measure, don't guess: every number dated, machine named.
Top concepts to have crisp¶
- HashMap internals: buckets,
hash & (n-1), list → red-black tree at 8, resize at 0.75. - volatile vs. synchronized: visibility + ordering vs. also mutual exclusion;
count++needs atomic/lock. - happens-before: unlock→lock, volatile write→read, start, join.
- Virtual threads: cheap blocking threads for I/O; not for CPU work; avoid pinning.
- G1 vs. ZGC: pause target vs. concurrent sub-ms pauses (needs headroom).
- @Transactional pitfalls: self-invocation, checked exceptions don't roll back, public only.
- Kafka: order per partition by key; at-least-once + idempotent consumer;
acks=all+min.insync.replicas=2; rebalance; lag; DLQ. - React: re-render triggers; keys;
useEffectcleanup and deps;useMemo/useCallback/memo; Context vs. Redux; React 18 batching & transitions; React 19 actions. - JS: event loop (microtasks before macrotasks), closures,
this,Promise.all. - Caching: cache-aside, delete on write, TTL + jitter, stampede.
- Design steps: requirements → estimates → API → data → high-level → deep dives.
Rules for the room¶
- Pause, then answer in one line, then the example.
- Say "I", not "we", in stories.
- Don't know? Say what you know and how you'd find out.
- Draw boxes for anything with more than two parts.
- End with your 3 questions.