Simple Java Program to demonstrate How to use Counting Semaphore in Java to achieve synchronization
Read this post on javarevisited.blogspot.com