AMRMClientAsync will stop if any exceptions thrown on allocate call

Details

Description

Currently, for any exceptions thrown on the allocate call of AMRMClientAsync, it will stop both heartbeat thread and the callback handler thread, leaving AMRMClient in an unusable state. Caller has to instantiate a new AMRMClient.
IMO, the threads should keep on running, it should be up to the caller whether to stop the AMRMClient or not.

Billie Rinaldi
added a comment - 14/Dec/16 20:34 +1. The patch looks good to me. I tried it out with YARN-5996 and verified that the AM continues working after onError has been received. Thanks, Jian He !