Timeout Expired - Max Connection Pool
We are using Enterpise Library June 2005 relase for .NET Framework 1.1 in our application, having a Oracle 10g database.
We are getting the following error often,
Message : Timeout expired. The timeout period elapsed prior to obtaining a connection from the pool. This may have occurred because all pooled connections were in use and max pool size was reached.
Source : System.Data.OracleClient
Help link :
TargetSite : System.Data.OracleClient.OracleInternalConnection GetPooledConnection(System.String, System.Data.OracleClient.OracleConnectionString, System.Data.OracleClient.OracleConnection, Boolean ByRef)
Stack Trace : at System.Data.OracleClient.OracleConnectionPoolManager.GetPooledConnection(String encryptedConnectionString, OracleConnectionString options, OracleConnection owningObject, Boolean& isInTransaction)
at System.Data.OracleClient.OracleConnection.OpenInternal(OracleConnectionString parsedConnectionString, Object transact)
at System.Data.Common.DbDataAdapter.QuietOpen(IDbConnection connection, ConnectionState& originalState)
at System.Data.Common.DbDataAdapter.FillFromCommand(Object data, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior)
at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet)
at Microsoft.Practices.EnterpriseLibrary.Data.Database.DoLoadDataSet(DBCommandWrapper command, DataSet dataSet, String tableNames)
at Microsoft.Practices.EnterpriseLibrary.Data.Database.LoadDataSet(DBCommandWrapper command, DataSet dataSet, String tableNames)
at Microsoft.Practices.EnterpriseLibrary.Data.Oracle.OracleDatabase.LoadDataSet(DBCommandWrapper commandWrapper, DataSet dataSet, String tableNames)
at Microsoft.Practices.EnterpriseLibrary.Data.Database.LoadDataSet(DBCommandWrapper command, DataSet dataSet, String tableName)
at Microsoft.Practices.EnterpriseLibrary.Data.Database.ExecuteDataSet(DBCommandWrapper command)
at Microsoft.Practices.EnterpriseLibrary.Data.Oracle.OracleDatabase.ExecuteDataSet(DBCommandWrapper commandWrapper)
As per the Enterprise Library documentation and expert reviews (ref. MSDN Magazine Data Points) it was mentioned as,
The DAAB also helps manage connection state for you. For example, if you want to fill a DataSet or insert some rows by executing a stored procedure, the DAAB automatically opens and closes the connection when needed. It uses the open late, close early approach so that connection pooling is maximized.
We are using only ExecuteDataset and ExecuteNonQuery in our Business Layer. But not sure why this error is occuring on the server.
When we contacted our DBA it was told that "There were two listeners running".
We are pretty sure that there is no connections kept open in our application, since its been taken care by the DAAB.
Not sure what was the cause for this problem.
Did anyone encountered similar issue? Is there some settings to be done on the DB Server?
All inputs are very much appreciated.
This has been resolved.
At times, there were 2 listeners getting created in our DB, This causes slow performance in application and sometimes throws time-out error as well.
We were told that there was a reference to an Oracle bug #4518443, Oracle reported this bug on metalink and has given a patch for the fix.
After installing this patch p4518443_10201_AIX64-5L.zip from metalink for AIX system, the issue of spawning 2 listeres got resolved.
This is a problem only in Oracle 10g.