mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-04-24 22:17:25 -04:00
Clean up migration logging messages
This commit is contained in:
parent
a0fdceb4bc
commit
2f0b4cc24c
1 changed files with 5 additions and 4 deletions
|
@ -46,11 +46,11 @@ namespace Jellyfin.Server.Migrations
|
||||||
var migrationRoutine = Migrations[i];
|
var migrationRoutine = Migrations[i];
|
||||||
if (applied.Contains(migrationRoutine.Name))
|
if (applied.Contains(migrationRoutine.Name))
|
||||||
{
|
{
|
||||||
logger.LogDebug("Skipping migration {Name} as it is already applied", migrationRoutine.Name);
|
logger.LogDebug("Skipping migration '{Name}' since it is already applied", migrationRoutine.Name);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
logger.LogInformation("Applying migration {Name}", migrationRoutine.Name);
|
logger.LogInformation("Applying migration '{Name}'", migrationRoutine.Name);
|
||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
@ -58,15 +58,16 @@ namespace Jellyfin.Server.Migrations
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
logger.LogError(ex, "Could not apply migration {Name}", migrationRoutine.Name);
|
logger.LogError(ex, "Could not apply migration '{Name}'", migrationRoutine.Name);
|
||||||
throw;
|
throw;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Mark the migration as completed
|
// Mark the migration as completed
|
||||||
logger.LogInformation("Migration {Name} applied successfully", migrationRoutine.Name);
|
logger.LogInformation("Migration '{Name}' applied successfully", migrationRoutine.Name);
|
||||||
applied.Add(migrationRoutine.Name);
|
applied.Add(migrationRoutine.Name);
|
||||||
migrationOptions.Applied = applied.ToArray();
|
migrationOptions.Applied = applied.ToArray();
|
||||||
host.ServerConfigurationManager.SaveConfiguration(MigrationsListStore.StoreKey, migrationOptions);
|
host.ServerConfigurationManager.SaveConfiguration(MigrationsListStore.StoreKey, migrationOptions);
|
||||||
|
logger.LogDebug("Migration '{Name}' marked as applied in configuration.", migrationRoutine.Name);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue