title: Apache Spark exception handling
body: <p>I'm working with Apache Spark and I would like to now more about exception handling.</p>
  
  <p>My situation is that I have a quite complex process, and at the end I do an action.</p>
  
  <p>Obviously, I need to handle exception in the middle of process, so just at the end, so basically also when I do transformation like map, flatMap, etc...</p>
  
  <p>How would I go about handling exceptions? Tips would be appreciated.</p>