YARN-2613. Support retry in NMClient for rolling-upgrades. (Contributed by Jian He)