Link

Concurrency

Table of contents

  1. Java Memory Model
  2. Threads
    1. Daemons
    2. Waiting for a thread to finish (Join)
    3. ThreadLocal
    4. Stale Caches
    5. Race Conditions
    6. Methods that should never be used.
  3. Concurrent Data Classes
    1. Primitive Wrappers
    2. List
    3. Set
    4. Map
    5. Queue
    6. Exchanger
  4. Classic Concurrency Control
    1. Volatile
    2. Synchronized
    3. Deadlocks
  5. New Approach to Concurrency
    1. Executors and Schedulers
    2. Lock and ReentrantLock
    3. Latch
    4. CyclicBarrier
    5. Fork Join Framework
  6. Cost of Concurrency
  7. Miscellaneous

Java Memory Model

🚧 Pending 🚧

Threads

Thread Lifecycle Image copied from: Theory: Operating Systems and Code Execution

🚧 Pending 🚧

Daemons

🚧 Pending 🚧

Waiting for a thread to finish (Join)

🚧 Pending 🚧

ThreadLocal

🚧 Pending 🚧

Stale Caches

🚧 Pending 🚧

Race Conditions

🚧 Pending 🚧

Methods that should never be used.

🚧 Pending 🚧
  1. stop()
  2. suspend()

Concurrent Data Classes

🚧 Pending 🚧

Primitive Wrappers

🚧 Pending 🚧

List

🚧 Pending 🚧

Set

🚧 Pending 🚧

Map

🚧 Pending 🚧

Queue

🚧 Pending 🚧

Exchanger

🚧 Pending 🚧

Classic Concurrency Control

Volatile

🚧 Pending 🚧

Synchronized

🚧 Pending 🚧

Deadlocks

🚧 Pending 🚧

New Approach to Concurrency

Executors and Schedulers

🚧 Pending 🚧

Lock and ReentrantLock

🚧 Pending 🚧

Latch

🚧 Pending 🚧

CyclicBarrier

🚧 Pending 🚧

Fork Join Framework

🚧 Pending 🚧

Cost of Concurrency

Cost of context switching

🚧 Pending 🚧

Miscellaneous

  1. InterruptedException
  2. Flow