diff options
author | Sami Hiltunen <shiltunen@gitlab.com> | 2023-07-10 23:01:28 +0300 |
---|---|---|
committer | Sami Hiltunen <shiltunen@gitlab.com> | 2023-07-11 11:10:52 +0300 |
commit | fa5a5186d74744e9bb62d13d82323f0c02956e1c (patch) | |
tree | 7cf4abd8bb93746b1309acdab5547c2b7005856a /internal/testhelper/testserver/gitaly.go | |
parent | 1a3c14aaac2b3fa39f9ad9f0f407fbb0ea9469a0 (diff) |
Move UpdaterWithHooks from git to hook package
UpdaterWithHooks wraps 'git update-ref' with executing the hooks by
calling Gitaly's HookManager. While the Updater itself is just a plain
'update-ref' wrapper, UpdaterWithHooks ties more into Gitaly's domain
types. This is prone to creating cyclic dependencies as anything that
needs to use the 'update-ref' wrapper will also import the hook package
from Gitaly. This creates a problem for TransactionManager as we are
about to integrate some of the transaction logic in the hooks. Fix
the cyclic dependency by moving UpdaterWithHooks into its own subpackage
below the main 'hook' package.
Diffstat (limited to 'internal/testhelper/testserver/gitaly.go')
-rw-r--r-- | internal/testhelper/testserver/gitaly.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/internal/testhelper/testserver/gitaly.go b/internal/testhelper/testserver/gitaly.go index 1b78c581d..0e3527fe1 100644 --- a/internal/testhelper/testserver/gitaly.go +++ b/internal/testhelper/testserver/gitaly.go @@ -18,12 +18,12 @@ import ( "gitlab.com/gitlab-org/gitaly/v16/internal/git/gittest" "gitlab.com/gitlab-org/gitaly/v16/internal/git/housekeeping" "gitlab.com/gitlab-org/gitaly/v16/internal/git/localrepo" - "gitlab.com/gitlab-org/gitaly/v16/internal/git/updateref" "gitlab.com/gitlab-org/gitaly/v16/internal/git2go" "gitlab.com/gitlab-org/gitaly/v16/internal/gitaly/config" "gitlab.com/gitlab-org/gitaly/v16/internal/gitaly/config/auth" gitalylog "gitlab.com/gitlab-org/gitaly/v16/internal/gitaly/config/log" "gitlab.com/gitlab-org/gitaly/v16/internal/gitaly/hook" + "gitlab.com/gitlab-org/gitaly/v16/internal/gitaly/hook/updateref" "gitlab.com/gitlab-org/gitaly/v16/internal/gitaly/server" "gitlab.com/gitlab-org/gitaly/v16/internal/gitaly/service" "gitlab.com/gitlab-org/gitaly/v16/internal/gitaly/storage" |