title: Commit transaction then send email
body: <p>In Java, let's say I have a transaction that once it is committed, I want to do another action, in this case, send an email.</p>
  
  <p>Therefore,</p>
  
  <pre><code>try {
      transaction.begin()
      ...
      transaction.commit()
      // point 1
      Utility.sendEmail(...)
  } catch (Exception e) {
      transaction.rollback();
  }
  </code></pre>
  
  <p>Is it possible for the thread to die/get killed at point 1 and not send an email ?
  Any way to minimize this ? JTA + JMS perhaps, where the action of sending a message is part of a transaction ?
  I'm investigating an issue and exploring whether this is possible. JVM is still alive (no OOM). I do not know the inner working of the app server so not sure if this is possible.</p>