feat(store): api/reaper/offsite/migrate 按版本集合校验 schema,库比二进制新时拒绝启动;bootstrap 迁移前失败回滚宿主二进制
This commit is contained in:
17 files changed
+390
-38
No files matched your search
+3
-1
@@ -345,7 +345,9 @@ func openConfiguredSetup(ctx context.Context, cfgPath string) (*configuredSetup,
|
||||
if err != nil {
|
||||
return nil, &setupOpenError{stage: "load config", err: err}
|
||||
}
|
||||
drv, err := store.Open(ctx, cfg.Database.URL)
|
||||
// Pending migrations are the preflight's to apply; a newer schema is a rolled-back
|
||||
// binary, and nothing this console writes would match it.
|
||||
drv, err := openStore(ctx, cfg.Database.URL, true)
|
||||
if err != nil {
|
||||
return nil, &setupOpenError{stage: "open database", err: err}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user