geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Jencks <>
Subject Re: Why convert OSGi version when building an eba module ID?
Date Wed, 02 Mar 2011 17:59:11 GMT
I think the reasoning here is that we are putting the eba into a maven-style repository so
we need a maven-style version.

In principle, putting the eba into our repo is a mistake.  osgi doesn't need us to put bundles
in our repo, there shouldn't really be anything we need to do to put the eba in.  The problem
comes from any expectations we might have that deploying an eba should persist over an osgi
framework clean start.  I don't yet have any firm opinion on what to do about this.  I'm inclined
to think that we shouldn't try to second-guess osgi and that some ways of installing bundles
will be persistent and some ways won't be persistent and that is just fine.

There are also some reasons we put the eba into our repo based on current deployer code but
I suspect we can fix those soon.

david jencks

On Mar 2, 2011, at 8:28 AM, Forrest Xia wrote:

> The patch of jira 5427 is to convert maven-like version to OSGi-like version, while my
question is about why not using OSGi-like version directly in the module ID for a deployed
eba module?
> Forrest
> On Thu, Mar 3, 2011 at 12:14 AM, Shawn Jiang <> wrote:
> See for the background.
> On Wed, Mar 2, 2011 at 11:52 PM, Forrest Xia <> wrote:
> Hi,
> Anyone could explain to me why need this piece of code? why not directly use OSGi version
in the module ID?
> public class BundleUtil {
>    ...
>     public static String getVersion(org.osgi.framework.
> Version version) {
>         String str = version.getMajor() + "." + version.getMinor() + "." + version.getMicro();
>         String qualifier = version.getQualifier();
>         if (qualifier != null && qualifier.trim().length() > 0) {
>             str += "-" + version.getQualifier().trim();
>         }
>         return str;
>     }
> The piece of code convert OSGi version into traditional maven-like version, I want to
know why do this transformation.
> One of my concern is when I use geronimo-maven-plugin to deploy and undeploy an eba,
I need to manually specify the eba's Application-Version, then tell geronimo-maven-plugin
the exact module ID to undeploy it. But I want to use maven property replacement to describe
the module ID automatically. Can I do that? Please advise. thanks!
> Forrest
> -- 
> Shawn

View raw message