mqtt重连

main
刘妍 2025-12-04 17:00:21 +08:00
parent 1834d70b8b
commit cbdf836d6b
1 changed files with 1 additions and 1 deletions

View File

@ -95,7 +95,7 @@ const createConnection = (callback?) => {
// 重连回调
client.on('reconnect', () => {
console.log('MQTT正在重连...');
client = mqtt.connect(connectUrl, options);
// client = mqtt.connect(connectUrl, options);
});
});
// const clientId = 'mqttx_' + Math.random().toString(16).substring(2, 8);