<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Hi all,<br>
<br>
I would like to write a Mojo for the "verify" goal which takes as
input a baseline, and compare output of the module build with a
baseline to tell whether the version of current module should be
bumped. So far the only criterion would simply be that for bundle
x.y.z, if baseline already contains x.y.z2 with z2 >= z, then
build would fail or warn to remind the developer to bump the
version.<br>
<br>
[ You'll notice there that this is not the process used by Eclipse
platform, as it implies that versions should be bumped
systematically whereas Platform build tends to re-use artifacts as
much as possible. So the use-case mentioned about is not a baseline
replacement, but more a version conformance taking baseline as
reference ]<br>
<br>
This "ValidateVersionAgainstBaselineMojo" would simply need to
execute a query against the baseline repositories. However, it's not
very trivial to implement such p2 related task with Tycho as such
actions have to be turned into services. So far, I've found that the
service which seems the closest from the ability to make queries
against a p2 repo is the BaselineService. However, it is too limited
as it only checks bundles that match exactly (x.y.z.qualifier
equal), whereas I'd like basically to put some version range. Is
there currently a way to ask for a bundle of given version range
from a Mojo or should I propose a patch that adds such a method to
the BaselineService? The method would look like<br>
<pre>public Collection<IP2Artifact> getBundles(Collection<MavenRepositoryLocation> baselineLocations, String bundleId, VersionRange range);
</pre>
Does this use-case make sense to you? Is there any chance that if I
write such a method, it gets integrated in Tycho so I can go ahead
and write a Mojo?<br>
When I'm done with this very simple Mojo, I'd like to go a step
forward and implement another Mojo that gives hints about semantic
versioning, as BND does
<a class="moz-txt-link-freetext" href="http://blog.osgi.org/2013/09/baselining-semantic-versioning-made-easy.html">http://blog.osgi.org/2013/09/baselining-semantic-versioning-made-easy.html</a>
, reusing recent BND improvements and API.<br>
<br>
Cheers,<br>
-- <br>
<div class="moz-signature">Mickael Istria<br>
Eclipse developer at <a href="http://www.jboss.org/tools">JBoss,
by Red Hat</a><br>
<a href="http://mickaelistria.wordpress.com">My blog</a> - <a
href="http://twitter.com/mickaelistria">My Tweets</a></div>
</body>
</html>