Debug with breakpoints works ok for me, I run karaf with the debug
option and attach the same I would a tomcat app. I will say that
somewhere I lost something because even though the ide stops at the
correct line of the breakpoint and I can see the variables I am
watching. The libraries included from the ide don't match with what is
loaded because I do not get the green line and step into and over don't
work. I also can debug with paxexam but I think OSGI is definitely much
harder than many other technologies. I don't have a problem with this
though. I chose java even though it is much harder to pickup than
dynamic languages. I like type safe languages because even though there
is more work involved in specifying the rules and it is slower to get
started. Cleanly specifying the rules allows for better tool support and
is priceless once a project gets large. I feel the same way about OSGI.
It is more work upfront but once you really know what you are doing it
saves a lot of work in the long run. It would be great if things were
easier at no expense but that is not what drew me to karaf. Also you
will be competing against many commercial entities for users who are
looking for easy enterprise and distributed computing (Typesafe, Spring
...) so I am not sure that is the way to get more people involved. I
think concentrating on the type of person who is willing to take the
time to learn and configure their project so they have an optimal
solution for the long term would probably pull in more people. 

On 2015-09-12 15:31, Pedro Domingues wrote: 

> Hi,
> 
> I really need to debug my code by the use of breakpoints, however this seems 
> a complex undertaking with an OSGi container.
> 
> I have Eclipse and Felix (both the latest). My project is a raw OSGi project, 
> I am not using PDE, just maven bundle plugin to generate the bundles and then 
> copy them to the /bundle folder in felix, then I perform java -jar 
> bin/felix.jar and the project runs. So no fuss here.
> 
> However I cannot debug the application that way. I've tried to read the docs 
> (http://felix.apache.org/documentation/development/integrating-felix-with-eclipse.html
>  [1]) but they are outdated/broken and cant make them work...
> 
> How can I debug this? Will I have to avoid using OSGi just because debug is 
> not supported...? :(
> 
> Thanks!
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@felix.apache.org
> For additional commands, e-mail: users-h...@felix.apache.org
 

Links:
------
[1]
http://felix.apache.org/documentation/development/integrating-felix-with-eclipse.html

Reply via email to