From 4a8d84b30344780c91a4a1fa4a4ec5cdb5cc1ab0 Mon Sep 17 00:00:00 2001 From: Asaf Gartner Date: Mon, 9 Aug 2021 11:06:39 +0300 Subject: [PATCH] Only run user cleanup once an hour. Not every 10 seconds. --- src/auth/auth.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/auth/auth.go b/src/auth/auth.go index 7c5371f1..63c5ced4 100644 --- a/src/auth/auth.go +++ b/src/auth/auth.go @@ -216,7 +216,7 @@ func PeriodicallyDeleteInactiveUsers(ctx context.Context, conn *pgxpool.Pool) <- go func() { defer close(done) - t := time.NewTicker(10 * time.Second) + t := time.NewTicker(1 * time.Hour) for { select { case <-t.C: