-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Open
Description
.net framework 4.8
win10
Not all computers behave this way; it's just some computers.
The system has updated all patches
var conStr=.......;
var scb = new SqlConnectionStringBuilder(conStr);
scb.ApplicationName = "DscServerD";
scb.Pooling = false;
// scb.MinPoolSize = 5;
// scb.MaxPoolSize = 100;
// scb.LoadBalanceTimeout = 5;
conStr = scb.ConnectionString;
Console.WriteLine(conStr);
Console.WriteLine("start debug\r\n");
string sql = "SELECT sort_no AS id,sort_name AS name,leag_flag AS remark FROM leag_sort where ltrim(sort_no)<>'' order by sort_no ";
while (true)
{
Thread.Sleep(5000); //主进程1秒1次
try
{
using(SqlConnection conn=new SqlConnection(conStr))
{
using(SqlDataAdapter sda=new SqlDataAdapter(sql, conn))
{
using (DataTable dt = new DataTable())
{
sda.Fill(dt);
//HandleCount will increasing 3
Console.WriteLine(string.Format("hand:{0}; query count {1}", Process.GetCurrentProcess().HandleCount, dt.Rows.Count));
}
}
}
}
catch (Exception ex)
{
Console.WriteLine(string.Format("hand:{0}; debug:{1}", Process.GetCurrentProcess().HandleCount, ex.Message));
}
}

Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels