A simple library bundle would likely just export the packages it wishes to share.

Not all bundles need to provide services. Services decouple bundles from implementation details, enabling multiple providers and dynamism.

Package sharing is another valid form of bundle collaboration, it is just a little less flexible. That doesn't mean it should be avoided completely, nor can it.

Now if you thought you might have multiple implementations of these utilities that you wanted to swap out dynamically, then defining services might make sense. But even at the package level you can have multiple implementations, it only means that swapping out implementations is slightly more traumatic on your system.

-> richard

On 11/30/10 6:51 PM, Wesley Silva wrote:
Hi,

I'm currently migrating an existing web application to OSGI. During the process I saw the utility package, where there are classes to manipulate things like date, strings, files, cryptography and so on. Almost all web applications in my company have this kind of package so I was wondering if it was a good idea to turn it into a reused piece of software. So here is my question, is it a good idea to turn it into a bundle? If so, how would this bundle look like? Would it publish some service thought interfaces or just export packages? Any suggestions?

--
Att,
Wesley
MSc Candidate in Software Engineering
Specialist in Test Analisys (CIn/UFPE - Motorola)
B.S. in Computer science - UFS
Sun Certified Java Programmer
Sun Certified Web Component Developer


_______________________________________________
OSGi Developer Mail List
osgi-dev@mail.osgi.org
https://mail.osgi.org/mailman/listinfo/osgi-dev
_______________________________________________
OSGi Developer Mail List
osgi-dev@mail.osgi.org
https://mail.osgi.org/mailman/listinfo/osgi-dev

Reply via email to