mirror of
https://codeberg.org/davrot/forgejo.git
synced 2025-05-24 00:00:02 +02:00
Add Status Updates whilst Gitea migrations are occurring (#15076)
* Add migrating message Signed-off-by: Andrew Thornton <art27@cantab.net> * simplify messenger Signed-off-by: Andrew Thornton <art27@cantab.net> * make messenger an interface Signed-off-by: Andrew Thornton <art27@cantab.net> * rename Signed-off-by: Andrew Thornton <art27@cantab.net> * prepare for merge Signed-off-by: Andrew Thornton <art27@cantab.net> * as per tech Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: 6543 <6543@obermui.de>
This commit is contained in:
parent
047c39e91b
commit
6d69df2804
13 changed files with 129 additions and 12 deletions
|
@ -555,7 +555,7 @@ func DumpRepository(ctx context.Context, baseDir, ownerName string, opts base.Mi
|
|||
return err
|
||||
}
|
||||
|
||||
if err := migrateRepository(downloader, uploader, opts); err != nil {
|
||||
if err := migrateRepository(downloader, uploader, opts, nil); err != nil {
|
||||
if err1 := uploader.Rollback(); err1 != nil {
|
||||
log.Error("rollback failed: %v", err1)
|
||||
}
|
||||
|
@ -620,7 +620,7 @@ func RestoreRepository(ctx context.Context, baseDir string, ownerName, repoName
|
|||
}
|
||||
updateOptionsUnits(&migrateOpts, units)
|
||||
|
||||
if err = migrateRepository(downloader, uploader, migrateOpts); err != nil {
|
||||
if err = migrateRepository(downloader, uploader, migrateOpts, nil); err != nil {
|
||||
if err1 := uploader.Rollback(); err1 != nil {
|
||||
log.Error("rollback failed: %v", err1)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue