Learning paths

Multithreading: beginner to advanced

Start with what a thread is, then learn why shared data breaks and how to protect it, then the tools real systems use: thread pools, CompletableFuture, concurrent collections and virtual threads.

  • For: You know basic Java and want to understand threads properly, step by step.
  • By the end: You can write correct concurrent code, explain race conditions and deadlocks, and answer multithreading interview questions confidently.
  • Size: 8 lessons (35 min of reading, plus time to try the code), beginner to advanced
  1. ExecutorService, ThreadPoolExecutor and FutureConcurrency and the JVM, advanced, 6 min
  2. CompletableFutureConcurrency and the JVM, advanced, 3 min
  3. Virtual threadsConcurrency and the JVM, advanced, 3 min
  4. HashMap vs ConcurrentHashMapCollections compared, advanced, 3 min
  5. Fail-fast vs fail-safe iteratorsCollections compared, intermediate, 3 min

Other paths