Skip to content

(BEDS-1113) use creation ts to determine oldest vdb for archival/removal#1236

Merged
remoterami merged 1 commit intostagingfrom
BEDS-1113/archiver-sort-by-creation-date
Jan 8, 2025
Merged

(BEDS-1113) use creation ts to determine oldest vdb for archival/removal#1236
remoterami merged 1 commit intostagingfrom
BEDS-1113/archiver-sort-by-creation-date

Conversation

@remoterami
Copy link
Contributor

No description provided.

slices.Sort(activeDashboards)
for id := 0; id < len(activeDashboards)-dashboardLimit; id++ {
dashboardsToBeArchived = append(dashboardsToBeArchived, t.ArchiverDashboardArchiveReason{DashboardId: activeDashboards[id], ArchivedReason: enums.VDBArchivedReasons.Dashboards})
for _, id := range activeDashboards[:len(activeDashboards)-dashboardLimit] {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@remoterami Can len(activeDashboards)-dashboardLimit return negative value?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, this is excluded by the check in line 82

@remoterami remoterami merged commit f0259aa into staging Jan 8, 2025
2 checks passed
@remoterami remoterami deleted the BEDS-1113/archiver-sort-by-creation-date branch January 8, 2025 14:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants