title: No managed connections available within configured blocking timeout (JBoss 7 and Postgres)
body: <p>Periodically i get error :</p>
  
  <blockquote>
    <p>ERROR JDBCExceptionReporter --> javax.resource.ResourceException: IJ000453: 
    Unable to get managed connection for java:jboss/datasources/myDB
    08:12:05,928 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/mySoftware].[jsp]] (ajp--xx.255.0.yyy-8109-21) Servlet.service() for servlet jsp threw exception: javax.resource.ResourceException: IJ000655: No managed connections available within configured blocking timeout (30000 [ms])
            at org.jboss.jca.core.connectionmanager.pool.mcp.SemaphoreArrayListManagedConnectionPool.getConnection(SemaphoreArrayListManagedConnectionPool.java:377) and etc.</p>
  </blockquote>
  
  <p>.</p>
  
  <p>So, i have next datasource config. on JBoss AS :</p>
  
  <pre><code>&lt;datasource jta="true" jndi-name="java:jboss/datasources/myDB" pool-name="ssbs-pssbs" enabled="true" use-ccm="true"&gt;
                      &lt;connection-url&gt;jdbc:postgresql://xx.255.0.yyy/myDatabase&lt;/connection-url&gt;
                      &lt;driver-class&gt;org.postgresql.Driver&lt;/driver-class&gt;
                      &lt;driver&gt;postgresql-jdbc4&lt;/driver&gt;
                      &lt;pool&gt;
                          &lt;min-pool-size&gt;30&lt;/min-pool-size&gt;
                          &lt;max-pool-size&gt;150&lt;/max-pool-size&gt;
                          &lt;prefill&gt;true&lt;/prefill&gt;
                          &lt;use-strict-min&gt;false&lt;/use-strict-min&gt;
                          &lt;flush-strategy&gt;FailingConnectionOnly&lt;/flush-strategy&gt;
                      &lt;/pool&gt;
                      &lt;security&gt;
                          &lt;user-name&gt;tick&lt;/user-name&gt;
                          &lt;password&gt;tack&lt;/password&gt;
                      &lt;/security&gt;
                      &lt;validation&gt;
                          &lt;check-valid-connection-sql&gt;SELECT 1&lt;/check-valid-connection-sql&gt;
                          &lt;validate-on-match&gt;false&lt;/validate-on-match&gt;
                          &lt;background-validation&gt;false&lt;/background-validation&gt;
                      &lt;/validation&gt;
                      &lt;timeout&gt;
                          &lt;blocking-timeout-millis&gt;30000&lt;/blocking-timeout-millis&gt;
                          &lt;idle-timeout-minutes&gt;5&lt;/idle-timeout-minutes&gt;
                      &lt;/timeout&gt;
                      &lt;statement&gt;
                          &lt;share-prepared-statements&gt;false&lt;/share-prepared-statements&gt;
                      &lt;/statement&gt;
                  &lt;/datasource&gt;
  </code></pre>
  
  <p>and in my Postgres server i allow max_connection on 500.
  Why i get this exception ? </p>