[Solved] How to use licensed version of flyway with dropwizard-flyway library


For others who may run into the same issue, this is how I eventually fixed it:

  1. Download and unzip the flyway enterprise trial version
  2. Navigate to the directory you unzipped into
  3. Run installToLocalMavenRepo.cmd
  4. Run deployToRemoteMavenRepo.cmd – here you will need your remote repo ID and URL. I found these in my distributionManagement section in my projects POM.XML file.
  5. In your project POM.XML file – add an exclusion for flyway-core to the dropwizard-flyway artifact as follows:

     <dependency>
        <groupId>io.dropwizard.modules</groupId>
        <artifactId>dropwizard-flyway</artifactId>
        <version>5.0.7</version>
        <exclusions>
           <exclusion>
              <groupId>org.flywaydb</groupId>
              <artifactId>flyway-core</artifactId>
           </exclusion>
        </exclusions>
     </dependency>
    
  6. Add a dependency to flyway-core trial version as follows:

     <dependency>
        <groupId>org.flywaydb.trial</groupId>
        <artifactId>flyway-core</artifactId>
        <version>5.0.7</version>
     </dependency>
    

You should now be good to go.

solved How to use licensed version of flyway with dropwizard-flyway library