Hi, On 3/19/07, Peter Kriens <[EMAIL PROTECTED]> wrote:
Do I have to list the dangers of util bundles in this forum? It is easy to make a jar that drags in a lot of unwanted components. It is always so painful to install a jar just to find out it needs the util bundle that needs ...
Quite true. My idea of such a util bundle is to provide very low level functionality and hence get a bundle with no - if possible - dependencies except Core Java classes and OSGi classes. And having depdencies is just another problem we are faced anyway when using third party libraries: we always have to resolve dependencies. At least with bundle manifests explicitly stating these dependencies and OBR supporting the resolution of those, we have come a long way ... Just my 2 cents. Of course many of the problems are alleviated if the code is included
in the target JAR and not imported.
True. If we include the classes by using tools such as the great BND this is ok, still it might create duplicate class instances, which might or might not be a problem with respect to memory consumption and performance. I personally like to share as much as possible (but to create as minimal dependencies as possible, of course). Regards Felix