Flyway-Databricks integration

Viewed 236

I am exploring Flyway for Database migration. I want to integrate it with Databricks. Have performed some tasks and trying to overcome the following error.

Till now I have performed

  1. Flyway setup on the local machine.
  2. Copied spark-jdbc databricks driver to drivers folder of Flyway
  3. Updated the Flyway config

Picked-up the jdbc url from databricks cluster and created a token in databricks. Added these configurations in flyway config.
flyway.url= jdbc:spark://<hostname>:443/<database>;transportMode=http;ssl=1;AuthMech=3;httpPath=<httpPath>;UID=token;PWD=<token>
flyway.driver=com.simba.spark.jdbc.Driver
flyway.user=<dummy_username>
flyway.password=<token>

  1. Error received

ERROR: Unexpected error
org.flywaydb.core.api.FlywayException: No database found to handle jdbc:spark://<host>:443/<database>
        at org.flywaydb.core.internal.database.DatabaseTypeRegister.getDatabaseTypeForUrl(DatabaseTypeRegister.java:55)
        at org.flywaydb.core.internal.jdbc.DriverDataSource.<init>(DriverDataSource.java:109)
        at org.flywaydb.core.internal.jdbc.DriverDataSource.<init>(DriverDataSource.java:89)
        at org.flywaydb.core.api.configuration.ClassicConfiguration.configure(ClassicConfiguration.java:1653)
        at org.flywaydb.core.api.configuration.FluentConfiguration.configuration(FluentConfiguration.java:1038)
        at org.flywaydb.commandline.Main.main(Main.java:159)

1 Answers

Error - org.flywaydb.core.api.FlywayException: No database found to handle jdbc:spark://:443/

This error occurred because of different versions of drivers.

Try with downgraded version. If it doesn’t work, you can try with different combinations of configuration.

For similar issue you can refer this github link

Related