title: How to identify the issue when Java OutOfMemoryError?
body: <p>How to identify the issue when java <code>OutOfMemoryError</code> or <code>stackoverflow</code> comes in production. By which reason it is coming or why the server is down.</p>
  
  <p>For example I am developing an application which is lived on production and UAT. Instantly on production java <code>OutOfMemoryError</code> or <code>stackoverflow</code>. </p>
  
  <p>Then how can we track this issue, by which reason it has happened ? Is there any technique that can tell me by which code flow this is happening ?</p>
  
  <p>Please explain it. I have faced this issue many times.</p>