...
- Currently, the
<major>.<minor>.<revision>
component of a
version must be numeric; if non-numeric characters are used to
annotate this (e.g.3.1.0myvendor-01
), the whole string is viewed
as a qualifier.
{{Wiki Markup <qualifier>
}} and {{<build>
}} are exclusive. Hence one can't
specify {{\[3.1.0-myvendor-01
\]
}}.
<qualifier>
's main purpose is for pre-releases (i.e. alpha,
beta, rc). From a release timeline, the qualifier is lexographically
compared, with no qualifier having the greatest value. So 3.1.0-
alpha < 3.1.0-beta < 3.1.0-rc < 3.1.0-sp1 < 3.1.0. The desired
behavior would be that 3.1.0-sp1 > 3.1.0
...
- Alter groupId or artifactId to include the vendor's tag. An
artifactId of commons-logging becomes commons-logging-myvendor. This
has the effect of bubbling the version dependency up. - Restrict the Maven remote repository only to those which contain
artifacts built by a vendor. With this scheme no metadata about the
vendor is possible in the local repository. It's a very tenuous
dependency at best Exactly specify the vendor tag and release (e.g. {{\[3.1.0-myvendor-Wiki Markup
sp1\])}}. Effectively this treats the whole string as a qualifier
and does work for that specific library, but one loses all ordering
relationships. You can't specify {{\[3.1.0-myvendor-sp1,3.1.1)
}} with this with
this scheme.
For handling post release versions an alternative would be
...
No Format |
---|
<major>.<minor>.<revision>[:vendortag]([-<qualifier>]|[- <build>]) |
This tag if present in a version dependency would be the most binding.
Wiki Markup
A specification of {{\[3.1.0:myvendor-SNAPSHOT
\]
}} would require that
the snapshot used must have that 'myvendor' identifier.
In conjunction with this vendor qualifier tag, it may be acceptable
Wiki Markup
to use the {{\[-<build>
\]
}} to distinguish follow-on patch releases,
essentially correlating 'service packs' to a specific build number.
With the presence of a vendor qualifier, this allows the vendor to
define what each build number represents.
Putting this altogether, we can specify the version dependencies for
the examples as follows:
(exactly 3.1) = {{\ Wiki Markup [3.1
\]
}}
(3.1 built by us) = {{\[3.1:us
\]
}}
(3.1 built by us and sp2) = {{\[3.1:us-02
\]
}} (assuming sp2
correlates to build 2)
(3.1 built by us and at least sp2) = {{\[3.1:us-02,3.1.1:us)
}}