1
This commit is contained in:
@@ -11,7 +11,7 @@
|
||||
{
|
||||
|
||||
|
||||
"Conn": "Data Source=139.224.232.211;User ID=root;Password=doantech123;Initial Catalog=GXAssembly;Port=3308",
|
||||
"Conn": "Data Source=139.224.232.211;User ID=root;Password=doantech123;Initial Catalog=pbl_huaxiang;Port=3308",
|
||||
"DbType": 0, //数据库类型 MySql = 0, SqlServer = 1, Oracle = 3,PgSql = 4
|
||||
"ConfigId": "0", //多租户唯一标识
|
||||
"IsAutoCloseConnection": true
|
||||
|
||||
@@ -74,8 +74,8 @@ namespace DOAN.ServiceCore
|
||||
await DbScoped.SugarScope.CopyNew().Insertable(storagelocation).ExecuteCommandAsync();
|
||||
|
||||
|
||||
await Task.Delay(3000, stoppingToken);
|
||||
Console.WriteLine("永驻线程,正在读取plc值 ");
|
||||
await Task.Delay(5000, stoppingToken);
|
||||
Console.WriteLine("永驻线程,正在读取plc值 "+ result);
|
||||
|
||||
index++;
|
||||
if (index > 16)
|
||||
|
||||
@@ -77,6 +77,7 @@ namespace DOAN.ServiceCore
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
PLCTool.ConnectClose();
|
||||
_cancellationTokenSource.Cancel();
|
||||
_executingTask.Wait();
|
||||
_cancellationTokenSource.Dispose();
|
||||
|
||||
Reference in New Issue
Block a user