TODO 掉线重连机制 (待完成)
This commit is contained in:
@@ -25,7 +25,7 @@ namespace RIZO_Helper.Tools
|
||||
public Action<string, int, int> Disconnected;
|
||||
|
||||
|
||||
public MqttHelper(string server, int port = 1883, string clientId = "wpf-demo", bool cleanSession = true)
|
||||
public MqttHelper(string server, int port = 1883, string clientId = "wpf-demo", bool cleanSession = false)
|
||||
{
|
||||
if (string.IsNullOrEmpty(server))
|
||||
throw new ArgumentNullException(nameof(server), "MQTT服务器地址不能为空");
|
||||
|
||||
Reference in New Issue
Block a user