no error message but kura does not construct/initialise component [message #1708103] |
Sun, 13 September 2015 10:06 |
paul stanton Messages: 87 Registered: July 2009 |
Member |
|
|
Hi all,
I came across this last week when I accidentally named a method 'acitvate' which was supposed to never be called. It was a place-holder for what I would later put in an 'activate' method however at the time I was assuming it was ok to have an un-published/referenced method named 'activate'.
Problem was that it was 'default' access, not protected/public. although my Component.xml had no reference to the 'activate' method this didn't matter (i later learned that kura tries to call activate even if the xml does not specify an activate method).
The component never loaded, and no error messages appear in the logs. I finally realised my mistake when I removed the method and everything worked again.
I am now part way through solving what I guess is a similar issue (a component not starting up) and again there is no message in the logs to help me. Of three components, only 2 start up.
Why does kura fail without any logging when a component is explicitly specified via manifest.mf?
Is there any way to debug why the component is not loading?
thanks. p.
[Updated on: Sun, 13 September 2015 10:07] Report message to a moderator
|
|
|
Re: no error message but kura does not construct/initialise component [message #1708104 is a reply to message #1708103] |
Sun, 13 September 2015 10:43 |
|
Hi Paul,
As far as I understood, your OSGi service component is not getting registered. I believe it's due to some malconfiguration in the Component Definition. I confronted the same issue. I would suggest you to start OSGi console and run ls to list all the registered service components. Check if your component is listed there.
1. If it is listed, check its status. It would be either ACTIVE or Unsatisfied. If it's active then your component is working fine and if not then try to execute COMP <component id> to see more details regarding that component.
2. If your component is not listed then try to restart the bundle manually using STOP and START command. You will encounter BundleException with the configuration related issue.
I hope it helps.
Thanks and Regards,
Amit Kumar Mondal
Email: admin@amitinside.com
Skype: arsenalnerk Blog: blog.amitinside.com
[Updated on: Sun, 13 September 2015 10:44] Report message to a moderator
|
|
|
|
|
|
Re: no error message but kura does not construct/initialise component [message #1709781 is a reply to message #1709649] |
Thu, 01 October 2015 05:06 |
|
Hi Paul,
So far I checked several OSGi toolings (Eclipse PDE, bndtools) and they do show you any error in Component Descriptor File (xml file) if you have created an erroneous service component but none of them will show any error regarding the Service Component Java File like if any public default constructor is missing, bind or unbind methods are missing etc. Maven Felix Plugin, on the other hand, does track all these errors and warnings.
Thanks and Regards,
Amit Kumar Mondal
Email: admin@amitinside.com
Skype: arsenalnerk Blog: blog.amitinside.com
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03422 seconds