Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Cai <jcai@gitlab.com>2021-12-13 21:40:37 +0300
committerJohn Cai <jcai@gitlab.com>2021-12-13 21:40:37 +0300
commitbba495c8c929b75f8cbcdc6d07d07431736aa8d1 (patch)
tree425e786deee7b56bdfc7f9711ab053d98d56732b /cmd/praefect
parent15a1323ae16dffd3ba6b078f6cb81e283a96c72d (diff)
parent145fc5f58f6811b83b00e92ba755664b4278c6dd (diff)
Merge branch 'pks-bootstrap-rewrite-tests' into 'master'
bootstrap: Rewrite tests to not use timeouts See merge request gitlab-org/gitaly!4188
Diffstat (limited to 'cmd/praefect')
-rw-r--r--cmd/praefect/main.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/cmd/praefect/main.go b/cmd/praefect/main.go
index 56f56ab9a..d444aff88 100644
--- a/cmd/praefect/main.go
+++ b/cmd/praefect/main.go
@@ -514,7 +514,10 @@ func run(
logger.Warn(`Repository cleanup background task disabled as "repositories_cleanup.run_interval" is not set or 0.`)
}
- return b.Wait(conf.GracefulStopTimeout.Duration(), srvFactory.GracefulStop)
+ gracefulStopTicker := helper.NewTimerTicker(conf.GracefulStopTimeout.Duration())
+ defer gracefulStopTicker.Stop()
+
+ return b.Wait(gracefulStopTicker, srvFactory.GracefulStop)
}
func getStarterConfigs(conf config.Config) ([]starter.Config, error) {