修改长时间内存会炸

This commit is contained in:
2026-03-25 17:51:43 +08:00
parent 1840794f40
commit d0c626c189
61 changed files with 82737 additions and 271 deletions

View File

@@ -229,15 +229,11 @@ namespace WebSite
T.Stop();
double d = CPUData.GetCPU();
DataTongJi.CPU_Data.Add(d);
// 简单的上限保护,避免长期积累导致内存膨胀
//if (DataTongJi.CPU_Data.Count > 1000)
//{
// DataTongJi.CPU_Data = new System.Collections.Concurrent.ConcurrentBag<double>();
//}
}
catch (Exception ex)
{
logger.Error("CPU 数量统计出错了:" + ex.Message);
logger.Error("CPU 数量统计出错了:" + ex.StackTrace);
}
finally
{