remove debugging info messages (change to debug if we want these -- and tell us how to turn off debug locally)

This commit is contained in:
2025-06-20 14:01:08 -06:00
parent 1c428daa3a
commit e5e07faf2a
4 changed files with 7 additions and 54 deletions

View File

@@ -25,7 +25,6 @@ class MigrationRegistry {
*/
registerMigration(migration: Migration): void {
this.migrations.push(migration);
logger.info(`[MigrationService] Registered migration: ${migration.name}`);
}
/**
@@ -42,7 +41,6 @@ class MigrationRegistry {
*/
clearMigrations(): void {
this.migrations = [];
logger.info("[MigrationService] Cleared all registered migrations");
}
}
@@ -94,10 +92,6 @@ export async function runMigrations<T>(
);
const appliedMigrations = extractMigrationNames(appliedMigrationsResult);
logger.info(
`[MigrationService] Found ${appliedMigrations.size} applied migrations`,
);
// Get all registered migrations
const migrations = migrationRegistry.getMigrations();
@@ -106,21 +100,12 @@ export async function runMigrations<T>(
return;
}
logger.info(
`[MigrationService] Running ${migrations.length} registered migrations`,
);
// Run each migration that hasn't been applied yet
for (const migration of migrations) {
if (appliedMigrations.has(migration.name)) {
logger.info(
`[MigrationService] Skipping already applied migration: ${migration.name}`,
);
continue;
}
logger.info(`[MigrationService] Applying migration: ${migration.name}`);
try {
// Execute the migration SQL
await sqlExec(migration.sql);
@@ -141,8 +126,6 @@ export async function runMigrations<T>(
throw new Error(`Migration ${migration.name} failed: ${error}`);
}
}
logger.info("[MigrationService] All migrations completed successfully");
} catch (error) {
logger.error("[MigrationService] Migration process failed:", error);
throw error;