云平台断开回调处添加线程休眠

zw
CZ 4 months ago
parent ab478ffd53
commit 691932d28c

@ -19,6 +19,7 @@ using Newtonsoft.Json;
using Newtonsoft.Json.Linq; using Newtonsoft.Json.Linq;
using Org.BouncyCastle.Utilities; using Org.BouncyCastle.Utilities;
using Repository.Station; using Repository.Station;
using Service.Cloud.Common;
using Service.Cloud.Handler; using Service.Cloud.Handler;
using Service.Cloud.Msg; using Service.Cloud.Msg;
using Service.Cloud.Msg.Cloud.Req; using Service.Cloud.Msg.Cloud.Req;
@ -386,6 +387,7 @@ public class CloudClient : IMqttClientConnectedHandler, IMqttApplicationMessageR
Connected = false; Connected = false;
if (AutoReConnect) if (AutoReConnect)
{ {
Thread.Sleep(5000);
Connect(); Connect();
} }
return Task.CompletedTask; return Task.CompletedTask;

Loading…
Cancel
Save