1
votes

I would like to get a self-contained JAR file. I mean I want to have a JAR file with all its dependencies, similar to a fat JAR.

And, I want to build this "fat JAR" file like OSGi bundle. Because, I want to manage all dependencies, for example, to avoid problems with differents version of a dependency running at the same time, to manage transitive dependencies between several OSGi bundles, etc.

My target is deploy self-contained OSGi bundles in a server with Apache Felix support.

Is it possible to get something like this? Which technologies I need (maven plugins maybe)?

I do not want to build a zip package with all dependencies and use something like Jenkins to deploy.

2
Maybe I misunderstand a think but sounds like you would like to contradict the concept of OSGi and it's dependencies during runtime etc. Also If you have problems with different versions that's sounds there is a problem defining the correct versions which are required etc. Also this violates the idea of the exported package/required packages in OSGi ? - khmarbaise
If I correctly remember there is a thing called product in OSGi ...help.eclipse.org/kepler/… ? - khmarbaise

2 Answers

1
votes

You can run a nested framework and install all your bundles in this framework. However, this is non trivial since you likely want to share classes with the parent framework.

Can be done but you better hire an expert ...

Any reason why you want to do this?