A comprehensive guide to multithreading and concurrency in Java, from fundamentals to advanced techniques. A great fit for engineers learning the basics of multi-threaded applications in theory and practice.
Articles
| # | Topic | Key Concepts |
|---|---|---|
| 01 – Threading Basics | Thread lifecycle, creation, interruption, pools | Thread states, Runnable, ExecutorService, volatile |
| 02 – Race Conditions and Data Races | Types of concurrency bugs | Race condition vs data race, CPU reordering, TOCTOU |
| 03 – Synchronization in Java | The synchronized keyword | Monitor locks, wait/notify, deadlock prevention |
| 04 – Locks and Conditions | Explicit locks | ReentrantLock, ReadWriteLock, StampedLock, Conditions |
| 05 – Semaphores | Resource limiting | Semaphore, TimedSemaphore, producer-consumer signaling |
| 06 – Atomic Classes and Operations | Lock-free primitives | CAS, AtomicInteger, AtomicReference, LongAdder, ABA problem |
| 07 – Lock-Free Algorithms | Building data structures without locks | CAS loops, lock-free stack/queue, backoff strategies |
| 08 – Future and CompletableFuture | Asynchronous computation | Future, CompletableFuture, chaining, combining, error handling |
| 09 – Virtual Threads | Lightweight threads (Java 21+) | Carrier threads, mounting/unmounting, pinning, structured concurrency |
Learning Path

problems Solved and Explained:
Coming soon…