title: jboss standalone-full.xml ,min-pool-size and max-pool-size issue
body: <p>need a help, i have a java application which is running on jboss -6. recently we got a requirement to keep our min-pool-size and max-pool-size  same, along with prefill value should be &quot;true'.</p>
  <pre><code>&lt;pool&gt;
  &lt;min-pool-size&gt;100&lt;/min-pool-size&gt;
  &lt;max-pool-size&gt;100&lt;/max-pool-size&gt;
  &lt;prefill&gt;true&lt;/prefill&gt;
  &lt;/pool&gt;
  </code></pre>
  <p>By default our standalone-full.xml has following datasource:</p>
  <pre><code> &lt;datasource jta=&quot;false&quot; jndi-name=&quot;java:jboss/&lt;datasourcename&gt;&quot; pool-name=&quot;&lt;datasourcename&gt;&quot; enabled=&quot;true&quot; use-java-context=&quot;true&quot; statistics-enabled=&quot;true&quot;&gt;
                      &lt;connection-url&gt;jdbc:mysql://&lt;dbhostip&gt;:&lt;port&gt;/&lt;dbdetailsForconnection&gt;&lt;/connection-url&gt;
                      &lt;driver&gt;mysql&lt;/driver&gt;
                      &lt;pool&gt;
                          &lt;max-pool-size&gt;100&lt;/min-pool-size&gt;
                          &lt;prefill&gt;true&lt;/prefill&gt;
                      &lt;/pool&gt;
  </code></pre>
  <p>we have requirement to set pool size like  below:</p>
  <pre><code>&lt;pool&gt;
  &lt;min-pool-size&gt;100&lt;/min-pool-size&gt;
  &lt;max-pool-size&gt;100&lt;/max-pool-size&gt;
  &lt;prefill&gt;true&lt;/prefill&gt;
  &lt;/pool&gt;
  </code></pre>
  <p>but every time when we make changes , our war files failed to get deployed.  We are getting following error:</p>
  <p>IJ000610: Unable to fill pool: javax.resource.ResourceException: Could not create connection
  When we define our connection pool setting like below:
  Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: Too many connections</p>
  <p>Approaches I tried:
  *remove datasource from jboss-cli and add datasource again
  *directly edit standalone-full.xml
  *after every change :reload it.
  *do the deployment and then edit xml ,reload afterward
  *before deployment ,edit, reload</p>
  <p>Solution: I have two solution to make it work :</p>
  <ol>
  <li>min  pool should be less than max</li>
  </ol>
  <pre><code>    &lt;pool&gt;
      &lt;min-pool-size&gt;1&lt;/min-pool-size&gt; 
      &lt;max-pool-size&gt;100&lt;/max-pool-size&gt;
      &lt;prefill&gt;true&lt;/prefill&gt;
      &lt;/pool&gt;
  </code></pre>
  <ol start="2">
  <li>Remove profill, as it will take min pool size as default to fill up the connection</li>
  </ol>
  <pre><code>    &lt;pool&gt;
      &lt;min-pool-size&gt;100&lt;/min-pool-size&gt;
      &lt;max-pool-size&gt;100&lt;/max-pool-size&gt; 
      &lt;/pool&gt;
  </code></pre>
  <p>but these solution are against the requirement.</p>