refactor: move auth, GDPR, and booking cleanup to centralized scheduler

Convert CleanupRevokedJTIs to return (int, error) and remove StartJTICleanup goroutine. Add CleanupStaleLoginEntries and CleanupGDPRExportCache for centralized scheduler. Add clock.London timezone location.

Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)

Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
2026-07-07 00:10:00 +01:00
co-authored by Sisyphus
parent a4fa75154d
commit e86248b27c
7 changed files with 276 additions and 79 deletions
+14
View File
@@ -1,3 +1,7 @@
// Package clock provides the single source of truth for time across the
// application. All wall-clock operations use Now() for UTC consistency with
// the database. LondonLocation provides Europe/London for cron schedules and
// scheduling calculations that depend on local business-closing rules.
package clock
import "time"
@@ -8,3 +12,13 @@ import "time"
func Now() time.Time {
return time.Now().UTC()
}
// London is the Europe/London timezone location, used for cron schedules and
// business-closing calculations.
var London = func() *time.Location {
loc, err := time.LoadLocation("Europe/London")
if err != nil {
panic("clock: failed to load Europe/London timezone: " + err.Error())
}
return loc
}()