Integrate Tom Arnfeld's changes.

From:
https://github.com/tarnfeld/mesos-hadoop/blob/1397ba13ddabbc4061c4ded3e8d1b6c60c5c7ca9/src/main/java/org/apache/hadoop/mapred/MesosTracker.java