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

Regression in 5.1.0 regarding non-transactional migrations including comments #2029

Closed
pakohan opened this issue May 28, 2018 · 1 comment
Closed

Comments

@pakohan
Copy link

@pakohan pakohan commented May 28, 2018

Which version and edition of Flyway are you using?

5.1.0

If this is not the latest version, can you reproduce the issue with the latest one as well?

(Many bugs are fixed in newer releases and upgrading will often resolve the issue)

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

Command-line in alpine docker image

Which database are you using (type & version)?

Postgres 9.6

Which operating system are you using?

Linux

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.)

migrate

-- Insertion order invoicing state
ALTER TYPE invoicing_state ADD VALUE IF NOT EXISTS 'factored';
ALTER TYPE invoicing_state ADD VALUE IF NOT EXISTS 'partially_factored';
What did you expect to see?

That the migration succeeds.

What did you see instead?

It didn't.

When upgrading from 5.0.7 to 5.1.0 the non-transactional migrations feature breaks for every migration including SQL comments. It seems that flyway recognizes these as transactional-eligible statements and thus does not run migrations with non-transactional statements, when mixed-migrations are not allowed. Since we've already applied these on our prod system, we cannot fix this issue by altering these migrations to not include comments anymore nor do we want to alter the checksums in the schema_version tables.

@axelfontaine axelfontaine added this to the Flyway 5.1.1 milestone May 28, 2018
axelfontaine added a commit to flyway/flywaydb.org that referenced this issue May 28, 2018
@axelfontaine
Copy link
Contributor

@axelfontaine axelfontaine commented May 28, 2018

Thanks for reporting and the analysis. Fixed.

awal11 pushed a commit to awal11/flyway that referenced this issue Sep 18, 2018
dohrayme pushed a commit to dohrayme/flyway that referenced this issue Feb 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants