优化连接池

This commit is contained in:
2026-04-20 11:16:59 +08:00
parent 8a61b56389
commit bd1ddfb0e7
4 changed files with 30 additions and 13 deletions
+6 -1
View File
@@ -330,7 +330,12 @@ namespace FineUIPro.Web
{
if (BLL.Funs.DBList.ContainsKey(System.Threading.Thread.CurrentThread.ManagedThreadId))
{
BLL.Funs.DBList.Remove(System.Threading.Thread.CurrentThread.ManagedThreadId);
Model.SGGLDB db ;
BLL.Funs.DBList.TryRemove(System.Threading.Thread.CurrentThread.ManagedThreadId,out db);
if (db != null)
{
db.Dispose();
}
}
if (BLL.SQLHelper.GetConn().State == ConnectionState.Open)