Reconnect network on MQTT failure (#435)

This commit is contained in:
iranl
2024-07-31 13:15:26 +02:00
committed by GitHub
parent d132e76ae2
commit 8e513bb501
14 changed files with 56 additions and 32 deletions

View File

@@ -159,6 +159,7 @@ private:
Gpio* _gpio;
int _mqttConnectionState = 0;
int _mqttConnectCounter = 0;
long _mqttConnectedTs = -1;
bool _connectReplyReceived = false;
bool _firstDisconnected = true;
@@ -172,6 +173,8 @@ private:
int _networkTimeout = 0;
std::vector<MqttReceiver*> _mqttReceivers;
bool _restartOnDisconnect = false;
bool _checkUpdates = false;
bool _reconnectNetworkOnMqttDisconnect = false;
bool _firstConnect = true;
bool _publishDebugInfo = false;
bool _logIp = true;