Good Read: Producer Consumer Example
Reference:
http://www.cin.ufpe.br/~java/docs/tutorial/essential/threads/synchronization.html
Gives an example of Producer Consumer using java threads and synchronization and then via lock from the concurrency package
