• Stan Hu's avatar
    Geo: Always update the default branch on the secondary · 043f8273
    Stan Hu authored
    Previously, we would only update the default branch on a Geo secondary
    if the default branch didn't match the primary default branch. However,
    the Gitaly FindDefaultBranch RPC may return an arbitrary branch if HEAD
    points to an invalid branch, so we can't trust that result to be
    correct.
    
    To ensure that the default branch is always correct, we now write it out
    on the Geo secondary whenever we do a sync. This incurs an additional
    filesystem write, but that should be relatively minor.
    
    Closes https://gitlab.com/gitlab-org/gitlab-ee/issues/9084
    043f8273
project_spec.rb 48.8 KB