[SOLVED]Error connecting to OpenHAB Cloud

Tags: #<Tag:0x00007f616e11e780> #<Tag:0x00007f616e11e6b8>

Due to an SD-Card error, I had to setup a new installation of OpenHAB.
Of course I had a backup :slight_smile:

My old installation was on 2.4.0 (Raspberry Pi 3B) … the new one is 2.5.6 (new OpenHabian installation) on an Raspberry Pi 4 (USB boot activated).

More or less, most parts are back to work.
But I still have an issue with my OpenHAB cloud connection.
I have to following error message in my log:

2020-06-28 18:52:35.180 [ERROR] [org.openhab.io.openhabcloud         ] - bundle
org.openhab.io.openhabcloud:2.5.6 (309)[org.openhab.io.openhabcloud.internal.CloudService(337)] : The setHttpClientFactory method has thrown an exception

java.lang.IllegalArgumentException: max threads (10) less than min threads (15)

	at org.eclipse.jetty.util.thread.QueuedThreadPool.<init>(QueuedThreadPool.java:118) ~[?:?]

	at org.eclipse.jetty.util.thread.QueuedThreadPool.<init>(QueuedThreadPool.java:112) ~[?:?]

	at org.eclipse.jetty.util.thread.QueuedThreadPool.<init>(QueuedThreadPool.java:107) ~[?:?]

	at org.eclipse.jetty.util.thread.QueuedThreadPool.<init>(QueuedThreadPool.java:102) ~[?:?]

	at org.eclipse.smarthome.io.net.http.internal.WebClientFactoryImpl.createThreadPool(WebClientFactoryImpl.java:350) ~[?:?]

	at org.eclipse.smarthome.io.net.http.internal.WebClientFactoryImpl.access$4(WebClientFactoryImpl.java:348) ~[?:?]

	at org.eclipse.smarthome.io.net.http.internal.WebClientFactoryImpl$2.run(WebClientFactoryImpl.java:273) ~[?:?]

	at org.eclipse.smarthome.io.net.http.internal.WebClientFactoryImpl$2.run(WebClientFactoryImpl.java:1) ~[?:?]

	at java.security.AccessController.doPrivileged(Native Method) ~[?:1.8.0_252]

	at org.eclipse.smarthome.io.net.http.internal.WebClientFactoryImpl.createHttpClientInternal(WebClientFactoryImpl.java:256) ~[?:?]

	at org.eclipse.smarthome.io.net.http.internal.WebClientFactoryImpl.createHttpClient(WebClientFactoryImpl.java:145) ~[?:?]

	at org.openhab.io.openhabcloud.internal.CloudService.setHttpClientFactory(CloudService.java:354) ~[?:?]

	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_252]

	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_252]

	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_252]

	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_252]

	at org.apache.felix.scr.impl.inject.methods.BaseMethod.invokeMethod(BaseMethod.java:228) ~[bundleFile:?]

	at org.apache.felix.scr.impl.inject.methods.BaseMethod.access$500(BaseMethod.java:41) ~[bundleFile:?]

	at org.apache.felix.scr.impl.inject.methods.BaseMethod$Resolved.invoke(BaseMethod.java:664) ~[bundleFile:?]

	at org.apache.felix.scr.impl.inject.methods.BaseMethod.invoke(BaseMethod.java:510) [bundleFile:?]

	at org.apache.felix.scr.impl.inject.methods.BindMethod.invoke(BindMethod.java:42) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.DependencyManager.doInvokeBindMethod(DependencyManager.java:1813) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.DependencyManager.bindDependency(DependencyManager.java:1637) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.DependencyManager.bind(DependencyManager.java:1624) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.createImplementationObject(SingleComponentManager.java:307) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.createComponent(SingleComponentManager.java:114) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.getService(SingleComponentManager.java:982) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.getServiceInternal(SingleComponentManager.java:955) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.getService(SingleComponentManager.java:900) [bundleFile:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceFactoryUse$1.run(ServiceFactoryUse.java:212) [org.eclipse.osgi-3.12.100.jar:?]

	at java.security.AccessController.doPrivileged(Native Method) [?:1.8.0_252]

	at org.eclipse.osgi.internal.serviceregistry.ServiceFactoryUse.factoryGetService(ServiceFactoryUse.java:210) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceFactoryUse.getService(ServiceFactoryUse.java:111) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceConsumer$2.getService(ServiceConsumer.java:45) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.getService(ServiceRegistrationImpl.java:508) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.getService(ServiceRegistry.java:461) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.framework.BundleContextImpl.getService(BundleContextImpl.java:624) [org.eclipse.osgi-3.12.100.jar:?]

	at com.eclipsesource.jaxrs.publisher.internal.ResourceTracker.addingService(ResourceTracker.java:39) [bundleFile:?]

	at org.osgi.util.tracker.ServiceTracker$Tracked.customizerAdding(ServiceTracker.java:941) [osgi.core-6.0.0.jar:?]

	at org.osgi.util.tracker.ServiceTracker$Tracked.customizerAdding(ServiceTracker.java:870) [osgi.core-6.0.0.jar:?]

	at org.osgi.util.tracker.AbstractTracked.trackAdding(AbstractTracked.java:256) [osgi.core-6.0.0.jar:?]

	at org.osgi.util.tracker.AbstractTracked.track(AbstractTracked.java:229) [osgi.core-6.0.0.jar:?]

	at org.osgi.util.tracker.ServiceTracker$Tracked.serviceChanged(ServiceTracker.java:901) [osgi.core-6.0.0.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:109) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.framework.BundleContextImpl.dispatchEvent(BundleContextImpl.java:920) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:862) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:801) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.setProperties(ServiceRegistrationImpl.java:168) [org.eclipse.osgi-3.12.100.jar:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.updateServiceRegistration(SingleComponentManager.java:622) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.modify(SingleComponentManager.java:819) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.reconfigure(SingleComponentManager.java:709) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.reconfigure(SingleComponentManager.java:673) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.ConfigurableComponentHolder.configurationUpdated(ConfigurableComponentHolder.java:435) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.RegionConfigurationSupport.configurationEvent(RegionConfigurationSupport.java:316) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.RegionConfigurationSupport$2.configurationEvent(RegionConfigurationSupport.java:118) [bundleFile:?]

	at org.apache.felix.cm.impl.ConfigurationManager$FireConfigurationEvent.sendEvent(ConfigurationManager.java:1709) [bundleFile:?]

	at org.apache.felix.cm.impl.ConfigurationManager$FireConfigurationEvent.run(ConfigurationManager.java:1651) [bundleFile:?]

	at org.apache.felix.cm.impl.UpdateThread.run0(UpdateThread.java:138) [bundleFile:?]

	at org.apache.felix.cm.impl.UpdateThread.run(UpdateThread.java:105) [bundleFile:?]

	at java.lang.Thread.run(Thread.java:748) [?:1.8.0_252]

2020-06-28 18:52:35.206 [ERROR] [org.openhab.io.openhabcloud         ] - bundle org.openhab.io.openhabcloud:2.5.6 (309)[org.openhab.io.openhabcloud.internal.CloudService(337)] : The activate method has thrown an exception

java.lang.NullPointerException: null

	at org.openhab.io.openhabcloud.internal.CloudService.modified(CloudService.java:227) ~[?:?]

	at org.openhab.io.openhabcloud.internal.CloudService.activate(CloudService.java:155) ~[?:?]

	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_252]

	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_252]

	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_252]

	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_252]

	at org.apache.felix.scr.impl.inject.methods.BaseMethod.invokeMethod(BaseMethod.java:228) ~[bundleFile:?]

	at org.apache.felix.scr.impl.inject.methods.BaseMethod.access$500(BaseMethod.java:41) ~[bundleFile:?]

	at org.apache.felix.scr.impl.inject.methods.BaseMethod$Resolved.invoke(BaseMethod.java:664) ~[bundleFile:?]

	at org.apache.felix.scr.impl.inject.methods.BaseMethod.invoke(BaseMethod.java:510) [bundleFile:?]

	at org.apache.felix.scr.impl.inject.methods.ActivateMethod.invoke(ActivateMethod.java:317) [bundleFile:?]

	at org.apache.felix.scr.impl.inject.methods.ActivateMethod.invoke(ActivateMethod.java:307) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.createImplementationObject(SingleComponentManager.java:340) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.createComponent(SingleComponentManager.java:114) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.getService(SingleComponentManager.java:982) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.getServiceInternal(SingleComponentManager.java:955) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.getService(SingleComponentManager.java:900) [bundleFile:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceFactoryUse$1.run(ServiceFactoryUse.java:212) [org.eclipse.osgi-3.12.100.jar:?]

	at java.security.AccessController.doPrivileged(Native Method) [?:1.8.0_252]

	at org.eclipse.osgi.internal.serviceregistry.ServiceFactoryUse.factoryGetService(ServiceFactoryUse.java:210) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceFactoryUse.getService(ServiceFactoryUse.java:111) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceConsumer$2.getService(ServiceConsumer.java:45) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.getService(ServiceRegistrationImpl.java:508) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.getService(ServiceRegistry.java:461) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.framework.BundleContextImpl.getService(BundleContextImpl.java:624) [org.eclipse.osgi-3.12.100.jar:?]

	at com.eclipsesource.jaxrs.publisher.internal.ResourceTracker.addingService(ResourceTracker.java:39) [bundleFile:?]

	at org.osgi.util.tracker.ServiceTracker$Tracked.customizerAdding(ServiceTracker.java:941) [osgi.core-6.0.0.jar:?]

	at org.osgi.util.tracker.ServiceTracker$Tracked.customizerAdding(ServiceTracker.java:870) [osgi.core-6.0.0.jar:?]

	at org.osgi.util.tracker.AbstractTracked.trackAdding(AbstractTracked.java:256) [osgi.core-6.0.0.jar:?]

	at org.osgi.util.tracker.AbstractTracked.track(AbstractTracked.java:229) [osgi.core-6.0.0.jar:?]

	at org.osgi.util.tracker.ServiceTracker$Tracked.serviceChanged(ServiceTracker.java:901) [osgi.core-6.0.0.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.FilteredServiceListener.serviceChanged(FilteredServiceListener.java:109) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.framework.BundleContextImpl.dispatchEvent(BundleContextImpl.java:920) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEventPrivileged(ServiceRegistry.java:862) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.publishServiceEvent(ServiceRegistry.java:801) [org.eclipse.osgi-3.12.100.jar:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.setProperties(ServiceRegistrationImpl.java:168) [org.eclipse.osgi-3.12.100.jar:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.updateServiceRegistration(SingleComponentManager.java:622) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.modify(SingleComponentManager.java:819) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.reconfigure(SingleComponentManager.java:709) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.reconfigure(SingleComponentManager.java:673) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.ConfigurableComponentHolder.configurationUpdated(ConfigurableComponentHolder.java:435) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.RegionConfigurationSupport.configurationEvent(RegionConfigurationSupport.java:316) [bundleFile:?]

	at org.apache.felix.scr.impl.manager.RegionConfigurationSupport$2.configurationEvent(RegionConfigurationSupport.java:118) [bundleFile:?]

	at org.apache.felix.cm.impl.ConfigurationManager$FireConfigurationEvent.sendEvent(ConfigurationManager.java:1709) [bundleFile:?]

	at org.apache.felix.cm.impl.ConfigurationManager$FireConfigurationEvent.run(ConfigurationManager.java:1651) [bundleFile:?]

	at org.apache.felix.cm.impl.UpdateThread.run0(UpdateThread.java:138) [bundleFile:?]

	at org.apache.felix.cm.impl.UpdateThread.run(UpdateThread.java:105) [bundleFile:?]

	at java.lang.Thread.run(Thread.java:748) [?:1.8.0_252]

The result is, that I’m not able to send push notifications (or is this not related to the error above?:

2020-06-28 19:00:01.466 [ERROR] [ntime.internal.engine.RuleEngineImpl] - Rule 'batteryalarmpush': The name 'sendNotification' cannot be resolved to an item or type; line 91, column 5, length 65

What can I do?

Just to clarify, you’ve updated the UUID and Secret in myopenhab to match your new installation and can control items remotely, but you can’t send notifications?

There’s a really old thread talking about something, but it’s from 2016. Still, worth trying the fix discussed near the end, which was to edit/save the rules file.

No, my local OpenHAB ist not online / not connected to MyOpenhab.org.

I checked my UUID and it was the same after restoring my OpenHAB backup file.
And I copied my secret to myopenhab … but still the same error.

What about this error message : “max threads (10) less than min threads (15)”?

I’m not using myopenhab to control items … I use myopenhab to send and receive push messages.

Okay, so you’re not even online. Your error messages are beyond my technical skills. I usually just search the community for strings (which is how I found the post I referenced earlier).

If you haven’t already done so, I’d probably start by uninstalling and reinstalling openHAB Cloud to see if that gets you back to normal.

I solved this issue :slight_smile:

After adding these lines to the runtime.cfg (location: $OPENHAB_CONF/services/runtime.cfg), everything is fine (no restart required):

org.eclipse.smarthome.webclient:minThreadsShared=20
org.eclipse.smarthome.webclient:maxThreadsShared=60
org.eclipse.smarthome.webclient:minThreadsCustom=15
org.eclipse.smarthome.webclient:maxThreadsCustom=25

1 Like