Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting unsupported error with correct versions? #2481

Closed
Tauri28 opened this issue Aug 25, 2019 · 7 comments

Comments

@Tauri28
Copy link

commented Aug 25, 2019

Which version and edition of Flyway are you using?

6.0.0 Community Edition

Which client are you using? (Command-line, Java API, Maven plugin, Gradle plugin)

CLI

Which database are you using (type & version)?

MariaDB (ver. 10.2.20)

Which operating system are you using?

Windows 10 Pro 1809

What did you do?

(Please include the content causing the issue, any relevant configuration settings, the SQL statement that failed (if relevant) and the command you ran.)
flyway migrate -url=jdbc:mysql://127.0.0.1/hmvc_listing?serverTimezone=UTC -user=xxx -password=xxx -table=xxx -locations=xxx -sqlMigrationSeparator=- -baselineOnMigrate=true -baselineVersion=000 -sqlMigrationPrefix='.

What did you expect to see?

Successful migration.

What did you see instead?

ERROR: Flyway Enterprise Edition or MariaDB upgrade required: MariaDB 5.5 is no longer supported by Flyway Community Edition, but still supported by Flyway Enterprise Edition.

@goekay

This comment has been minimized.

Copy link

commented Aug 26, 2019

we experience the same issue with builds using travis ci.

@pzygielo

This comment has been minimized.

Copy link

commented Aug 27, 2019

@Tauri28:

flyway migrate -url=jdbc:mysql://127.0.0.1/hmvc_listing?serverTimezone=UTC -user=xxx -password=xxx -table=xxx -locations=xxx -sqlMigrationSeparator=- -baselineOnMigrate=true -baselineVersion=000 -sqlMigrationPrefix='.

On https://flywaydb.org/documentation/database/mariadb the format of url is jdbc:mariadb:..., but you are using jdbc:mysql:.... Do you get the same error with url corrected?

@alextercete alextercete added the t: bug label Aug 27, 2019

@MikielAgutu

This comment has been minimized.

Copy link
Contributor

commented Aug 27, 2019

I've managed to reproduce this. As @pzygielo suggested the problem is that you're using a MySQL JDBC url instead of a MariaDB one. If you use jdbc:mariadb://127.0.0.1/hmvc_listing... it should be fine.

I can't see a reason why we'd need to support such interchangeability. Is there an advantage to using the MySQL JDBC url?

@goekay

This comment has been minimized.

Copy link

commented Aug 27, 2019

in our case, our product leaves the choice of database (mysql or mariadb) to the user/client. and since mariadb is supposed to be a drop-in replacement with some limitations and since mariadb connector/j itself allows both usages jdbc:(mysql|mariadb) i see this as a minor problem.

moreover, this was working with flyway 5.2.4 but stopped with 6.0.0 even though mariadb version we use (10.2.26) did not change. mariadb 10.2.26 is for sure newer than mariadb 5.5. therefore the report is not true.

@MikielAgutu

This comment has been minimized.

Copy link
Contributor

commented Aug 28, 2019

Fair point! This is due to slightly odd behavior in the way JDBC reports Maria DB versions. We've introduced a fix that should be in the next release.

@goekay

This comment has been minimized.

Copy link

commented Aug 28, 2019

thanks! as i understand from the commit, the version identification is corrected, which means we can continue using the prefix jdbc:mysql:... with mariadb, right?

@MikielAgutu

This comment has been minimized.

Copy link
Contributor

commented Aug 28, 2019

Yes you can continue using that url.

@juliahayward juliahayward added this to the Flyway 6.0.1 milestone Aug 28, 2019

goekay added a commit to goekay/flywaydb.org that referenced this issue Aug 28, 2019
Update mariadb url format to reflect what is possible
as established in flyway/flyway#2481, flyway supports both "jdbc:mysql" and "jdbc:mariadb" prefixes in database URLs.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
6 participants
You can’t perform that action at this time.