Skip to content
Advertisement

Flyway can’t find classpath:db/migrations

I just started right now a new project in Intellij using Spring Boot ver 2.1.3 and Flyway 5.2.4 with Java 11.

After try to start my project i got :

JavaScript

I have the following folders:

enter image description here

As you can see i have “db/migration” but without any migration, i just started right now. Debugging the class FlywayAutoConfiguration i got the following:

enter image description here

So, i tried to return all files in “classpath:”, see:

enter image description here

Note that i just have “application.properties” file.

Advertisement

Answer

I believe that Flyway requires at least one migration script to initialize. Try adding a simple sql creation script into your migration folder and give it another try. Alternatively you can disable the flyway dependency until you need it.

User contributions licensed under: CC BY-SA
6 People found this is helpful
Advertisement