HDFS-5624. Merging change r1611068 from trunk to branch-2.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1611075 13f79535-47bb-0310-9956-ffa450edef68
Merge r1611126 from trunk. YARN-2264. Fixed a race condition in DrainDispatcher which may cause random test failures. Contributed by Li Lu

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1611127 13f79535-47bb-0310-9956-ffa450edef68
HADOOP-10839. Merging change r1611134 from trunk to branch-2.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1611136 13f79535-47bb-0310-9956-ffa450edef68
HDFS-6689. Merging change r1611135 from trunk

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1611152 13f79535-47bb-0310-9956-ffa450edef68