Using the latest version?
JFrog Container Registry Guide
Dynamically Adding Properties to Artifacts on Deployment
You can add key-value matrix parameters to deploy (PUT) requests and those are automatically transformed to properties on the deployed artifact.
Since matrix parameters can be added on any part of the URL, not just at the end, you can add them to the target deployment base URL. At the time of deployment, the artifact path is added after the matrix parameters and the final deployed artifact will be assigned the defined properties.
You can even use dynamic properties, depending on our deployment framework.
Permissions to attach properties
You must have the 'Annotate' permission in order to add properties to deployed artifacts.
Controlling Artifact Resolution with Matrix Parameters Queries
Matrix parameters can also be used in artifact resolution, to control how artifacts are found and served.
There is currently support for two types of queries:
- Non-conflicting values
- Mandatory values.
Non-mandatory Properties
Resolved artifacts may either have no property with the key specified, or have the property with the key specified and the exact value specified (i.e. the artifact is resolved if it has a property with a non-conflicting value).
Non-mandatory properties are identified by a simple key=value
parameter.
For example:
Current Artifact Property | Matrix Parameter | Resolution Result |
---|---|---|
color=black | color=black | OK (200) |
None or height=50 | color=black | OK (200) |
color=red | color=black | NOT_FOUND (404) |
Mandatory Properties
Resolved artifacts must have a property with the key specified and the exact value specified.
Mandatory properties are identified with a plus sign (+) after the property key: key+=value
.
For example:
Current Artifact Property | Matrix Parameter | Resolution Result |
---|---|---|
color=black | color+=black | OK (200) |
None or height=50 | color+=black | NOT_FOUND (404) |
color=red | color+=black | NOT_FOUND (404) |
Multiple properties in queries
Multiple key-value matrix parameters are additive, forming an AND query between each key-value subsection.
Multi-valued Properties Support
All matrix parameters can support multiple values by separating values with a comma (,). For example:
colors=red,gold,green