Added: ant/ivy/site/target/history/2.2.0/ivyfile/configurations.html URL: http://svn.apache.org/viewvc/ant/ivy/site/target/history/2.2.0/ivyfile/configurations.html?rev=1005260&view=auto ============================================================================== --- ant/ivy/site/target/history/2.2.0/ivyfile/configurations.html (added) +++ ant/ivy/site/target/history/2.2.0/ivyfile/configurations.html Wed Oct 6 21:25:29 2010 @@ -0,0 +1,178 @@ + + + + + + + + +configurations | Apache Ivy + + + + + + + + + + +
+ + + + + + + + + + + + + +
+ +
+ +
+ + + + +
+ + +
+ + +
+ + + + + + + +
+
+ +

configurations

+
Tag: configurations Parent: ivy-module

A container for configuration elements. If this container is not present, it is assumed that the module has one public configuration called 'default'.

since 2.2 You can define the default conf on this container by specifying the defaultconf attribute. This attribute defines the conf mapping to use when no conf mapping is specified for a dependency in this ivy file.

since 1.3 You can define a default conf mapping on this container by specifying the defaultconfmapping attribute.

This attribute modifies the way ivy interprets conf mapping with no mapped conf. In this case, Ivy will look in the default conf mapping and use the conf mapping d efined in the default conf mapping for the conf for which there is no mapped conf.

In order to maintain backwards compatibility with Ivy 2.1.0 and earlier, the defaultconfmapping also provides one additional function. If no defaultconf is specified (on either the configurations tag or the dependencies tag), the defaultconfmapping becomes the default configuration for dependencies in this ivy file when no configuration is specified. In other words, in addition to altering the interpretation of individual configurations with no mapping, defaultconfmapping also performs exactly like defaultconf in the absence of a definition for defaultconf.

If several defaultconfmapping or defaultconf attributes are defined (in the configurations tag, one or several in an included configurations file, and/or in the dependency tag, then it's only the last definition of each property which is taken into accou nt. The others will have no effect at all.

See examples below to clarify the behavior of these two attributes together.

since 1.4 You can activate a confmappingoverride mode for all configurations, in which case the extending configurations will override the mappings of the configurations they extend from.


Attributes

+ + + + + + + + + + + +
AttributeDescriptionRequired
defaultconfthe default conf to use in this ivy file since 2.2No, defaults to no default conf
defaultconfmappingthe default conf mapping to use in this ivy file since 1.3No, defaults to no default conf mapping
confmappingoverridetrue to activate configuration mapping override, false otherwise since 1.4No, defaults to false
+

Child elements

+ + + + + + + + + + +
ElementDescriptionCardinality
confdeclares a configuration of this module0..n
includeinclude configurations from another file0..n
+ +

Configuration mappings details

+When Ivy parses your Ivy file, it will create (internally) modify the configuration mapping of your dependencies.
For instance, say you have: +
+<configurations defaultconfmapping="conf1->other1;conf2->other2">
<conf name="conf1" />
<conf name="conf2" extends="conf1" />
</configurations>
<dependencies>
<dependency name="other-module" conf="conf1" />
</dependencies> +
+When Ivy parses this file, it will construct the following dependency (in-memory only): +
<dependency name="other-module" conf="conf1->other1" />
+ +So, if you now resolve the conf2 configuration, you will only get the other1 dependencies of your other-module.

But when you set confmappingoverride to true, Ivy will construct the following dependency in memory: +
<dependency name="other-module" conf="conf1->other1;conf2->other2" />
+As you can see, the defaultmappings of the extending configurations are also added (although you didn't explicitly defined them)

When you now resolve the conf2 configuration, you'll get the other2 dependencies of your other-module.

Examples involving defaultconf and defaultconfmapping

+The table below indicates how Ivy interprets the conf attribute according to how defaultconfmapping and defaultconf are set: + + + + + + + + + + + + +
defaultconfdefaultconfmappingconfivy interpretation
*->*
runtime
runtime->runtime
test
test->test
runtime
runtime->runtime
runtime
runtime->*;test->default
runtime->*
runtime
runtime->*;test->default
testtest->default
runtime->*;test->default
runtime->*;test->default
runtime->*;test->default
runtime
runtime->*
runtime->*;test->default
test
test->default
+ +
+
+ + + + + + + + + + + + +
+ + Added: ant/ivy/site/target/history/2.2.0/ivyfile/conflict.html URL: http://svn.apache.org/viewvc/ant/ivy/site/target/history/2.2.0/ivyfile/conflict.html?rev=1005260&view=auto ============================================================================== --- ant/ivy/site/target/history/2.2.0/ivyfile/conflict.html (added) +++ ant/ivy/site/target/history/2.2.0/ivyfile/conflict.html Wed Oct 6 21:25:29 2010 @@ -0,0 +1,148 @@ + + + + + + + + +conflict | Apache Ivy + + + + + + + + + + +
+ + + + + + + + + + + + + +
+ +
+ +
+ + + + +
+ + +
+ + +
+ + + + + + + +
+
+ +

conflict

+
Tag: conflict Parent: dependencies
+
+(since 2.0) + +Specify a a conflict manager for one or several dependencies.
The way to specify a conflict manager is by giving indication to which dependencies the conflict manager applies (by giving organisation and module names or name regexp), and then specifying the conflict manager, either by giving its name or by specifying a fixed revision list, in which case a fixed conflicts manager is used.

The list of built-in conflict managers available is listed on the conflict manager configuration page.

Conflicts manager are used during the resolve operation, i.e. when ivy analyse the graph of dependencies and download corresponding ivy files and artifacts. The fact to manage conflict at resolve time enables to minimize downloads: when a module is evicted by a conflict manager, it is not downloaded.

There are two things optimized during conflict resolution: download of artifacts and download of ivy files. The first is always ensured by ivy, i.e. artifacts of a module evicted will never be downloaded. The second is not as simple to handle because to know what are the conflicts ivy needs to know the dependency graph, and to know the dependency graph, it has to download ivy files. But ivy is highly optimized on this too, and it tries to evict modules as soon as possible.
That's why the order of dependencies is important for download optimization. Indeed ivy traverses the dependency graph in the order in which dependencies are declared in the ivy files, and each time it encounters a dependency on a module, it first check if there is a conflict on this module, and if this is the case, it asks the conflict manager to resolve the conflict. Then if the module is evicted, it does not download its ivy file, and the whole branch is not traversed, which ca n saves a lot of time.

If no specific conflict manager is defined, a default conflict manager is used for all modules.

The current default conflict manager is the "latest-revision" conflict manager.

Attributes

+ + + + + + + + + + + + + + + +
AttributeDescriptionRequired
orgthe name, or an expression matching the name of organisation to which this conflict manager should apply (see matcher attribute below)No, defaults to * (match all)
modulethe name, or an expression matching the name of module to which this conflict manager should apply (see matcher attribute below)No, defaults to * (match all)
managerthe name of the conflict manager to useExactly one of two
reva comma separated list of revisions this conflict manager should select
matcherthe matcher to use to match the modules for which the conflict manager should be usedNo, defaults to exact
+ +
+
+ + + + + + + + + + + + +
+ + Added: ant/ivy/site/target/history/2.2.0/ivyfile/conflicts.html URL: http://svn.apache.org/viewvc/ant/ivy/site/target/history/2.2.0/ivyfile/conflicts.html?rev=1005260&view=auto ============================================================================== --- ant/ivy/site/target/history/2.2.0/ivyfile/conflicts.html (added) +++ ant/ivy/site/target/history/2.2.0/ivyfile/conflicts.html Wed Oct 6 21:25:29 2010 @@ -0,0 +1,149 @@ + + + + + + + + +conflicts | Apache Ivy + + + + + + + + + + +
+ + + + + + + + + + + + + +
+ +
+ +
+ + + + +
+ + +
+ + +
+ + + + + + + +
+
+ +

conflicts

+
Tag: conflicts Parent: ivy-module

+ +(since 2.0) the conflicts section is deprecated. Use the conflict instead.

Container for conflict manager elements, used to indicate how conflicts should be resolved
for this module.

+ +The list of built-in conflict managers available is listed on the conflict manager configuration page.

+ +Conflicts manager are used during the resolve operation, i.e. when ivy analyse the graph of dependencies
and download corresponding ivy files and artifacts. The fact to manage conflict at resolve time
enables to minimize downloads: when a module is evicted by a conflict manager, it is not downloaded.

+ +There are two things optimized during conflict resolution: download of artifacts and download
of ivy files. The first is always ensured by ivy, i.e. artifacts of a module evicted will never
be downloaded. The second is not as simple to handle because to know what are the conflicts
ivy needs to know the dependency graph, and to know the dependency graph, it has to download
ivy files. But ivy is highly optimized on this too, and it tries to evict modules as soon as possible.
+That's why the order of dependencies is important for download optimization. Indeed ivy
traverses the dependency graph in the order in which dependencies are declared in the ivy files,
and each time it encounters a dependency on a module, it first check if there is a conflict on this module,
and if this is the case, it asks the conflict manager to resolve the conflict. Then if the module is evicted,
it does not download its ivy file, and the whole branch is not traversed, which can saves
a lot of time.

+ +If this container is not present, a default conflict manager is used for all modules.
The current default conflict manager is the "latest-revision" conflict manager.

Child elements

+ + + + + + + + +
ElementDescriptionCardinality
managerdeclares a conflict manager for this module1..n
+ + +
+
+ + + + + + + + + + + + +
+ + Added: ant/ivy/site/target/history/2.2.0/ivyfile/dependencies.html URL: http://svn.apache.org/viewvc/ant/ivy/site/target/history/2.2.0/ivyfile/dependencies.html?rev=1005260&view=auto ============================================================================== --- ant/ivy/site/target/history/2.2.0/ivyfile/dependencies.html (added) +++ ant/ivy/site/target/history/2.2.0/ivyfile/dependencies.html Wed Oct 6 21:25:29 2010 @@ -0,0 +1,152 @@ + + + + + + + + +dependencies | Apache Ivy + + + + + + + + + + +
+ + + + + + + + + + + + + +
+ +
+ +
+ + + + +
+ + +
+ + +
+ + + + + + + +
+
+ +

dependencies

+
Tag: dependencies Parent: ivy-module

Container for dependency elements, used to describe the dependencies of this module.
If this container is not present, it is assumed that the module has no dependency at all.

This container provides for two similar behaviors. An overview is given here. (See configurations doc page for more details about these behaviors).

since 1.1
defaultconf
Defines the conf attribute to use when no conf is defined for a dependency in this ivy file. It is only used when no conf mapping is defined, and has no influence in other cases.

since 1.3
defaultconfmapping
Influen ces the way that a conf mapping with no mapped conf is interpreted.

In Ivy 2.1.0 and earlier, if both defaultconf and defaultconfmapping are defined, it's the defaultconfmapping that is used. Since Ivy 2.2.0, these attributes can be used together.

Attributes

+ + + + + + + + + + +
AttributeDescriptionRequired
defaultconfthe default configuration to use when none is specified in a dependency. since 1.1No, defaults to *->*
defaultconfmappingthe default configuration mapping to use in this ivy file. since 1.3No, defaults to no default conf mapping
+

Child elements

+ + + + + + + + + + +
ElementDescriptionCardinality
dependencydeclares a dependency for this module0..n
excludeexcludes artifacts, modules or whole organizations from the set of dependencies of this module since 2.00..n
+ + +
+
+ + + + + + + + + + + + +
+ +