Skip to content

Add 'praefect metadata' subcommand

Sami Hiltunen requested to merge smh-generalize-dataloss into master

Praefect doesn't yet have any way of fetching a repository's metadata. With the addition of replica path, this is becoming increasingly important as users may need to figure out where on the disk a given repository is stored. They may also want to figure out which repository on the disk a replica actually belongs to. Likewise, it's currently not possible to really see which Gitaly node is acting as a primary of a repository. The dataloss subcommand does provide some of this information but it only returns information when a repository is not fully replicated. To address this gap, this MR adds 'praefect metadata' subcommand that can be used to fetch a repository's metadata. Users can fetch the metadata either by the repository's ID or by its virtual storage and relative path to accommodate all possible queries.

Closes #3481 (closed)
Related to #3485 (closed) as Gitaly tests that access the repository directly via the filesystem need to ask Praefect for the repository's location.
Documentation: gitlab!75260 (merged)

Edited by Sami Hiltunen

Merge request reports