Harmony Hub activityStarting?

Hi. I will check tomorrow (or is it today but during the daytime), obviously the error code equal to -1 is not expected but for some reasons it occurs and only on some installations. May be some bug or correct behavior, no idea. A workaround will be simple, but let me try to find the root cause.

1 Like

Since I don’t see the same problem on my installation, also after upgrading the most recent snapshot, I have to ask for some help.

@elektrolubach could you please install this binding: https://www.dropbox.com/s/5fjn94ougcb2x8q/org.openhab.binding.harmonyhub-2.3.0-SNAPSHOT.jar?dl=0

It has extra logging added to the whistlingfish library, and paste the logs that follow STATE_DIGEST: start message.

In case of a successful trigger it looks like that:

2018-04-07 12:58:36.222 [DEBUG] [ingfish.harmony.protocol.EventStanza] - STATE_DIGEST: start
2018-04-07 12:58:36.223 [DEBUG] [ingfish.harmony.protocol.EventStanza] - CONTENT: {"sleepTimerId":-1,"runningZoneList":[],"configVersion":148,"activityId":"17316451","errorCode":"200","syncStatus":0,"time":1523055230,"stateVersion":584,"tzOffset":"7200","mode":3,"hubSwVersion":"4.14.123","deviceSetupState":[],"tzoffset":"7200","isSetupComplete":true,"contentVersion":112,"wifiStatus":1,"discoveryServer":"https:\/\/svcs.myharmony.com\/Discovery\/Discovery.svc","activityStatus":2,"runningActivityList":"17316451","tz":"CET-1CEST,M3.5.0,M10.4.0\/3","activitySetupState":false,"updates":{"100":"4.14.112","97":"4.14.112"},"hubUpdate":false,"sequence":false,"accountId":"7394939"}
2018-04-07 12:58:36.223 [DEBUG] [ingfish.harmony.protocol.EventStanza] - READ VALUE: ID=17316451, STATUS=2, ERRORCODE=200
2018-04-07 12:58:36.224 [DEBUG] [.whistlingfish.harmony.HarmonyClient] - Received event: type=STATE_DIGEST, id=17316451, status=ACTIVITY_IS_STARTED, error=200

Thanks
Pawel

Hi Pawel,
thanks for the really quick answer to this. I replaced the 2.2.0-version with the one provided by you and get the following debug output:

2018-04-07 21:17:10.339 [DEBUG] [ingfish.harmony.protocol.EventStanza] - STATE_DIGEST: start
2018-04-07 21:17:10.343 [DEBUG] [ingfish.harmony.protocol.EventStanza] - CONTENT: {"sleepTimerId":-1,"runningZoneList":[],"configVersion":207,"activityId":"29418203","syncStatus":0,"time":1523047602,"stateVersion":344,"tzOffset":"7200","mode":3,"hubSwVersion":"4.14.123","deviceSetupState":[],"tzoffset":"7200","isSetupComplete":true,"contentVersion":90,"wifiStatus":1,"discoveryServer":"https:\/\/svcs.myharmony.com\/Discovery\/Discovery.svc","activityStatus":1,"runningActivityList":"","tz":"CET-1CEST,M3.5.0,M10.4.0\/3","activitySetupState":false,"updates":{"97":"4.13.100"},"hubUpdate":false,"sequence":false,"accountId":"6835756"}
2018-04-07 21:17:10.347 [DEBUG] [ingfish.harmony.protocol.EventStanza] - READ VALUE: ID=29418203, STATUS=1, ERRORCODE=null
2018-04-07 21:17:10.350 [DEBUG] [.whistlingfish.harmony.HarmonyClient] - Received event: type=STATE_DIGEST, id=29418203, status=ACTIVITY_IS_STARTING, error=-1

2018-04-07 21:17:10.668 [DEBUG] [ingfish.harmony.protocol.EventStanza] - STATE_DIGEST: start
2018-04-07 21:17:10.671 [DEBUG] [ingfish.harmony.protocol.EventStanza] - CONTENT: {"sleepTimerId":-1,"runningZoneList":[],"configVersion":207,"activityId":"29418203","syncStatus":0,"time":1523047602,"stateVersion":345,"tzOffset":"7200","mode":3,"hubSwVersion":"4.14.123","deviceSetupState":[],"tzoffset":"7200","isSetupComplete":true,"contentVersion":90,"wifiStatus":1,"discoveryServer":"https:\/\/svcs.myharmony.com\/Discovery\/Discovery.svc","activityStatus":2,"runningActivityList":"","tz":"CET-1CEST,M3.5.0,M10.4.0\/3","activitySetupState":false,"updates":{"97":"4.13.100"},"hubUpdate":false,"sequence":false,"accountId":"6835756"}
2018-04-07 21:17:10.678 [DEBUG] [ingfish.harmony.protocol.EventStanza] - READ VALUE: ID=29418203, STATUS=2, ERRORCODE=null
2018-04-07 21:17:10.680 [DEBUG] [.whistlingfish.harmony.HarmonyClient] - Received event: type=STATE_DIGEST, id=29418203, status=ACTIVITY_IS_STARTED, error=-1
2018-04-07 21:17:10.698 [DEBUG] [.whistlingfish.harmony.HarmonyClient] - Received event: type=START_ACTIVITY_FINISHED, id=29418203, status=UNKNOWN, error=200
2018-04-07 21:17:10.702 [DEBUG] [.whistlingfish.harmony.HarmonyClient] - listener[org.openhab.binding.harmonyhub.handler.HarmonyHubHandler$1@e8c74e] notified: Activity[29418203]:Radio

2018-04-07 21:17:10.731 [DEBUG] [ingfish.harmony.protocol.EventStanza] - STATE_DIGEST: start
2018-04-07 21:17:10.740 [DEBUG] [ingfish.harmony.protocol.EventStanza] - CONTENT: {"sleepTimerId":-1,"runningZoneList":[],"configVersion":207,"activityId":"29418203","syncStatus":0,"time":1523047602,"stateVersion":346,"tzOffset":"7200","mode":3,"hubSwVersion":"4.14.123","deviceSetupState":[],"tzoffset":"7200","isSetupComplete":true,"contentVersion":90,"wifiStatus":1,"discoveryServer":"https:\/\/svcs.myharmony.com\/Discovery\/Discovery.svc","activityStatus":2,"runningActivityList":"29418203","tz":"CET-1CEST,M3.5.0,M10.4.0\/3","activitySetupState":false,"updates":{"97":"4.13.100"},"hubUpdate":false,"sequence":false,"accountId":"6835756"}
2018-04-07 21:17:10.745 [DEBUG] [ingfish.harmony.protocol.EventStanza] - READ VALUE: ID=29418203, STATUS=2, ERRORCODE=null
2018-04-07 21:17:10.747 [DEBUG] [.whistlingfish.harmony.HarmonyClient] - Received event: type=STATE_DIGEST, id=29418203, status=ACTIVITY_IS_STARTED, error=-1

It seams, the ERRORCODE is always “null” in my setup.

At least the Hub-SwVersion is equal, the other version strings I think are irrelevant, because referenced to the setup of the harmony activities.

Thanks again a lot for your help!

Regards
Jonathan

Great. It looks like for some reason the event received from the hub does not contain this one field: errorCode.
There is no documentation to that protocol. I think I can assume that lack of explicit errorCode means errorCode = 200 = everything is ok. I made such changes here:


You can try and use this version until the code gets merged.
Interesting case! Thanks for your help debugging it so far!
Pawel

Thanks for the quick bugfix.
Unfortunately the binding won’t install throwing a lot of exceptions during installation process. The first being this one:

2018-04-07 23:09:51.078 [ERROR] [org.openhab.binding.harmonyhub      ] - [org.openhab.binding.harmonyhub.internal.HarmonyHubHandlerFactory(32)] Error during instantiation of the implementation object

java.lang.Error: Unresolved compilation problems: 

	The import org.osgi.framework cannot be resolved

	The import com.google cannot be resolved

	Sets cannot be resolved

	ServiceRegistration cannot be resolved to a type

	ServiceRegistration cannot be resolved to a type

	ServiceRegistration cannot be resolved to a type

	ServiceRegistration cannot be resolved to a type

	ServiceRegistration cannot be resolved to a type

	BundleContext cannot be resolved to a type

	at org.openhab.binding.harmonyhub.internal.HarmonyHubHandlerFactory.<init>(HarmonyHubHandlerFactory.java:38) ~[?:?]

	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[?:?]

	at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) ~[?:?]

	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) ~[?:?]

	at java.lang.reflect.Constructor.newInstance(Constructor.java:423) ~[?:?]

	at java.lang.Class.newInstance(Class.java:442) ~[?:?]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.createImplementationObject(SingleComponentManager.java:237) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.createComponent(SingleComponentManager.java:109) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.getService(SingleComponentManager.java:906) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.getServiceInternal(SingleComponentManager.java:879) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.getService(SingleComponentManager.java:823) [42:org.apache.felix.scr:2.0.12]

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

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

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

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

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

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.getService(ServiceRegistrationImpl.java:496) [?:?]

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

	at org.eclipse.osgi.internal.framework.BundleContextImpl.getService(BundleContextImpl.java:619) [?:?]

	at org.apache.felix.scr.impl.manager.SingleRefPair.getServiceObject(SingleRefPair.java:72) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.inject.BindMethod.getServiceObject(BindMethod.java:651) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.DependencyManager.getServiceObject(DependencyManager.java:2201) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.DependencyManager$MultipleDynamicCustomizer.prebind(DependencyManager.java:403) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.DependencyManager.prebind(DependencyManager.java:1520) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager.collectDependencies(AbstractComponentManager.java:1006) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.getServiceInternal(SingleComponentManager.java:859) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.SingleComponentManager.getService(SingleComponentManager.java:823) [42:org.apache.felix.scr:2.0.12]

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

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

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

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

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

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.getService(ServiceRegistrationImpl.java:496) [?:?]

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

	at org.eclipse.osgi.internal.framework.BundleContextImpl.getService(BundleContextImpl.java:619) [?:?]

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

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

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

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

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

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

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

	at org.eclipse.osgi.internal.framework.BundleContextImpl.dispatchEvent(BundleContextImpl.java:915) [?:?]

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

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

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

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

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:127) [?:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:225) [?:?]

	at org.eclipse.osgi.internal.framework.BundleContextImpl.registerService(BundleContextImpl.java:464) [?:?]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager$3.register(AbstractComponentManager.java:887) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager$3.register(AbstractComponentManager.java:874) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.RegistrationManager.changeRegistration(RegistrationManager.java:132) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager.registerService(AbstractComponentManager.java:941) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager.activateInternal(AbstractComponentManager.java:741) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.DependencyManager$SingleStaticCustomizer.addedService(DependencyManager.java:1012) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.DependencyManager$SingleStaticCustomizer.addedService(DependencyManager.java:968) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerAdded(ServiceTracker.java:1215) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerAdded(ServiceTracker.java:1136) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$AbstractTracked.trackAdding(ServiceTracker.java:945) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$AbstractTracked.track(ServiceTracker.java:881) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.serviceChanged(ServiceTracker.java:1167) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.BundleComponentActivator$ListenerInfo.serviceChanged(BundleComponentActivator.java:127) [42:org.apache.felix.scr:2.0.12]

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

	at org.eclipse.osgi.internal.framework.BundleContextImpl.dispatchEvent(BundleContextImpl.java:915) [?:?]

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

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

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

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

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:127) [?:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:225) [?:?]

	at org.eclipse.osgi.internal.framework.BundleContextImpl.registerService(BundleContextImpl.java:464) [?:?]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager$3.register(AbstractComponentManager.java:887) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager$3.register(AbstractComponentManager.java:874) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.RegistrationManager.changeRegistration(RegistrationManager.java:132) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager.registerService(AbstractComponentManager.java:941) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager.activateInternal(AbstractComponentManager.java:741) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.DependencyManager$SingleStaticCustomizer.addedService(DependencyManager.java:1012) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.DependencyManager$SingleStaticCustomizer.addedService(DependencyManager.java:968) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerAdded(ServiceTracker.java:1215) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerAdded(ServiceTracker.java:1136) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$AbstractTracked.trackAdding(ServiceTracker.java:945) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$AbstractTracked.track(ServiceTracker.java:881) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.serviceChanged(ServiceTracker.java:1167) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.BundleComponentActivator$ListenerInfo.serviceChanged(BundleComponentActivator.java:127) [42:org.apache.felix.scr:2.0.12]

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

	at org.eclipse.osgi.internal.framework.BundleContextImpl.dispatchEvent(BundleContextImpl.java:915) [?:?]

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

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

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

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

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:127) [?:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:225) [?:?]

	at org.eclipse.osgi.internal.framework.BundleContextImpl.registerService(BundleContextImpl.java:464) [?:?]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager$3.register(AbstractComponentManager.java:887) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager$3.register(AbstractComponentManager.java:874) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.RegistrationManager.changeRegistration(RegistrationManager.java:132) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager.registerService(AbstractComponentManager.java:941) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager.activateInternal(AbstractComponentManager.java:741) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.DependencyManager$SingleStaticCustomizer.addedService(DependencyManager.java:1012) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.DependencyManager$SingleStaticCustomizer.addedService(DependencyManager.java:968) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerAdded(ServiceTracker.java:1215) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerAdded(ServiceTracker.java:1136) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$AbstractTracked.trackAdding(ServiceTracker.java:945) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$AbstractTracked.track(ServiceTracker.java:881) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.serviceChanged(ServiceTracker.java:1167) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.BundleComponentActivator$ListenerInfo.serviceChanged(BundleComponentActivator.java:127) [42:org.apache.felix.scr:2.0.12]

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

	at org.eclipse.osgi.internal.framework.BundleContextImpl.dispatchEvent(BundleContextImpl.java:915) [?:?]

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

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

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

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

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:127) [?:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:225) [?:?]

	at org.eclipse.osgi.internal.framework.BundleContextImpl.registerService(BundleContextImpl.java:464) [?:?]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager$3.register(AbstractComponentManager.java:887) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager$3.register(AbstractComponentManager.java:874) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.RegistrationManager.changeRegistration(RegistrationManager.java:132) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager.registerService(AbstractComponentManager.java:941) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager.activateInternal(AbstractComponentManager.java:741) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.DependencyManager$SingleStaticCustomizer.addedService(DependencyManager.java:1012) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.DependencyManager$SingleStaticCustomizer.addedService(DependencyManager.java:968) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerAdded(ServiceTracker.java:1215) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.customizerAdded(ServiceTracker.java:1136) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$AbstractTracked.trackAdding(ServiceTracker.java:945) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$AbstractTracked.track(ServiceTracker.java:881) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ServiceTracker$Tracked.serviceChanged(ServiceTracker.java:1167) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.BundleComponentActivator$ListenerInfo.serviceChanged(BundleComponentActivator.java:127) [42:org.apache.felix.scr:2.0.12]

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

	at org.eclipse.osgi.internal.framework.BundleContextImpl.dispatchEvent(BundleContextImpl.java:915) [?:?]

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

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

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

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

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistrationImpl.register(ServiceRegistrationImpl.java:127) [?:?]

	at org.eclipse.osgi.internal.serviceregistry.ServiceRegistry.registerService(ServiceRegistry.java:225) [?:?]

	at org.eclipse.osgi.internal.framework.BundleContextImpl.registerService(BundleContextImpl.java:464) [?:?]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager$3.register(AbstractComponentManager.java:887) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager$3.register(AbstractComponentManager.java:874) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.RegistrationManager.changeRegistration(RegistrationManager.java:132) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager.registerService(AbstractComponentManager.java:941) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager.activateInternal(AbstractComponentManager.java:741) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager.enableInternal(AbstractComponentManager.java:675) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.AbstractComponentManager.enable(AbstractComponentManager.java:430) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.manager.ConfigurableComponentHolder.enableComponents(ConfigurableComponentHolder.java:657) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.BundleComponentActivator.initialEnable(BundleComponentActivator.java:341) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.Activator.loadComponents(Activator.java:390) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.Activator.access$200(Activator.java:54) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.scr.impl.Activator$ScrExtension.start(Activator.java:265) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.utils.extender.AbstractExtender.createExtension(AbstractExtender.java:254) [42:org.apache.felix.scr:2.0.12]

	at org.apache.felix.utils.extender.AbstractExtender.modifiedBundle(AbstractExtender.java:227) [42:org.apache.felix.scr:2.0.12]

	at org.osgi.util.tracker.BundleTracker$Tracked.customizerModified(BundleTracker.java:482) [?:?]

	at org.osgi.util.tracker.BundleTracker$Tracked.customizerModified(BundleTracker.java:415) [?:?]

	at org.osgi.util.tracker.AbstractTracked.track(AbstractTracked.java:232) [?:?]

	at org.osgi.util.tracker.BundleTracker$Tracked.bundleChanged(BundleTracker.java:444) [?:?]

	at org.eclipse.osgi.internal.framework.BundleContextImpl.dispatchEvent(BundleContextImpl.java:903) [?:?]

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

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

	at org.eclipse.osgi.internal.framework.EquinoxEventPublisher.publishBundleEventPrivileged(EquinoxEventPublisher.java:213) [?:?]

	at org.eclipse.osgi.internal.framework.EquinoxEventPublisher.publishBundleEvent(EquinoxEventPublisher.java:120) [?:?]

	at org.eclipse.osgi.internal.framework.EquinoxEventPublisher.publishBundleEvent(EquinoxEventPublisher.java:112) [?:?]

	at org.eclipse.osgi.internal.framework.EquinoxContainerAdaptor.publishModuleEvent(EquinoxContainerAdaptor.java:156) [?:?]

	at org.eclipse.osgi.container.Module.publishEvent(Module.java:476) [?:?]

	at org.eclipse.osgi.container.Module.start(Module.java:467) [?:?]

	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1620) [?:?]

	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1600) [?:?]

	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.doContainerStartLevel(ModuleContainer.java:1571) [?:?]

	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1514) [?:?]

	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1) [?:?]

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

	at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340) [?:?]

Any ideas?
Thanks!
Jonathan

Remove all instances from addons dir and uninstall all instances from karaf console. Copy the jar again. If does not help restart openHAB. Practically can’t be binding related if previous version installed correctly - this one is basically the same except for the hub library.

I did all that, but it won’t install.

If I copy the first jar (2.3.0-SNAPSHOT) the installation runs through without problems, the Hub gets initialised correctly.
With the second jar (2.3.0-SNAPTSHOT2) I always get the error messages.

This is the full list of all appearing messages including the stack trace:
trace.txt.xml (153.3 KB)
(remove xml extension - only for upload limitation)

Thanks in advance.
Jonathan

@elektrolubach I am sorry, I have not checked because it was a rebuild and indeed it does not install. I simply rebuilt it again and checked that it installs this time, here is the version: https://www.dropbox.com/s/hrjeml7wy0tvgs3/org.openhab.binding.harmonyhub-2.3.0-SNAPSHOT-3.jar?dl=0
Sorry for the trouble.

Hi @ppieczul,
thanks again for the quick support with the new version.
First, the triggers are working great!

Only one thing could be better - in my opinion:
When powering off an activity there is only the trigger “PowerOff starting”.
The “PowerOff started” is not available if I get the code of the whistlingfish lib correctly?

I need a trigger of the Harmony Hub when the PowerOff procedure has ended to switch off a WLAN socket. A workaround - or maybe the better way - is to use the item state update trigger from “ActivityXYZ” to “PowerOff”!?

Some topics are still not working completely well:

  1. During installation, some other exceptions appeared in the log, see file trace2.txt.xml (40.7 KB)
  2. The auto discovery function for the Hub doesn’t work anymore - I had to manually add the hub; for the devices the discovery function works properly
  3. In the control window of the item “Current Activity” there was a selection list of all available activities until version 2.3.0-SNAPSHOT; in the current version 2.3.0-SNAPSHOT-3 there is only a text box with a checkmark at the end (I have to type the activity name)
    Also upon startup there is standing NULL as activity name

Maybe topic 2 and 3 are caused by topic 1?

Thanks!

Regards
Jonathan

@elektrolubach it will probably be solved when you use the JAR with a more recent openHAB 2.3.0 snapshot build.

See: Unit-Support, KNX 2, Karaf 4.1.5 Upgrade and more!

I have the latest snapshot build from apt and it installs every time and no issues 1-3.

A good catch on not passing power off activity finished trigger. I fixed this in here: https://www.dropbox.com/s/172l4ykgk3t09p1/org.openhab.binding.harmonyhub-2.3.0-SNAPSHOT-4.jar?dl=0

Please test for some time and let me know if it works now every time.

Thanks!
Pawel

@elektrolubach My changes to the whistlingfish library got merged. I am waiting for your feedback before submitting PR to openHAB. Thanks!

1 Like

@ppieczul, thanks for the last update (4). I have tested this solution since the last 8 days and it works perfectly.
The power off-started trigger is also worth it.

From my side, you can submit the PR to openHAB.

Thanks!
Jonathan

Thanks, submitted PR https://github.com/openhab/openhab2-addons/pull/3496

Sorry for the very newbie question, how I can updated the harmony binding version?
I would like to try the new fixed version as well.
Thank you

You need to upgrade to the most recent openHAB snapshot version or wait for the next stable release.

Ok, I was wrongly assuming that is possible to uninstall the binding plugin coming with the official version and just manually install the new plugin.
If this is not the case, I will wait for the new official version in order to not impact all the other configured items and plugins.
Thank you!

There is a way to do that but it is a workaround and not recommended because it may not work. Here is an example for the astro binding:

Hi @Giuseppe_Capodanno ,

I did it exactly this way. With some exceptions (see thread history above, my posts), it worked well and I was able to test it.

You have to download the current snapshot jar of this harmony binding. You can find the links here in the thread history (for example the latest, posted by @ppieczul here Harmony Binding 2.3.0 Snapshot-4).

Then copy this jar file into the config folder “addons” of your openHAB runtime.
IMPORTANT: Be sure to uninstall any other versions of the harmony binding (e.g. via paper UI).

Jonathan

Thank you Jonathan. I will get a try!