mirror of
https://github.com/Radarr/Radarr.git
synced 2025-04-23 22:17:15 -04:00
New: Log which DB is being migrated
(cherry picked from commit 07c95f06d3b9b32aaeb923d4c678f10a2bf1141a)
This commit is contained in:
parent
672b37c319
commit
4f8b0dd5cc
1 changed files with 10 additions and 2 deletions
|
@ -41,15 +41,18 @@ namespace NzbDrone.Core.Datastore.Migration.Framework
|
|||
switch (MigrationContext.Current.MigrationType)
|
||||
{
|
||||
case MigrationType.Main:
|
||||
_logger.Info("Starting migration to " + Version);
|
||||
LogMigrationMessage(MigrationType.Main);
|
||||
MainDbUpgrade();
|
||||
return;
|
||||
case MigrationType.Log:
|
||||
_logger.Info("Starting migration to " + Version);
|
||||
LogMigrationMessage(MigrationType.Log);
|
||||
LogDbUpgrade();
|
||||
return;
|
||||
default:
|
||||
LogMigrationMessage(MigrationType.Log);
|
||||
LogDbUpgrade();
|
||||
|
||||
LogMigrationMessage(MigrationType.Main);
|
||||
MainDbUpgrade();
|
||||
return;
|
||||
}
|
||||
|
@ -59,5 +62,10 @@ namespace NzbDrone.Core.Datastore.Migration.Framework
|
|||
{
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
private void LogMigrationMessage(MigrationType type)
|
||||
{
|
||||
_logger.Info("Starting migration of {0} DB to {1}", type.ToString(), Version);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue