fix(deps): update flyway to v11.14.1

This commit is contained in:
Renovate authored and anthorob committed 2025-10-22 21:27:32 +00:00
1 parent f345505578
commit 47ced9d0f2
2 files changed
+7 -4

No files matched your search

@@ -9,6 +9,7 @@ import me.bobert.netneutrality.utils.Settings;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.flywaydb.core.Flyway;
import org.flywaydb.core.api.output.MigrateResult;
public class DatabaseMigration {
private final static Logger logger = LogManager.getLogger(DatabaseMigration.class);
@@ -21,11 +22,13 @@ public class DatabaseMigration {
String dbUrl = String.format("jdbc:mysql://%s:3306/%s", dbHost, dbName);
try {
logger.info("Running database migrations..");
Flyway flyway = Flyway.configure()
.dataSource(dbUrl, dbUser, dbPass)
.load();
flyway.migrate();
MigrateResult result = flyway.migrate();
logger.info("Database migrations finished successfully! (total: {})", result.migrationsExecuted);
} catch (Exception e) {
logger.error(e);
System.exit(1);