Assign a repository storage tag to projects

Problem to solve

GitLab has different Gitaly machine configurations and shards for different purposes. These are currently documented outside of Gitaly and SRE's need to be aware of them before doing certain operations. GitLab should help manage this automatically

Proposal

Each project should support being assigned one repository storage tag using:

  • the GitLab API
  • the Administrator interface

The interface and API should only allow storage tags that are available from the currently attached storage. For a fresh GitLab instance with default storage, this means that there are no storage tags.

New projects will have no storage tag set by default. This means when choosing a shard to put the new repo on, shards with a storage tag like marquee or icebox should be excluded even if they have a non zero weight configured #39111 (closed).

In the future we might need multiple, but for the first iteration one will be enough. The purpose of the storage tag will be to ensure that when repositories are moved from shard to shard, the target shard has a matching tag.

For example, projects with a marquee tag can only live on a shard with the marquee. This will prevent it being moved to one of the shards for stale or archived projects.

Links / references

Edited Apr 30, 2020 by James Ramsay (ex-GitLab)
Assignee Loading
Time tracking Loading