title: java.lang.OutOfMemoryError: Java heap space while reading excel with Apache POI
body: <p>My file is <strong>9MB</strong> and I got this error while loading workbook.</p>
  
  <pre><code>XSSFWorkbook workbook = new XSSFWorkbook(excelFilePath); 
  </code></pre>
  
  <p>this line causes to  <code>java.lang.OutOfMemoryError: Java heap space</code></p>
  
  <p>How can I solve this? </p>