added CountdownLatch in order to wait for completion of jobs without have the waiting thread sitting at 100%.
CountLatch is more useful than CountdownLatch. Also used the latch for merging tasks, so now no thread is ever polling for jobs to finish.