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
Flyway 9.19.3 migrate hangs forever on second non-transactional migration #3682
Comments
I can confirm that this is also happening on the Flyway Docker Image as well.
|
I also posted for the docker image :)
You're right, the new default for transaction is set to |
Thanks for your update. We have been making updates to the configuration of Flyway and it seems like this has become disconnected. We have already started a fix for this and will update soon. |
9.19.4 is working for me, thanks guys for the quick fix! |
I've tried with this previous minimal example and changing Flyway version to 9.19.4 or 9.21.1, but it still hangs when creating the index. Is there anything else that needs to be done to make it work? |
Following to message from @MrMaxxan, this behaviour is also reproducible in |
Has there been a fix yet? |
Also encountering this on 9.22.2 |
My workaround is to add
|
Running into the forever hang on |
We are also encountering this issue on Reopen plz? |
Same issue on 9.22.3 |
I've gone down all the way to version 9.6 and it still has this problem. |
Same issue here on 9.22.3. |
Facing this issue on 9.8.2 |
same issue on spring boot 3.2 + flyway 9.22.3. All the solutions here does not work for me. |
To avoid this issue, two conditions need to be met:
|
There was a regression sometime around 9.22. I just encountered it this morning on 10.6.0 with |
I did another round of verification of this scenario with the latest version of Flyway:
|
Step 1+2 will successfully create the index (once flyway is terminated, the deadlock clears up and the creation succeeds), so step 3+4 will fail with "ERROR: relation ... already exists". I suspect you have If you start the process with I am able to recreate this issue reliably, now in 10.7.1. https://gist.github.com/luhn/7688fb2545bb7bab59c4d7cd02ff3d15 |
Hi @luhn , But I was able to reproduce the issue now with the configurations you have provided in the gist link. And I found out that it's due to the "# Issue with CREATE INDEX CONCURRENTLY" comment in the conf file. Remove that comment or put it in a separated line, the issue will be gone. |
Huh, sure enough. Thanks for your help! |
I am getting the same error with version 9.18.0 and I am setting the |
Hi @ehsansad ,
|
Which version and edition of Flyway are you using?
9.19.3 docker image
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)
CLI in docker
Which database are you using? (Type & version)
postgres 13
Which operating system are you using?
alpine (docker)
What did you do? (Please include the content causing the issue, any relevant configuration settings, the SQL statement(s) that failed (if any), and the command you ran)
Command:
Migrations that have worked before suddenly freeze on the second non-transactional query using the latest docker image release (9.19.3).
What I've tried:
-postgresql.transactional.lock=false
flagWhat did you expect to see?
I expected migrations to complete (within 15 minutes) and not freeze on non-transactional queries.
What did you see instead?
Migration freezes, -postgresql.transactional.lock=false does not work
The text was updated successfully, but these errors were encountered: