summaryrefslogtreecommitdiff
path: root/workhorse/main.go
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2022-08-31 06:12:36 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2022-08-31 06:12:36 +0000
commit136651d7cb69357d2823adefac430df389e81e17 (patch)
tree9e501e488170ff6f8be0f7fec2405a54440391d4 /workhorse/main.go
parenta5bd90f43bbd7d7b3222cf84698daa2cbc6e2b3f (diff)
downloadgitlab-ce-136651d7cb69357d2823adefac430df389e81e17.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'workhorse/main.go')
-rw-r--r--workhorse/main.go7
1 files changed, 4 insertions, 3 deletions
diff --git a/workhorse/main.go b/workhorse/main.go
index 91008e16961..b0f9760b0d5 100644
--- a/workhorse/main.go
+++ b/workhorse/main.go
@@ -220,9 +220,10 @@ func run(boot bootConfig, cfg config.Config) error {
secret.SetPath(boot.secretPath)
+ keyWatcher := redis.NewKeyWatcher()
if cfg.Redis != nil {
redis.Configure(cfg.Redis, redis.DefaultDialFunc)
- go redis.Process()
+ go keyWatcher.Process()
}
if err := cfg.RegisterGoCloudURLOpeners(); err != nil {
@@ -237,7 +238,7 @@ func run(boot bootConfig, cfg config.Config) error {
gitaly.InitializeSidechannelRegistry(accessLogger)
- up := wrapRaven(upstream.NewUpstream(cfg, accessLogger))
+ up := wrapRaven(upstream.NewUpstream(cfg, accessLogger, keyWatcher.WatchKey))
done := make(chan os.Signal, 1)
signal.Notify(done, syscall.SIGINT, syscall.SIGTERM)
@@ -271,7 +272,7 @@ func run(boot bootConfig, cfg config.Config) error {
ctx, cancel := context.WithTimeout(context.Background(), cfg.ShutdownTimeout.Duration) // lint:allow context.Background
defer cancel()
- redis.Shutdown()
+ keyWatcher.Shutdown()
return srv.Shutdown(ctx)
}
}