YARN-562. Modified NM to reject any containers allocated by a previous ResourceManager. Contributed by Jian He. MAPREDUCE-5167. Update MR App after YARN-562 to use the new builder API for the container. Contributed by Jian He.