Add 3-segment format for gl_repository
What does this MR do?
Implements #215315 (closed), a new gl_repository
format:
[repository holder class]-[repository holder id]-[repository type]
, where:
- repository holder class would be the active record class name (e.g. "project")
- repository holder id would be the active record id (e.g. 7)
- repository type indicates it being
code
,wiki
ordesign
.
So project 7's wiki could be represented as project-7-wiki
.
Backward compatibility is implemented so the old 2-segment format would still work.
The IdentifierParser
is extracted as its own object, because I find we repeatedly do split
at different places, and wrapping this as object helps caching this result.
Does this MR meet the acceptance criteria?
Conformity
- [-] Changelog entry
-
Documentation (if required) -
Code review guidelines -
Merge request performance guidelines -
Style guides -
Database guides -
Separation of EE specific content
Availability and Testing
-
Review and add/update tests for this feature/bug. Consider all test levels. See the Test Planning Process.
Edited by 🤖 GitLab Bot 🤖