1 post Resolve tasks
Several of the tasks in Ivy are considered post-parsing tasks (post resolve task) and share common behavior and settings accordingly.
These tasks are:
* Retrieve
* Cachefileset
* CachePath
* Artifactproperty (since 2.0)
* Artifactreport (since 2.0)
All of these tasks will automatically trigger resolve if:
* No task with a Keep property set to true in the current build is invoked
* Combination and Module not set
From the ivy1.4 version, there are two ways to run resolve: Use Ivy files, or use inline mode. When you invoke resolve using the Ivy file, the default is to persist the parsed data for the subsequent parsing task. When you run the resolve of inline mode, the data is not persisted by default. You can override this behavior by setting the Keep property to the value you want.
If you want to reuse data that is obtained by calling Resolve in another build (or not the current one), you have to set the organization and module properties. This works only if the cache has not been cleaned up since your last resolve call. Under the inline call this does not work, inline must be completed in the same build.
2) Property
Most of the properties listed below are available only when Resove is automatically triggered.
Property |
Describe |
Necessary |
Conf |
Comma-delimited list of configurations for Retriev, or "*"
From 2.0 you can use ' * (public) ' or ' * (private) '. Note When inline is true ' * ' do ' * (Public ') understanding. |
No. The default is the setting used by the last resolve call, or the ' * ' when the call to resolve is not displayed |
Inline |
True use inline mode, false to parse Ivy file (from version 1.4) |
No, default is False |
Organisation |
The organization of the module to get. You typically do not need to set, because the default is the last resolved organization, in addition to the inline mode needs. |
In inline mode, the other is not the organization that defaults to the last parsed module. |
Module |
The name of the module to get. You typically do not need to set, because the default is the last resolved organization, in addition to the inline mode needs. |
In inline mode, the other is not, the default is the name of the last parsed module. |
Revision |
The version constraint for the module to get, which is only used in inline mode. Starting with the 1.4 version. |
No, default is Latest.integration |
Branch |
The branch of the module to be resolved in inline mode (starting from version 2.1) |
There are no branches by default in inline mode, regardless of standard mode. |
Transitive |
True recursive resolution dependencies, false not recursive, from 1.4 |
No, default is True |
Resolvemode |
Resolve mode used when automatic parsing is triggered (from version 2.1) |
No, the default is to use the Resolve mode set in the settings. |
Keep |
True to keep the results of the automatic resolve in memory, false to discard them. When is false, the standard Ivy properties won ' t being set and other postresolve-tasks (like retrieve and CachePath) won ' t is able to resuse the results of this resolve!
True to keep the result of automatic parsing in memory, false discards the result. When this is false, the standard Ivy properties are not set, and other postresolve-tasks (such as retrieve and CachePath) will not be able to reuse the results of this resolution! |
No, the inline mode defaults to false and the other defaults to True |
Haltonfailure |
True suspend build when Ivy fails, false continues |
No, default is True |
Validate |
True force ivy.xsd to validate the Ivy file, false to force no validation. |
No, default is Ivy default (configured in the middle of setup) |
Refresh |
True to force Ivy to parse the dynamic version during this parsing, false using the cached parsed version. From 2.1 onwards |
No, default is False |
File |
To parse the file, if the parsing is necessary, from 2.0 |
No, the default is the previously parsed Ivy file or the default is ${ivy.dep.file} |
Settingsref |
A reference to the Ivy settings, that must is used by this task (since 2.0)
Must be referenced by the Ivy settings used by this task. (from 2.0) |
No, use ' ivy.instance ' by default |
Resolveid |
The ID which was used to a previous resolve, or the Resolveid if a new resolve is performed (since 2.0)
Resolves the used ID before, or Resolveid if a new parse is performed (from 2.0) |
No, the default is ' [Org]-[module] '. |
Log |
Log settings used during the parsing process (from 2.0)
The available options are:
Default
Default log settings, so the usual messages are output to the console
Download-only
Other than downloading messages, the usual messages are invalidated. All things are cached in parsing will not enter any messages.
Quiet
All messages are invalidated unless an error occurs, otherwise the entire parsing process remains quiet. |
No, defaults to ' default '. |
3) Example
<ivy:cachepath organisation="emma" module="emma" revision="2.0.4217" inline="true" conf="ant" pathid="emma.classpath"/>
<taskdef resource="emma_ant.properties" classpathref="emma.classpath" />
The Emma module, which is an 2.0.4217 version, constructs an ant path with the corresponding product and then uses this path to define the Emma task.