Skip to content
GitLab
Next
    • GitLab: the DevOps platform
    • Explore GitLab
    • Install GitLab
    • How GitLab compares
    • Get started
    • GitLab docs
    • GitLab Learn
  • Pricing
  • Talk to an expert
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
    Projects Groups Topics Snippets
  • Register
  • Sign in
  • GitLab GitLab
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
    • Locked files
  • Issues 55.1k
    • Issues 55.1k
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
    • Requirements
  • Merge requests 1.6k
    • Merge requests 1.6k
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Artifacts
    • Schedules
    • Test cases
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Container Registry
    • Terraform modules
    • Model experiments
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • GitLab.orgGitLab.org
  • GitLabGitLab
  • Issues
  • #333034
Closed
Open
Issue created Jun 08, 2021 by James Fargher@proglottis🌴Maintainer

[Feature flag] Enable repository backups using gitaly-backup

Summary

This issue is to rollout repository backups using gitaly-backup on production, that is currently behind the gitaly_backup feature flag.

Owners

  • Team: Gitaly
  • Most appropriate slack channel to reach out to: #g_create_gitaly
  • Best individual to reach out to: @proglottis
  • PM: @mjwood

Stakeholders

The Rollout Plan

  • Rollout Feature for everyone as soon as it's ready

Since gitlab repository backups aren't used on gitlab.com. We only want to provide a way for on-prem users to opt-out in an emergency.

Expectations

What are we expecting to happen?

This is an architectural change to how repository backups are made. Repository backups should continue to work as before.

What might happen if this goes wrong?

Errors while trying to create or restore the repository backups.

What can we monitor to detect problems with this?

Backups are used for on-prem only. So this rollout will need to rely on issues being reported.

Rollout Steps

Release the feature with the feature flag

If you're still unsure whether the feature is deemed stable but want to release it in the current milestone, you can change the default state of the feature flag to be enabled. To do so, follow these steps:

  • Create a merge request with the following changes. Ask for review and merge it.
    • Set the default_enabled attribute in the feature flag definition to true.
    • Create a changelog entry.
  • Ensure that the above MR has been deployed to both production and canary. If the merge request was deployed before the code cutoff, the feature can be officially announced in a release blog post.
    • /chatops run auto_deploy status <merge-commit>
  • Close the feature issue to indicate the feature will be released in the current milestone.

WARNING: This approach has the downside that it makes it difficult for us to clean up the flag. For example, on-premise users could disable the feature on their GitLab instance. But when you remove the flag at some point, they suddenly see the feature as enabled and they can't roll it back to the previous behavior. To avoid this potential breaking change, use this approach only for urgent matters.

Release the feature

After the feature has been deemed stable, the clean up should be done as soon as possible to permanently enable the feature and reduce complexity in the codebase.

  • Create a merge request to remove <feature-flag-name> feature flag. Ask for review and merge it.
    • Remove all references to the feature flag from the codebase.
    • Remove the YAML definitions for the feature from the repository.
    • Create a changelog entry.
  • Ensure that the above MR has been deployed to both production and canary. If the merge request was deployed before the code cutoff, the feature can be officially announced in a release blog post.
    • /chatops run auto_deploy status <merge-commit>
  • Close the feature issue to indicate the feature will be released in the current milestone.
  • Clean up the feature flag from all environments by running these chatops command in #production channel:
    • /chatops run feature delete <feature-flag-name> --dev
    • /chatops run feature delete <feature-flag-name> --staging
    • /chatops run feature delete <feature-flag-name>
  • Close this rollout issue.

Rollback Steps

  • This feature can be disabled by running the following Chatops command:
/chatops run feature set gitaly_backup false
Edited Oct 04, 2021 by James Fargher
Assignee
Assign to
Time tracking