title: Java CompletableFuture threadpool used
body: <p>In the code below no matter what I set as the max value of i, the total number of threads never crosses 13. What thread pool does it use? Where can I find its default settings?</p>
  <pre><code>public static void main(String[] args) {
      // write your code here
      for (int i = 0; i &lt;= 5; i++) {
  
          System.out.println(&quot;kick off&quot; + i);
          CompletableFuture.runAsync(() -&gt; {
              try {
                  Thread.sleep(1000);
  
                  System.out.println(java.lang.Thread.activeCount());
              }
              catch (Exception e) {
                  System.out.println(&quot;error&quot;);
              }
          });
  
      }
      System.out.println(java.lang.Thread.activeCount());
      try {
          Thread.sleep(10000);
      }
      catch (InterruptedException e) {
          e.printStackTrace();
      }
  }
  </code></pre>