Fix bug importing wikis and multiple shards
What does this MR do?
Groups have the associated object GroupWikiRepository
that stores information about the repository storage (shard). When we're importing a group wiki, we're not creating that object and, therefore, not tracking the selected repositorage storage (inside the @repository
object).
This can lead to transient errors because the repository can be imported in one repository shard, but later, since we're not tracking which one, when we access the wiki page, the GroupWikiRepository
object is created outside of that operation and the shard picked can be different.
This is the same we do for snippets.
There is not need for a Changelong because the feature is still behind a feature flag and it was introduced in %13.9.
Does this MR meet the acceptance criteria?
Conformity
-
Code review guidelines -
Merge request performance guidelines -
Style guides -
Separation of EE specific content
Related to #207886 (closed)
Edited by Francisco Javier López (ex-Gitlab)