ee/app/services/geo/base_sync_service.rb
# Use snapshotting for redownloads *only* when enabled.
#
# If writes happen to the repository while snapshotting, it may be
# returned in an inconsistent state. However, a subsequent git fetch
# will be enqueued by the log cursor, which should resolve any problems
# it is possible to fix.
Use snapshotting for redownloads *only* when enabled.
If writes happen to the repository while snapshotting, it may be
returned in an inconsistent state. However, a subsequent git fetch
will be enqueued by the log cursor, which should resolve any problems
it is possible to fix.
Use snapshotting for redownloads * only * when enabled . If writes happen to the repository while snapshotting it may be returned in an inconsistent state . However a subsequent git fetch will be enqueued by the log cursor which should resolve any problems it is possible to fix .
def fetch_snapshot
      return unless Feature.enabled?(:geo_redownload_with_snapshot)
      log_info("Attempting to fetch repository via snapshot")
      temp_repo.create_from_snapshot(
        ::Gitlab::Geo.primary_node.snapshot_url(temp_repo),
        ::Gitlab::Geo::RepoSyncRequest.new.authorization
      )
    rescue => err
      log_error('Snapshot attempt failed', err)
      false
    end
def fetch_snapshot return unless Feature . enabled? ( :geo_redownload_with_snapshot ) log_info ( "Attempting to fetch repository via snapshot" ) temp_repo . create_from_snapshot ( :: Gitlab :: Geo . primary_node . snapshot_url ( temp_repo ) , :: Gitlab :: Geo :: RepoSyncRequest . new . authorization ) rescue => err log_error ( 'Snapshot attempt failed' , err ) false end
Use snapshotting for redownloads *only* when enabled.
Use snapshotting for redownloads * only * when enabled .