Hi all, I've got some questions about development lifecycle of OSGI components, and specifically maintaining and using package versioning correctly. All the rationale behind having package versioning is sound in my opinion, OSGI has the right abstraction. In my experience the hard part really is how this is realised through day to day development practices.
I architected the transition of our middleware product from a 'standard' Java application to an OSGI-architected one. The main driver for us was the class isolation that OSGI can provide - and this was most important for us not for our own components, but for classes that are defined by end users of the platform. The transition was on the whole very positive, our architecture is much more solid I think, and the build process went from a monolithic build to many individual components. Since time was tight we never introduced packaging versioning, and never have. We still rely on 'naïve' jar versioning, and manually manage package level issues as they arise. I suspect that many OSGI systems are the same. I'm attracted to having proper package versioning on our components, but frankly I can't work out how to integrate it into our development process. Put simply, if you have to maintain the package versioning manually, it's never going to work. Unless tools can automate the package versions (at least at the export side), I don't think the cost will ever outweigh the benefit. I feel that this points to the heart of the 'complexity' argument that detractors of OSGI make - while the model is sound, unless the model is inherent at every level of development and deployment then it cannot be adopted without introducing the need for 'expert' (in that it's not common) knowledge about OSGI into the development cycle. Anyway, I have some questions about package versioning which I hope can enlighten me and help me towards some kind of solution path. The Bnd tool is the canonical tool for managing package versions in the manifest. I'm interested to know - how does it work out imported package versions? Does it directly read the manifest of the bundles referenced by your bundle? What tools are there for maintaining your package versions? Is there a tool that I can use to detect API changes between two versions of a bundle? For such a tool to work, you need something to compare it to - so what's the standard for the 'last thing to compare to'? The last released version? The last built version? This part is crucial - it seems to me you need a build system that can go and find the last released version all by itself (maven style, although my impression is that that's a dirty word around here) and fail if your package versions have not been set correctly. Using the last released version makes sense to me since that's all that really matters - steps of interim changes are irrelevant. I am aware of the bndtools project - and this shows some real promise as an alternate, lightweight set of tools for managing bundle development. I haven't found it useful yet, it's still under development and I'm not sure that our workflow fits into its model, but I check on it all the time for progress. More docs would be great. Thanks in advance Lindsay
_______________________________________________ OSGi Developer Mail List [email protected] https://mail.osgi.org/mailman/listinfo/osgi-dev
