我们的应用程序托管一个调度程序,每30秒对数据库执行一次调度,以便运行可用任务。但运行两个小时后,它开始给连接池耗尽错误。我们已经检查过我们已经关闭/放置了用于Mysql的所有连接。
9/26/2017 12:00:14 AM:MySql.Data.MySqlClient.MySqlException (0x80004005): error connecting: 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.
at MySql.Data.MySqlClient.MySqlPool.GetConnection()
at MySql.Data.MySqlClient.MySqlConnection.Open()
at com.ivp.rad.dal.RMYSQLDBProvider.GetConnection(String connectionString)
HResultDAL -> 0
Message -> error connecting: 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.
ExceptionSource -> MySql.Data
MachineName -> VM-asdf
CustomMessage -> MySql.Data.MySqlClient.MySqlException (0x80004005): error connecting: 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.