Skip to content
Snippets Groups Projects
Commit 8784d29a authored by Tor-Einar Skog's avatar Tor-Einar Skog
Browse files

Upgraded Flywaydb to latest version

parent fe6057e9
Branches
No related tags found
No related merge requests found
......@@ -60,7 +60,7 @@
<dependency>
<groupId>org.flywaydb</groupId>
<artifactId>flyway-core</artifactId>
<version>4.2.0</version>
<version>8.3.0</version>
</dependency>
<dependency>
<groupId>org.hibernate</groupId>
......
......@@ -51,8 +51,10 @@ public class StartupListener implements javax.servlet.ServletContextListener{
System.out.println("VIPSLogic system initializing");
System.out.println("VIPSLogic checking for database migrations");
// Migrate DB on startup using flywaydb.org
Flyway flyway = new Flyway();
flyway.setDataSource(vipslogicDS);
Flyway flyway = Flyway.configure()
.table("schema_version") // This was done to ease the upgrade from v4 to v8 - which has "flyway_schema_history" as default name for this table
.dataSource(vipslogicDS)
.load();
flyway.migrate();
schedulingBean.initSystemScheduler();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment