Summary
Retrieves the most recent artifact version, including its dependents, from an artifact repository.
This API wraps the retrieve function in the ElectricCommander::ArtifactManagement
Perl module and hides some additional functionality implemented in that module.
You must specify search criteria options to locate the artifact versions you want to retrieve.
artifactKeyStringoptionalUser-specified identifier for this artifact. This field is limited to alphanumeric characters, spaces, underscores, hyphens, and periods. artifactNameStringoptionalThe name of the artifact. artifactVersionNameStringoptionalThe name of the artifact version. cacheDirectoryStringoptionalThe directory where the artifact version is stored. The artifact version files are stored in a subdirectory under this cache directory. filtersArrayoptionalA list of zero or more filter criteria definitions used to define objects to find. Each element of the filter list is a hash reference containing one filter criterion. You may specify several filter criteria, in which case an object must meet all filter criteria to be included in the result. There are two types of filters:
groupIdStringoptionalA user-generated group name for this artifact. This field may consist of alphanumeric characters, spaces, underscores, hyphens, and periods. includeDependentsBooleanoptionalThe default is
overwriteStringoptionalOptions are:
repositoryNamesStringoptionalA space-separated list of artifact repository names. Retrieval is attempted from each specified repository in a specified order until it succeeds or all specified repositories have rejected the retrieval. If not specified, and if this request is made in a job step context, a preferred list of repository names is obtained from the Resource definition in the server. If that list is empty, the global repository list is used. retryNumberIntegeroptionalNumber of retry attempts for the operation. The default is 1. The time between retry attempts is 20 seconds. toDirectoryStringoptionalUsed to retrieve an artifact version to a specific directory without imposing the structure of a cache directory. Specify the full path to the new directory.
If the artifact version is in a local cache directory. it will be copied out of the cache.
If the artifact version is not in a cache directory, it will be downloaded directly to the specified directory, without putting it into a cache. versionRangeStringoptionalThe range of versions to search.
Version range syntax is standard number interval notation. |
Usage
Perl
$cmdr->retrieveArtifactVersions( # optionals );
ectool
ectool retrieveArtifactVersions \ # optionals
Examples
Perl
# Retrieve the most current core:infra artifact version whose version is 1.x.x. $cmdr->retrieveArtifactVersions({groupId => "core", artifactKey => "infra", versionRange => "[1.0,2.0)"}); # Or alternatively... $cmdr->retrieveArtifactVersions({artifactName => "core:infra", versionRange => "[1.0,2.0)"});