In this example we will see how to use Java.util.concurrent.SynchronousQueue. SynchronousQueue is a type of Blocking Queue (it implements BlockingQueue) As mentioned in the java docs , it is a blocking queue in which each insert operation must wait for a corresponding remove operation by another thread, and vice versa. This means that the queue can only contain a single ...
Read More »