Merge pull request #1058 from Icinga/overdue-sync-redis-key-namespace

overdue: Temporary Key in "icingadb:" Namespace
This commit is contained in:
Alvar 2026-01-13 16:05:13 +00:00 committed by GitHub
commit 4e3fe1c0d5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 2 deletions

View file

@ -1,7 +1,7 @@
-- get_overdues.lua takes the following KEYS:
-- * either icinga:nextupdate:host or icinga:nextupdate:service
-- * either icingadb:overdue:host or icingadb:overdue:service
-- * a random one
-- * a temporary one with a random name in the icingadb:temp namespace
--
-- It takes the following ARGV:
-- * the current date and time as *nix timestamp float in seconds

View file

@ -143,7 +143,7 @@ func (s Sync) sync(ctx context.Context, objectType string, factory factory, coun
keys := [3]string{"icinga:nextupdate:" + objectType, "icingadb:overdue:" + objectType, ""}
if rand, err := uuid.NewRandom(); err == nil {
keys[2] = rand.String()
keys[2] = "icingadb:temp:" + rand.String()
} else {
return errors.Wrap(err, "can't create random UUID")
}