File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Other Application Frameworks and the fly likes OSGI its own container? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Other Application Frameworks
Bookmark "OSGI its own container?" Watch "OSGI its own container?" New topic
Author

OSGI its own container?

Don Scott
Greenhorn

Joined: Mar 10, 2009
Posts: 8
OSGI runs in its own container correct? What are the performance impacts of running this container inside of an existing container such as a web or ejb container? For example, if you profile the class running on the jvm-how small is the footprint?
Augusto Sellhorn
Ranch Hand

Joined: May 24, 2007
Posts: 57
Don Scott wrote:OSGI runs in its own container correct? What are the performance impacts of running this container inside of an existing container such as a web or ejb container? For example, if you profile the class running on the jvm-how small is the footprint?


I've done this the other way around. You can run an OSGi container and have a web container bundle (like jetty) and run your web apps inside. For EJB component it is more complicated, I don't think it would be trivial to try to bolt a whole OSGi runtime inside of JBoss (in those cases I've used Spring inside). However, a lot of the app servers are being implemented via an OSGi runtime so this is more of a possibility.
Karl Pauls
author
Greenhorn

Joined: Feb 14, 2011
Posts: 4
Running a OSGi framework inside other containers is doable (but as others have noted some are easier than others - eg. servlets easy, ejb tricky). The footprint of for example Apache Felix is about 500K (both on disk as well as in memory) so typically no problem for a server side application.


As mentioned already, more and more, there are possibilities to use OSGi out-of-the-box inside JEE containers (JOnAS has very good support but, Glassfish, JBoss, and Websphere make it possible one way or the other by now as well).
Don Scott
Greenhorn

Joined: Mar 10, 2009
Posts: 8
Thanks for the replies! OSGI is still really new to me, so I wasn't even familiar with the idea about the OSGI container holding the web container. I haven't ever looked at JOnAS-but will have to research it.

Thanks!
 
 
subject: OSGI its own container?