excaliburpartners / OmniLinkBridge

MQTT bridge, web service API, time sync, and logging for HAI/Leviton OmniPro II controllers
GNU General Public License v3.0
41 stars 24 forks source link

Web service stops pushing status updates after connectivity loss #15

Open bash1979 opened 4 years ago

bash1979 commented 4 years ago

I use the web service option for integration with SmartThings. Lately, I've noticed that, if there is any interruption in connectivity (i.e. internet outage, router reboots, etc), the web service stops pushing status updates (even though it still responds to pull requests from SmartThings). So automations around motion or door open/close events no longer work because the updates aren't be pushed. The only way to fix is to reboot the SmartThings Hub and restart the OmniLinkBridge service (in that order).

The last entry in the log file is below. Anyone else seeing this?

2020-02-23 18:12:37,510 [126] ERROR OmniLinkBridge.WebAPI.WebNotification - An error occurred sending notification to http://192.168.1.197:39500/notify/omnilink System.Net.WebException: Unable to connect to the remote server ---> System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 192.168.1.197:39500 at System.Net.Sockets.Socket.InternalEndConnect(IAsyncResult asyncResult) at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult) at System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Exception& exception) --- End of inner exception stack trace --- at System.Net.HttpWebRequest.EndGetRequestStream(IAsyncResult asyncResult, TransportContext& context) at System.Net.HttpWebRequest.EndGetRequestStream(IAsyncResult asyncResult) at System.Net.WebClient.UploadBitsRequestCallback(IAsyncResult result) 2020-02-23 18:12:42,713 [126] ERROR OmniLinkBridge.WebAPI.WebNotification - An error occurred sending notification to http://192.168.1.197:39500/notify/omnilink System.Net.WebException: Unable to connect to the remote server ---> System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond 192.168.1.197:39500 at System.Net.Sockets.Socket.InternalEndConnect(IAsyncResult asyncResult) at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult) at System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Exception& exception) --- End of inner exception stack trace --- at System.Net.HttpWebRequest.EndGetRequestStream(IAsyncResult asyncResult, TransportContext& context) at System.Net.HttpWebRequest.EndGetRequestStream(IAsyncResult asyncResult) at System.Net.WebClient.UploadBitsRequestCallback(IAsyncResult result) 2020-02-23 18:13:04,041 [126] WARN OmniLinkBridge.Modules.OmniLinkII - CONNECTION STATUS: Retrying 2020-02-23 18:13:09,042 [126] WARN OmniLinkBridge.Modules.OmniLinkII - CONNECTION STATUS: Retrying 2020-02-23 18:13:16,058 [126] WARN OmniLinkBridge.Modules.OmniLinkII - CONNECTION STATUS: Retrying 2020-02-23 18:13:20,230 [7] ERROR OmniLinkBridge.Modules.OmniLinkII - CONNECTION STATUS: Connection Timed Out 2020-02-23 18:13:25,074 [126] WARN OmniLinkBridge.Modules.OmniLinkII - CONNECTION STATUS: Retrying

tblouse commented 4 years ago

I am experiencing similar loss of connectivity. Everything will work fine for about 10-15 minutes, and then it stops working. OmniLinkBridge is continuing to get status updates from HAI, but I am not seeing anything in the live log on SmartThings.