Many thanks for the quick reply. I am not yet very familiar with OH3 - can you point me to where the cloud communciations is to be enabled? I don’t see an option for this under the bridge or in any of the obvious places under openHAB settings!
In the meantime, I was carefully watching the logs as the bridge went offline just now - nothing meaningful is posted to the logs unfortunately, even with TRACE enabled on the binding logs. The only thing we get is the bridge going offline, followed by the remaining Xiaomi devices:
2020-12-26 08:10:45.783 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'mihome:86sw2:7811dcb9d14c:158d00027c0edf' changed from OFFLINE (BRIDGE_OFFLINE) to UNINITIALIZED
2020-12-26 08:10:45.810 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'mihome:86sw2:7811dcb9d14c:158d00027c0edf' changed from UNINITIALIZED to UNINITIALIZED (HANDLER_MISSING_ERROR)
2020-12-26 08:10:45.812 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'mihome:sensor_motion_aq2:7811dcb9d14c:158d0002f3bd64' changed from OFFLINE (BRIDGE_OFFLINE) to UNINITIALIZED
2020-12-26 08:10:45.836 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'mihome:sensor_motion_aq2:7811dcb9d14c:158d0002f3bd64' changed from UNINITIALIZED to UNINITIALIZED (HANDLER_MISSING_ERROR)
I then did a “scan” for new devices for the Xiaomi Mihome binding. Even though the bridge is offline, the scan discovered the gateway, but also threw the following error:
2020-12-26 08:02:58.757 [DEBUG] [discovery.XiaomiItemDiscoveryService] - Start scan for items
2020-12-26 08:02:58.761 [DEBUG] [internal.handler.XiaomiBridgeHandler] - Having 1 Item Discovery listeners
2020-12-26 08:02:58.762 [DEBUG] [internal.handler.XiaomiBridgeHandler] - Triggered discovery
2020-12-26 08:02:58.763 [DEBUG] [internal.handler.XiaomiBridgeHandler] - Send to bridge mihome:bridge:7811dcb9d14c: {"cmd": "get_id_list"}
2020-12-26 08:02:58.764 [WARN ] [internal.handler.XiaomiBridgeHandler] - No token received from the gateway yet. Unable to encrypt the access key.
2020-12-26 08:02:58.766 [ERROR] [nternal.DiscoveryServiceRegistryImpl] - Cannot trigger scan for thing types '[mihome:ctrl_ln1, mihome:ctrl_ln2, mihome:sensor_motion, mihome:sensor_motion_aq2, mihome:86sw1, mihome:86sw2, mihome:sensor_magnet, mihome:sensor_magnet_aq2, mihome:sensor_plug, mihome:smoke, mihome:sensor_wleak_aq1, mihome:sensor_switch, mihome:sensor_switch_aq2, mihome:curtain, mihome:sensor_lock_aq1, mihome:gateway, mihome:natgas, mihome:sensor_cube, mihome:sensor_weather_v1, mihome:sensor_vibration, mihome:basic, mihome:ctrl_neutral1, mihome:ctrl_neutral2, mihome:sensor_ht]' on 'XiaomiItemDiscoveryService'!
java.lang.NullPointerException: null
at org.openhab.binding.mihome.internal.handler.XiaomiBridgeHandler.toJsonValue(XiaomiBridgeHandler.java:369) ~[?:?]
at org.openhab.binding.mihome.internal.handler.XiaomiBridgeHandler.sendCommandToBridge(XiaomiBridgeHandler.java:298) ~[?:?]
at org.openhab.binding.mihome.internal.handler.XiaomiBridgeHandler.sendCommandToBridge(XiaomiBridgeHandler.java:280) ~[?:?]
at org.openhab.binding.mihome.internal.handler.XiaomiBridgeHandler.writeToBridge(XiaomiBridgeHandler.java:317) ~[?:?]
at org.openhab.binding.mihome.internal.handler.XiaomiBridgeHandler.discoverItems(XiaomiBridgeHandler.java:393) ~[?:?]
at org.openhab.binding.mihome.internal.discovery.XiaomiItemDiscoveryService.startScan(XiaomiItemDiscoveryService.java:68) ~[?:?]
at org.openhab.core.config.discovery.AbstractDiscoveryService.startScan(AbstractDiscoveryService.java:194) ~[bundleFile:?]
at org.openhab.core.config.discovery.internal.DiscoveryServiceRegistryImpl.startScan(DiscoveryServiceRegistryImpl.java:377) [bundleFile:?]
at org.openhab.core.config.discovery.internal.DiscoveryServiceRegistryImpl.startScans(DiscoveryServiceRegistryImpl.java:353) [bundleFile:?]
at org.openhab.core.config.discovery.internal.DiscoveryServiceRegistryImpl.startScan(DiscoveryServiceRegistryImpl.java:211) [bundleFile:?]
at org.openhab.core.io.rest.core.internal.discovery.DiscoveryResource.scan(DiscoveryResource.java:105) [bundleFile:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:?]
at jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:?]
at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
at java.lang.reflect.Method.invoke(Method.java:566) ~[?:?]
at org.apache.cxf.service.invoker.AbstractInvoker.performInvocation(AbstractInvoker.java:179) [bundleFile:1.0.9]
at org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:96) [bundleFile:1.0.9]
at org.apache.cxf.jaxrs.JAXRSInvoker.invoke(JAXRSInvoker.java:201) [bundleFile:1.0.9]
at org.apache.cxf.jaxrs.JAXRSInvoker.invoke(JAXRSInvoker.java:104) [bundleFile:1.0.9]
at org.apache.cxf.interceptor.ServiceInvokerInterceptor$1.run(ServiceInvokerInterceptor.java:59) [bundleFile:1.0.9]
at org.apache.cxf.interceptor.ServiceInvokerInterceptor.handleMessage(ServiceInvokerInterceptor.java:96) [bundleFile:1.0.9]
at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:308) [bundleFile:1.0.9]
at org.apache.cxf.transport.ChainInitiationObserver.onMessage(ChainInitiationObserver.java:121) [bundleFile:1.0.9]
at org.apache.cxf.transport.http.AbstractHTTPDestination.invoke(AbstractHTTPDestination.java:267) [bundleFile:1.0.9]
at org.apache.cxf.transport.servlet.ServletController.invokeDestination(ServletController.java:234) [bundleFile:1.0.9]
at org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:208) [bundleFile:1.0.9]
at org.apache.cxf.transport.servlet.ServletController.invoke(ServletController.java:160) [bundleFile:1.0.9]
at org.apache.cxf.transport.servlet.CXFNonSpringServlet.invoke(CXFNonSpringServlet.java:216) [bundleFile:1.0.9]
at org.apache.cxf.transport.servlet.AbstractHTTPServlet.handleRequest(AbstractHTTPServlet.java:301) [bundleFile:1.0.9]
at org.apache.cxf.transport.servlet.AbstractHTTPServlet.doPost(AbstractHTTPServlet.java:220) [bundleFile:1.0.9]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:707) [bundleFile:3.1.0]
at org.apache.cxf.transport.servlet.AbstractHTTPServlet.service(AbstractHTTPServlet.java:276) [bundleFile:1.0.9]
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:852) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:544) [bundleFile:9.4.20.v20190813]
at org.ops4j.pax.web.service.jetty.internal.HttpServiceServletHandler.doHandle(HttpServiceServletHandler.java:71) [bundleFile:?]
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:536) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:235) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1581) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1307) [bundleFile:9.4.20.v20190813]
at org.ops4j.pax.web.service.jetty.internal.HttpServiceContext.doHandle(HttpServiceContext.java:293) [bundleFile:?]
at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:482) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1549) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1204) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141) [bundleFile:9.4.20.v20190813]
at org.ops4j.pax.web.service.jetty.internal.JettyServerHandlerCollection.handle(JettyServerHandlerCollection.java:80) [bundleFile:?]
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.Server.handle(Server.java:494) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:374) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:268) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:117) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:336) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:313) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:171) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:129) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:367) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:782) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:918) [bundleFile:9.4.20.v20190813]
at java.lang.Thread.run(Thread.java:834) [?:?]
2020-12-26 08:02:58.829 [DEBUG] [scovery.XiaomiBridgeDiscoveryService] - Stop scan
2020-12-26 08:02:58.830 [DEBUG] [.mihome.internal.socket.XiaomiSocket] - Interrupting receiver thread Thread[XiaomiSocketReceiveThread(0, discovery),5,main]
2020-12-26 08:02:58.831 [DEBUG] [nternal.socket.XiaomiDiscoverySocket] - Setup discovery socket
2020-12-26 08:02:58.832 [DEBUG] [nternal.socket.XiaomiDiscoverySocket] - Initialized socket to null:-1 on 0.0.0.0/0.0.0.0:52993
2020-12-26 08:02:58.833 [DEBUG] [scovery.XiaomiBridgeDiscoveryService] - Start scan for bridges
2020-12-26 08:02:58.849 [DEBUG] [.mihome.internal.socket.XiaomiSocket] - Received Datagram from 172.16.3.30:4321 on port 52993
2020-12-26 08:02:58.853 [DEBUG] [scovery.XiaomiBridgeDiscoveryService] - Received message {"cmd":"iam","port":"9898","sid":"7811dcb9d14c","model":"gateway","proto_version":"1.1.2","ip":"172.16.3.30"}
2020-12-26 08:02:58.854 [DEBUG] [scovery.XiaomiBridgeDiscoveryService] - Discovered Xiaomi Gateway - sid: 7811dcb9d14c ip: 172.16.3.30 port: 9898
2020-12-26 08:03:28.833 [DEBUG] [scovery.XiaomiBridgeDiscoveryService] - Stop scan
2020-12-26 08:03:28.839 [DEBUG] [.mihome.internal.socket.XiaomiSocket] - Interrupting receiver thread Thread[XiaomiSocketReceiveThread(0, discovery),5,main]
2020-12-26 08:03:28.845 [DEBUG] [.mihome.internal.socket.XiaomiSocket] - Closing socket java.net.DatagramSocket@5b9cf079
2020-12-26 08:03:28.849 [DEBUG] [.mihome.internal.socket.XiaomiSocket] - Receiver thread ended
Does this help?