4 Replies Latest reply on Jan 14, 2018 4:24 AM by Srinu Anumaneni

    wildfly-failed to auto release datasource connection to pool

    seetha s Newbie

      As we know in jboss 6 if the code not handled with closing DB connection then the application server will close it and throws a warning message which will occur immediately after the transaction session closed, but this option is not available by default in Wildfly server which we come know after a code with connection left open.By search for solution in this context came to know about flush-strategy needs to be configured to take care of the idle connection, but its strikes the mind,

      1. why this option is removed is not available by default in wildfly server ?
      2. is this part of improvising the performance of server activity for scanning idle connection?

      But because of the default auto release option missing, application code which was not touched for a long time need to be revisited again to manage the connection manually, so it will put a lot of work in front.

      To overcome that, if i provide the flush strategy as "IdleConnections" and idle-timeout-minutes as 0 then will it be the equivalent to immediate connection release configuration and at the same time is this advisable to take this configuration setup to production.

      we tried with below configuration, but the connection left open are not auto closed after the idle time out period 1 minute, so the below configuration also an inappropriate approach for handling idle connection then what would be the exact configuration to accomplish it ?

      <pool>

           <min-pool-size>10</min-pool-size>

           <max-pool-size>20</max-pool-size>

           <flush-strategy>IdleConnections</flush-strategy>

      </pool>

      <timeout>

           <idle-timeout-minutes>1</idle-timeout-minutes>

      </timeout>