Syllabus

Follow Priya as QuickCart gets busy — threads, pools, locks, and patterns in plain language with real Java code.

Getting started

Getting started

Why one worker is not enough — threads, pools, and getting results back.

  1. 1One Worker Is Not Enough
  2. 2Hire a Crew — Thread Pools
  3. 3Waiting for Results

Async flow

Async flow

Chain work without blocking the whole shop.

  1. 4Pipelines with CompletableFuture

Shared data

Shared data

When many workers touch the same counter, shelf, or map.

  1. 5Race at the Counter
  2. 6Better Locks
  3. 7Safe Shelves — Concurrent Collections
  4. 8Fast Counters — Atomics
  5. 9Sticky Notes — ThreadLocal

Coordination

Coordination

Make workers wait for each other the right way.

  1. 10Meeting Points — Latch, Barrier, Semaphore

Parallel work

Parallel work

Split big jobs across CPU cores.

  1. 11Many Hands — Parallel Streams
  2. 12Divide and Conquer — ForkJoin

Patterns & pitfalls

Patterns & pitfalls

Classic kitchen flow, deadlocks, logs across threads, and reactive style.

  1. 13Kitchen to Counter — Producer-Consumer
  2. 14Everyone Waiting — Deadlocks
  3. 15Don't Lose the Order Id — MDC
  4. 16Event Streams — Reactive Basics

Interview

Interview

Say it out loud like you lived the story.

  1. 17Say It Out Loud