Added a MapReduceListener class the listens for "master" or "worker" commands