Backend: Update tagName to `name` and tagPath to `path` on VersionType
Summary
In !136081 (merged) we decided that Version#name
would be the SSoT identifier for a Version instead of Version#tag
. With this change, the terms tagPath
and tagName
in the GraphQl type Types::Ci::Catalog::Resources::VersionType
no longer align with this implementation of Version. In order to maintain consistency, we should update the field names.
Further context:
-
@fabiopitino
started a discussion: (+3 comments)To answer to the
name
vstag
naming, today we are using repository tags and relative releases to identify a resource version. Theresource version
is an abstract concept that indicates "the version of a resource in the catalog". Today we have components that are based on revisions in a repository but in the future we could have other types of components such as container images, packages, etc. Each of these component types may have a different representation of version (container tags, package version, etc.).The use of
release.tag
is a particular implementation ofresource version
. For this I was suggesting to useVersionType#name
to be more agnostic of the specific implementation.@lma-git
: Thank you for re-clarifying. Understood. I have replaced Version#tag with Version#name so that #name is the SSoT. Perhaps then we should have a follow up issue to rename the fieldstagName
andtagPath
in VersionType to bename
andpath
.
Proposal
In Types::Ci::Catalog::Resources::VersionType
, update:
-
tagName
=>name
-
tagPath
=>path
This effort will require coordination with FE.
Steps:
- Add
name
andpath
to VersionType, and deprecatetagName
andtagPath
. - Unblock the FE counterpart issue #432107 (closed). Wait for FE to merge and deploy the change.
- Remove
tagName
andtagPath
from VersionType.