deep dives
the interview-grade internals. source-level, bit-level, no hand-waving.
- 01HashMap, line by linehash spreading, (n-1) & hash, the resize split, and treeification.
- 02ConcurrentHashMap internalsCAS on empty bins, locked bin heads, and cooperative resizing.
- 03the string poolliterals, intern(), and every == trap in one place.
- 04string concatenation internalsfrom StringBuilder to invokedynamic and StringConcatFactory.
- 05the integer cachewhy -128..127, and how to make it bigger.
- 06singletons and double-checked lockingthe half-constructed object, and the three ways to do it right.
- 07ThreadLocal internalsweak keys, the per-thread map, and the thread pool leak.
- 08ThreadPoolExecutor internalsthe ctl field: run state and worker count in one int.
- 09how lambdas are compiledno anonymous classes. invokedynamic and LambdaMetafactory.
- 10virtual threads, insidecontinuations, mounting, unmounting, and pinning.
- 11ArrayList vs LinkedList, measuredbig-O says one thing, the CPU cache says another.
- 12the OutOfMemoryError zooevery OOM message, what it means, and what to do.
- 13equals and hashCode trapsmutable keys, inheritance, and the object that vanished from a set.
- 14class loader leakshow redeploying an app leaks an entire copy of it.