8000 fix(api): take care of not executed for migration status (#4905) · ovh/cds@d9a2517 · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Commit d9a2517

Browse files
richardltsguiheux
authored andcommitted
fix(api): take care of not executed for migration status (#4905)
1 parent 39d9030 commit d9a2517

File tree

1 file changed

+2
-1
lines changed
< 8000 div class="d-flex gap-2 flex-items-center">

1 file changed

+2
-1
lines changed

engine/api/migrate/migration.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,8 @@ func CleanMigrationsList() {
9898

9999
// Status returns monitoring status, if there are cds migration in progress it returns WARN
100100
func Status(db gorp.SqlExecutor) sdk.MonitoringStatusLine {
101-
count, err := db.SelectInt("SELECT COUNT(id) FROM cds_migration WHERE status <> $1 AND status <> $2", sdk.MigrationStatusDone, sdk.MigrationStatusCanceled)
101+
count, err := db.SelectInt("SELECT COUNT(id) FROM cds_migration WHERE status <> $1 AND status <> $2 AND status <> $3",
102+
sdk.MigrationStatusDone, sdk.MigrationStatusCanceled, sdk.MigrationStatusNotExecuted)
102103
if err != nil {
103104
return sdk.MonitoringStatusLine{Component: "CDS Migration", Status: sdk.MonitoringStatusWarn, Value: fmt.Sprintf("KO Cannot request in database : %v", err)}
104105
}

0 commit comments

Comments
 (0)
0