This week's book giveaway is in the General Computing forum.
We're giving away four copies of Emmy in the Key of Code and have Aimee Lucido on-line!
See this thread for details.
Win a copy of Emmy in the Key of Code this week in the General Computing forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Junilu Lacar
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Knute Snortum
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Ron McLeod
  • Carey Brown
Bartenders:
  • Paweł Baczyński
  • Piet Souris
  • Vijitha Kumara

Modular Java: If you can answer "yes" to these 3 questions, then you should use OSGI

 
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't know anything more about OSGI than what I read in the Modular Java topics, so I'd like to find out which are these three questions(or less or more questions).
Thank you!

Alexandra N.
 
Ranch Hand
Posts: 1936
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can read benefits of using OSGi from http://www.osgi.org/About/WhyOSGi.
 
author
Posts: 396
8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Alexandra Niculai wrote:I don't know anything more about OSGI than what I read in the Modular Java topics, so I'd like to find out which are these three questions(or less or more questions).



I'm not sure if these could be considered the definitive set of questions or not, but let me give it a shot...

- If you want to develop applications that are assembled from highly-cohesive/loosely-coupled modules, then you should use OSGi.
- If you want to be able to maintain parts of an application without updating other parts (or even restarting the application), then you should use OSGi.
- If you want to build plugin capability into your application, then you should use OSGi.
- If you want to stay out of "Classpath Hell" (multiple dependencies on different versions of the same library), then you should use OSGi.
- If you want to increase productivity through parallel development of application components, then you should use OSGi.
- If you want to develop in a service-oriented architecture, but aren't so sure that SOA really has anything to do with web services, then you should use OSGi.

I may think of some more later, but this is a good start.

 
Alexandra Niculai
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks a lot! I can answer yes to some of these questions. I need to learn and use OSGI.
And thank you, too, Kengkaj.
 
Ranch Hand
Posts: 1325
Android Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Thanks for explanation.. Craig,

does this book cover initial learning of OSGI framework ?
I mean is this book is enough to understand.. OSGI framework.. ?

thanks
 
Craig Walls
author
Posts: 396
8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Muhammad Saifuddin wrote:does this book cover initial learning of OSGI framework ?
I mean is this book is enough to understand.. OSGI framework.. ?



Absolutely! The very first thing we do in the book is startup a couple of OSGi frameworks (Equinox and Felix) and kick the tires. Then we create a dumb simple Hello World bundle that does little more than...well, what do you think Hello World bundles would do? Then we ramp up a bit and create a couple of bundles, one that publishes a service into the OSGi service registry and another that consumes that service.

Up until this point in the book, we've done everything by hand. But before we go any further, I introduce you to Pax Construct...because I can't imagine doing any sizable OSGi project without Pax Construct.

Throughout the rest of the book we build a somewhat realistic OSGi example ("somewhat" meaning that it's big enough to demonstrate much of what you need to know about OSGi, but small enough to fit in the book). We even write some integration tests for those bundles.

At some point we abandon programmatic OSGi and start using Spring-DM to publish and consume services. Then we build a web front end for our application, use fragments to "skin" the app, and then we start packaging up the application to be deployed.

So, yes...we start off with some basic OSGi and quickly ramp up to building a full application.
 
Muhammad Saifuddin
Ranch Hand
Posts: 1325
Android Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for your reply.. Craig,
 
The harder you work, the luckier you get. This tiny ad brings luck - just not good luck or bad luck.
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!