Search code examples
mavenjenkinsartifactory

adding metadata to artifactory


The problem: I need to be able to use artifacts/versions that passed specific version CI of 3 different project. For instance project A version x.y.z passed the pipeline with B version x2.y2.z2 and when building C I need to be able to get the artifact of A and B that passed a specific versions. Therefore I was thinking of pushing additional metadata to the stored artifact in artifactory and when building C to query the artifactory with the data. How can I add custom data to artifact stored in artifactory as per the CI pipeline with Jenkins


Solution

  • You can use Artifactory's REST api or the JFrog CLI to easily set properties on an Artifact or an entire Folder.

    You can then query Items/Artifacts based on the properties using REST

    or CLI using a spec file

    for more advanced querying capabilities you can use Artifactory's AQL