[v11.0.x] Snapshots: Fix panic when snapshot_remove_expired is true (#91330)
Snapshots: Fix panic when snapshot_remove_expired is true (#91232)
(cherry picked from commit bb5d2c83ef)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
This commit is contained in:
co-authored by
Ryan McKinley
parent
15a3afdc35
commit
cb75e88483
@@ -34,7 +34,7 @@ func NewStore(db db.DB, skipDeleteExpired bool) *DashboardSnapshotStore {
|
|||||||
if skipDeleteExpired {
|
if skipDeleteExpired {
|
||||||
log.Warn("[Deprecated] The snapshot_remove_expired setting is outdated. Please remove from your config.")
|
log.Warn("[Deprecated] The snapshot_remove_expired setting is outdated. Please remove from your config.")
|
||||||
}
|
}
|
||||||
return &DashboardSnapshotStore{store: db, skipDeleteExpired: skipDeleteExpired}
|
return &DashboardSnapshotStore{store: db, skipDeleteExpired: skipDeleteExpired, log: log}
|
||||||
}
|
}
|
||||||
|
|
||||||
// DeleteExpiredSnapshots removes snapshots with old expiry dates.
|
// DeleteExpiredSnapshots removes snapshots with old expiry dates.
|
||||||
|
|||||||
Reference in New Issue
Block a user