title: Kafka - producer - handle "failed to send"
body: <p>I'm running a 0.8 Kafka, and build a producer using the provided Java API.<br>
  The API functions of sending a message (or messages) return void.</p>
  
  <p>Is there a way to get the status of the sent message? If it sent or failed?</p>
  
  <p>This is extremely important to us since we are reading the messages from a file and we want to delete the file after all messages were sent. But if there were errors and some messages weren't sent and I delete the file it will cause a loss of a very important data.</p>