Artifact

4 minute readExtensibilityDeveloper productivity

The CloudBees CD/RO EC-Artifact plugin provides an interface to the CloudBees CD/RO artifact repository for artifact version publish and retrieve operations.

For more information about the artifact repository refer Artifact management.

Plugin Version 1.1.10.2021080408

Revised on October 28, 2020

Integrated version

For all parameter descriptions in this document, required parameters are shown in bold italics.
In the CloudBees CD UI, go to the Home page, open the Main Menu, and click Admin > Plugins to open the Plugin Manager.

Plugin procedures

PublishArtifactVersion

Use the EC-Artifact plugin to create a step to publish a new artifact version.

Input

  1. In the Main Menu, click Admin > Plugins to open the Plugin Manager.

  2. Go to the PublishArtifactVersion procedure.

  3. Enter the following parameters:

ParameterDescription

Artifact

Artifact name, in the form <groupId>:<artifactKey>. If the artifact does not exist, it will be created if this procedure’s launching user or this project’s principal has the required permissions.

Version

A full version string takes the form: <major>.<minor>.<patch>-<qualifier>-<buildNumber>. The version specification must be unique across all of this artifact’s versions.

Repository

Name of the repository where this new artifact version will be published.

Enable Compression?

Check this box to compress the artifact version before it is stored in the repository.

Follow Symbolic Links?

Name of the cluster in which server is to be added.

From directory

Name of the directory in the job’s workspace that contains files that comprise the artifact version to be published. If not specified, the entire workspace is used.

Include Pattern(s)

List file include patterns one pattern per line, to limit which files are published. If no patterns are specified, all files are included.

Exclude Pattern(s)

List file exclude patterns one pattern per line, to limit which files are published. If no patterns are specified, no files are excluded.

Dependent Artifact Version(s)

List dependent artifact versions one per line, each in the form <groupId>:<artifactKey>:<versionRange>. All dependent artifact versions must exist for this artifact version to be retrievable. When this artifact version is successfully retrieved its dependent artifact versions are retrieved also.

Output

After the job runs, you can view the results on the Job Details page in CloudBees CD. The status of the page was checked successfully.

In the PublishArtifactVersion step, click the Log button to see the diagnostic information:

RetrieveArtifactVersion

Input

  1. In the Main Menu, click Admin > Plugins to open the Plugin Manager.

  2. Go to the RetrieveArtifactVersion procedure.

  3. Enter the following parameters:

ParameterDescription

Artifact

Artifact name, in the form <groupId>:<artifactKey>. If the artifact does not exist, it will be created if this procedure’s launching user or this project’s principal has the required permissions.

Version

Either latest, exact version or a version range of the artifact. Version is in the form: <major>.<minor>.<patch>-<qualifier>-<buildNumber>. The version specification must be unique across all of this artifact’s versions.

Retrieve to directory

Download the artifact version to a specific directory.

Retrieved Artifact Location Property

Name or property sheet path used by the step to create a property sheet. This property sheet stores information about the retrieved artifact version(s), including their location in the file system.

From directory

Name of the directory in the job’s workspace that contains files that comprise the artifact version to be published. If not specified, the entire workspace is used.

Filter(s)

Supply search filters one per line, to apply when querying the CloudBees CD database for the artifact version to retrieve.

Artifact retrieval dependency order explained

The order of dependencies registered for an artifact version are significant. Consider this scenario:

  • A depends on B (any version) and C [1.0, 2.0)

  • B depends on C (any version)

  • C versions 1.0, 2.0, and 3.0 exist

When retrieving A, the dependency algorithm evaluates B first. The algorithm finds that the max version of B depends on any version of C, so the algorithm looks for max version C and finds C 3.0. Because this chain is satisfied, the algorithm returns to A and evaluates its next dependency "C [1.0, 2.0)". This results in matching C 1.0. The returned artifacts are: A, B, C 1.0, and C 3.0. Consider if the A dependency is changed to:

  • A depends on C [1.0, 2.0), B (any version)

The algorithm will choose C 1.0 first. Then the algorithm evaluates B, determines that its "C (any version)" is satisfiable by the already chosen C 1.0. The returned artifacts are A, B, and C 1.0.

Note: In the version range syntax [] indicates inclusive, () indicates exclusive.

Output

After the job runs, you can view the results on the Job Details page in CloudBees CD. The status of the page was checked successfully.

In the RetrieveArtifactVersion step, click the Log button to see the diagnostic information:

SyncArtifactVersion

Input

  1. In the Main Menu, click Admin > Plugins to open the Plugin Manager.

  2. Go to the SyncArtifactVersion procedure.

  3. Enter the following parameters:

ParameterDescription

Artifact

Artifact name, in the form <groupId>:<artifactKey>. If the artifact does not exist, it will be created if this procedure’s launching user or this project’s principal has the required permissions.

Version

Either latest, exact version or a version range of the artifact. Version is in the form: <major>.<minor>.<patch>-<qualifier>-<buildNumber>. The version specification must be unique across all of this artifact’s versions.

Source Repository

Name of the repository from where this artifact version will be retrieved.

Target Repository

Name of the repository, where this artifact will be uploaded.

Overwrite?

If checked, artifacts on target repositories will be overwritten.

Upload in parallel?

If checked, artifacts will be uploaded to the target repo in parallel.

Output

After the job runs, you can view the results on the Job Details page in CloudBees CD. The status of the page was checked successfully.

In the SyncArtifactVersion step, click the Log button to see the diagnostic information:

Release notes

EC-Artifact 1.1.10

  • Fix Open Redirect Vulnerability and XSS, cookie stealing.

EC-Artifact 1.1.9

  • Convert help to ADoc format

EC-Artifact 1.1.8

  • Renaming to "CloudBees CD"

EC-Artifact 1.1.7

  • Renaming to "CloudBees"

EC-Artifact 1.1.6

  • Fixed dropdowns in Chrome.

EC-Artifact 1.1.5

  • Added metadata that is required for 9.0 release.

EC-Artifact 1.1.4

  • AIX agent support has been added.

EC-Artifact 1.1.3

  • SyncArtifactVersion procedure has been added.