From 1c649d88b609e66a78835d07f91136488e39b2b3 Mon Sep 17 00:00:00 2001 From: Matthew Skinner Date: Sat, 19 Oct 2024 16:13:14 +1100 Subject: [PATCH] [ipcamera] Fix Reolink events do not auto restart (#17581) * Fix Reolink events do not auto restart. Signed-off-by: Matthew Skinner --- .../binding/ipcamera/internal/handler/IpCameraHandler.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/bundles/org.openhab.binding.ipcamera/src/main/java/org/openhab/binding/ipcamera/internal/handler/IpCameraHandler.java b/bundles/org.openhab.binding.ipcamera/src/main/java/org/openhab/binding/ipcamera/internal/handler/IpCameraHandler.java index 9707ae0ec748c..fe834f1cd5c67 100644 --- a/bundles/org.openhab.binding.ipcamera/src/main/java/org/openhab/binding/ipcamera/internal/handler/IpCameraHandler.java +++ b/bundles/org.openhab.binding.ipcamera/src/main/java/org/openhab/binding/ipcamera/internal/handler/IpCameraHandler.java @@ -1593,6 +1593,11 @@ void pollCameraRunnable() { sendHttpGET("/api.cgi?cmd=GetMdState&channel=" + cameraConfig.getNvrChannel() + reolinkAuth); } else { onvifCamera.sendOnvifRequest(RequestType.Renew, onvifCamera.subscriptionXAddr); + if (onvifCamera.pullMessageRequests.intValue() == 0) { + logger.debug("The alarm stream was not running for Reolink camera {}, re-starting it now", + cameraConfig.getIp()); + onvifCamera.sendOnvifRequest(RequestType.PullMessages, onvifCamera.subscriptionXAddr); + } } break; case DAHUA_THING: