08 January 2021

#Multithread

#MultiThread
What is the difference between Process and Thread?
What are the benefits of multi-threaded programming?
What is difference between user Thread and daemon Thread?
What are different states in lifecycle of Thread?
What do you understand about Thread Priority?
What is Thread Scheduler and Time Slicing?
What is context-switching in multi-threading?
What is volatile keyword in Java
What is ThreadLocal?
What is Thread Group? Why it?s advised not to use it?
What is Java Thread Dump, How can we get Java Thread dump of a Program?
What is Deadlock? How to analyze and avoid deadlock situation?
What is Java Timer Class? How to schedule a task to run after specific interval?
What is Thread Pool? How can we create Thread Pool in Java?
What will happen if we don?t override Thread class run() method?
What is atomic operation? What are atomic classes in Java Concurrency API?
What is Lock interface in Java Concurrency API? What are it?s benefits over synchronization?
What is Executors Framework?
What is BlockingQueue? How can we implement Producer-Consumer problem using Blocking Queue?
What is Callable and Future?
What is FutureTask class?
What are Concurrent Collection Classes?
What is Executors Class?
What are some of the improvements in Concurrency API in Java 8?
Why thread communication methods wait(), notify() and notifyAll() are in Object class?
Why wait(), notify() and notifyAll() methods have to be called from synchronized method or block?
Why Thread sleep() and yield() methods are static?
Which is more preferred ? Synchronized method or Synchronized block?
How can we create a Thread in Java?
How can we pause the execution of a Thread for specific time?
How can we make sure main() is the last thread to finish in Java Program?
How does thread communicate with each other?
How can we achieve thread safety in Java?
How to create daemon thread in Java?
Can we call run() method of a Thread class?
Thread
  • Thread - Thread Lifecycle, Thread Priorities, Thread Local Storage, Thread Safety, Thread Pool, Daemon Thread
  • Concurrency vs. Parallelism
  • Atomic variable
  • Locks (Mutexes) - GIL (Global Interpreter Lock), Spinlocks
  • Synchronization
  • Inter-Thread Communication
  • Starvation - LiveLock, Deadlock
  • Race Condition
  • Task Scheduling
  • Context Switching
  • Fork/Join Framework
  • ShutdownHook
  • Garbage collection
  • Cyclic barrier
  • CountDownLatch
  • Granularity
  • Latch
Which method must be implemented by all threads in Java?
start()
run()*
stop()
main()
Which of the following is a marker interface?
Runnable
Serializable
Cloneable
Both B and C*
#Multithreading #Concurrency #ParallelProgramming #ThreadSafety #Synchronization #Threading #ThreadPool #AsynchronousProgramming #ConcurrencyControl #ConcurrentProgramming #ParallelComputing #ThreadManagement #ThreadingIssues #Deadlock #RaceCondition #Mutex #AtomicOperations #ContextSwitching #ThreadLifecycle #ReactiveProgramming #ThreadPools #ThreadPriority #Locks #GIL #ThreadingModel

No comments:

Post a Comment

Most views on this month