title: spark on yarn run double times when error
body: <p>I use the model that spark on yarn,when i meet a problem the spark would restart automatic.</p>
  
  <p>I want to run exact once whatever successful or fail.</p>
  
  <p>Is there any conf or api can set?</p>
  
  <p>I'm using spark version 1.5.</p>