Okay, somehow I never noticed the ds.loglevel property, I set it to
debug and now get this:
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Dependency not satisfied:
gpioMasterPortA
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Dependency not satisfied:
gpioMasterPortB
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Dependency not satisfied:
gpioMasterPortC
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Not all dependencies
satisified, cannot activate
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Dependency Manager:
Service gpioMasterPortC registered, activate component
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Dependency not satisfied:
gpioMasterPortA
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Dependency not satisfied:
gpioMasterPortB
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Not all dependencies
satisified, cannot activate
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Dependency Manager:
Service gpioMasterPortB registered, activate component
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Dependency not satisfied:
gpioMasterPortA
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Not all dependencies
satisified, cannot activate
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Dependency Manager:
Service gpioMasterPortA registered, activate component
As you can see, GPIOImpl does get the needed dependencies:
gpioMasterPortA-C, so the component factory becomes satisfied, but later
GPIOImpl states ports B and C are not satisfied, why would it no longer
be satisfied?
INFO 20110811 17:00:24 ID#14 - [x.GPIOFactory] Dependency Manager:
Service factory registered, activate component
INFO 20110811 17:00:24 ID#14 - [x.PhysicalLinks] Dependency Manager:
Service gpioFactory registered, activate component
INFO 20110811 17:00:24 ID#7 - Creating PhysicalLink of type x.GPIO
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Dependency not satisfied:
gpioMasterPortB
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Dependency not satisfied:
gpioMasterPortC
INFO 20110811 17:00:24 ID#14 - [x.GPIOImpl] Not all dependencies
satisified, cannot activate
ERROR 20110811 17:00:24 ID#14 - [x.PhysicalLinks] The activate method
has thrown an exception
Caused by: org.apache.felix.log.LogException:
org.osgi.service.component.ComponentException: Failed activating
component
at
org.apache.felix.scr.impl.manager.ComponentFactoryImpl.newInstance(Compo
nentFactoryImpl.java:120)
Also, the output of the scr command shows that all master ports are
still satisfied.
David Humeniuk
-----Original Message-----
From: [email protected] [mailto:[email protected]]
Sent: Thursday, August 11, 2011 4:21 PM
To: [email protected]
Subject: Hard to debug component factory activation failures
When trying to create a new instance through a Declarative Services
component factory, the component may fail (throw a ComponentException).
When this happen in the Felix SCR, the exception is thrown only with the
message "Failed activating component". Is there a way to get more
information like a stack trace that explains why the component failed to
activate?
Thanks,
David Humeniuk
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]