title: Java, Apache POI, XSSFWorkbook extremly slow
body: <p>I use Apache POI to read an excel file (xlsx)
  This works fine in Eclipse. 30.000 rows and 20 cols are no problem. Loaded after around 5 seconds.</p>
  <p>If I generate a runnable JAR File it doesnt process the excel file</p>
  <pre><code>    try {
          soeArraylist.clear();
          //JOptionPane.showMessageDialog(null, &quot;SoE Pre Test 1&quot;, &quot;Done&quot; , JOptionPane.INFORMATION_MESSAGE);
          //Workbook workbook2 = new XSSFWorkbook();
          //JOptionPane.showMessageDialog(null, &quot;SoE Pre Test 2&quot;, &quot;Done&quot; , JOptionPane.INFORMATION_MESSAGE); 
          
          JOptionPane.showMessageDialog(null, &quot;SoE Import started 1&quot;, &quot;Done&quot; , JOptionPane.INFORMATION_MESSAGE); 
          
          FileInputStream excelFile = new FileInputStream(new File(FILE__NAME));
          JOptionPane.showMessageDialog(null, &quot;SoE Import started 2 &quot; + FILE__NAME, &quot;Done&quot; , JOptionPane.INFORMATION_MESSAGE); 
          
          
          Workbook workbook = new XSSFWorkbook(excelFile);
          JOptionPane.showMessageDialog(null, &quot;SoE Import started 3&quot;, &quot;Done&quot; , JOptionPane.INFORMATION_MESSAGE); 
          
          Sheet datatypeSheet = workbook.getSheet(&quot;SoE&quot;);
          JOptionPane.showMessageDialog(null, &quot;SoE Import started 4&quot;, &quot;Done&quot; , JOptionPane.INFORMATION_MESSAGE); 
          
          Iterator&lt;Row&gt; iterator = datatypeSheet.iterator();
          JOptionPane.showMessageDialog(null, &quot;SoE Import started 5&quot;, &quot;Done&quot; , JOptionPane.INFORMATION_MESSAGE); 
          
          DataFormatter formatter = new DataFormatter(Locale.US);
          //JOptionPane.showMessageDialog(null, &quot;SoE Import started 6&quot;, &quot;Done&quot; , JOptionPane.INFORMATION_MESSAGE); 
          
          JOptionPane.showMessageDialog(null, &quot;File opened&quot;, &quot;Done&quot; , JOptionPane.INFORMATION_MESSAGE); 
          while (iterator.hasNext()) {
  
              Row currentRow = iterator.next();
  
   ........ code removed .......
  
      } catch (FileNotFoundException e) {
          e.printStackTrace();
          JOptionPane.showMessageDialog(null, &quot;SoE Import FileNotFoundException&quot;, &quot;FileNotFoundException&quot; , JOptionPane.INFORMATION_MESSAGE);
      } catch (IOException e) {
          e.printStackTrace();
          JOptionPane.showMessageDialog(null, &quot;SoE Import IOException&quot;, &quot;IOException&quot; , JOptionPane.INFORMATION_MESSAGE);
      }
  </code></pre>
  <p>So its stopps after SoE Import &quot;started 2&quot;
  OK it does not stopp but it looks like its processing for ages. After 1 hour still no result.</p>
  <p>I tried to create an empty Workbook and this last 20 seconds outside from Eclipse. In Eclipse it is less than 1 second</p>
  <pre><code>    JOptionPane.showMessageDialog(null, &quot;SoE Pre Test 1&quot;, &quot;Done&quot; , JOptionPane.INFORMATION_MESSAGE);
      Workbook workbook2 = new XSSFWorkbook();
      JOptionPane.showMessageDialog(null, &quot;SoE Pre Test 2&quot;, &quot;Done&quot; , JOptionPane.INFORMATION_MESSAGE);
  </code></pre>
  <p>Java is 1.8 in Eclipse and also on the W10 machine.
  I know there are some similar questions here but non of them have different times between Eclipse and as standalone JAR.</p>
  <p>Any Ideas ?</p>