Skip to content

Latest commit

 

History

History
24 lines (23 loc) · 633 Bytes

README.md

File metadata and controls

24 lines (23 loc) · 633 Bytes

Java Multithreading

  • Threads
    • A Java Thread is an independent path of execution within a program.
    • Many Threads can run concurrently within a program.
    • Every Thread in Java is created and controlled by the java.lang.Thread class.
  • Ways
    • Extend Thread class
    • Implement Runnable interface
    • Anonymous implementation
    • Executor Services
  • Synchronization
    • Volatile keyword (to avoid issue caused by caching)
    • Synchronized keyword
      • Method
      • Code Blocks
  • Thread Pool
  • Countdown Latch
  • Blocking Queue
  • Wait And Notify
  • Re-Entrant Lock
  • Semaphore
  • Callable And Future
  • Interrupting Thread