fb6a4e21d4
This brings back some of the changes in https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/20339. For users using Gitaly on top of NFS, accessing the Git data directly via Rugged is more performant than Gitaly. This merge request introduces the feature flag `rugged_find_commit` to activate Rugged paths. There are also Rake tasks `gitlab:features:enable_rugged` and `gitlab:features:disable_rugged` to enable/disable these feature flags altogether. Part of four Rugged changes identified in https://gitlab.com/gitlab-org/gitlab-ce/issues/57317.
20 lines
483 B
Ruby
20 lines
483 B
Ruby
# frozen_string_literal: true
|
|
|
|
# NOTE: This code is legacy. Do not add/modify code here unless you have
|
|
# discussed with the Gitaly team. See
|
|
# https://docs.gitlab.com/ee/development/gitaly.html#legacy-rugged-code
|
|
# for more details.
|
|
|
|
module Gitlab
|
|
module Git
|
|
module RuggedImpl
|
|
module Ref
|
|
def self.dereference_object(object)
|
|
object = object.target while object.is_a?(::Rugged::Tag::Annotation)
|
|
|
|
object
|
|
end
|
|
end
|
|
end
|
|
end
|
|
end
|