Glenn Buckholz created IVY-1543:
-----------------------------------
Summary: Allow artifact resolution with branches to fall through
to a branchless release repo during ivy:resolve
Key: IVY-1543
URL: https://issues.apache.org/jira/browse/IVY-1543
Project: Ivy
Issue Type: Improvement
Components: Ant
Affects Versions: unspecified
Reporter: Glenn Buckholz
Priority: Minor
Fix For: 2.4.0-RC1
Currently we use feature branches. Our java project is about 40 modules. Each
module is an ivy artifact. An artifact is either just a jar file OR a jar file
and a tar file OR two jar files and a zip file.
We use ivy branches that map to our svn branches. This way one feature can keep
the binary dependencies within the branch. I've set up a chain resolver that
looks for artifacts in three repositories, a local snapshot repo, an
integration repo, and a release candidate repo. When I use the
latest.integration keyword I search all three repos and pull down the highest
version artifact of all the artifacts are jar files with a default name
pattern. In order to organize the snapshot and integration repo's I use a
branch. However, a branch does not make sense in the context of a release or
release candidate repo, these artifacts are ready for general consumption. If I
have an artifact that has files that do not conform to the default naming
convention OR are not jar files the chain resolver will not download them from
the release candidate or release repos if a branch is specified. If a released
a artifact is greater in version than the one on my branch I would like to get
that one instead.
For released higher versioned artifacts I would like to be able to ignore the
branch so they resolve by either setting a parameter OR having ivy know that
branch isn't a deciding factor on how to resolve when I specify the ivy or
artifact pattern for the ibiblo repo or url repo type without the branch
variable.
Example:
<url name="chain2-releases" m2compatible="true" >
<ivy
pattern="${nexus-releases}/[organisation]/[module]/[revision]/ivy-[revision].xml"
/>
<artifact
pattern="${nexus-releases}/[organisation]/[module]/[revision]/[artifact]-[revision].[ext]"
/>
</url>
should resolve an artifact of higher version in:
<ivy:resolve>
<dependency org="my.org" name="MODULE1"
rev="latest.integration" branch="${branch.name}" conf="default" />
<dependency org="my.org" name="MODULE2"
rev="latest.integration" branch="${branch.name}" conf="default" />
</ivy:resolve>
<ivy:retrieve conf="default"
pattern="${lib}/[artifact](-[classifier]).[ext]" />
EVEN IF branch.name is specified and the artifact in chain2-releases had no
branch in the metadata.
Stated another way:
In a chain resolver given repositories that are branch and non branch aware, I
would like ivy to resolve to the highest version number across all repos even
if it is not in the branch.
If ivy handled this it would make our build/integration scripts much less
complex.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)