ant-ivy-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Carlton Brown" <>
Subject RE: dynamic revision and determine the most recent
Date Wed, 21 Oct 2009 14:25:13 GMT
> -----Original Message-----
> From: corwin.yo []
> Sent: Wednesday, October 21, 2009 10:16 AM
> To:
> Subject: RE: dynamic revision and determine the most recent
> Thanks Douglass,
> I understand how its working. But in this case, what is the best
> practice ?

The best practice, apparently, is not to have the same revision found in
multiple repositories in a chain.   Ivy does not seem to handle this

If you really want to take this on, however, I have it working for a
trivial test case.   The key things to do are:
* Set checkmodified=true on the chain
* Set a latest-strategy of "latest-time" on the chain, and
"latest-revision" on the individual resolvers.   
* Set checkUpToDate=true on the <caches>
* Set the dependency revision to "latest.integration" which skips the
rev matching and devolves to the latest-strategy set on the resolver.

The latest-strategy of the chain is supposed to override those of the
child resolvers, but this only happens if the child resolver latest
strategies are set to a non-null value other than "default".    

Here's my working trivial configuration.  

<?xml version="1.0" encoding="UTF-8"?>
    <!-- properties in this section are defaults and can be overridden
from build scripts -->
	<property name="" value="${user.home}/ivy"
	<property name="ivy.caches.root"
	<property name="ivy.local.repo.root"
	<property name="" value="default"
	<property name="ivy.defaultcache.dir"
value="${ivy.caches.root}/${}" override="false"/>

	<property name="ivy.default.resolver" value="default-chain"
	<settings defaultResolver="${ivy.default.resolver}"
   <caches checkUpToDate="true"
		<filesystem name="mine" changingPattern=".*SNAPSHOT"
checkmodified="true" latest="latest-revision">
/ivy.xml" />
/[artifact](-[classifier]).[ext]" />				
		<filesystem name="theirs" changingPattern=".*SNAPSHOT"
checkmodified="true" latest="latest-revision">
vision]/ivy.xml" />
vision]/[artifact](-[classifier]).[ext]" />				
		<chain name="default-chain" changingPattern=".*SNAPSHOT"
checkmodified="true" latest="latest-time">
			<resolver ref="mine"/>
			<resolver ref="theirs"/>


* I haven't been able to get this working in the more complicated
production config
* There may be some unnecessary settings in here because I've ended up
throwing the whole kitchen sink at this problem and I'm almost ready to
give up.

This message and any attachment are confidential and may be
privileged or otherwise protected from disclosure and solely for
the use of the person(s) or entity to whom it is intended. If you
have received this message in error and are not the intended
recipient, please notify the sender immediately and delete this
message and any attachment from your system. If you are not the
intended recipient, be advised that any use of this message is
prohibited and may be unlawful, and you must not copy this
message or attachment or disclose the contents to any other person.

View raw message