-
Couldn't load subscription status.
- Fork 41.6k
Upgrade Flyway 4.0 #5344
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
Upgrade Flyway 4.0 #5344
Conversation
| @Configuration | ||
| @ConditionalOnClass(LocalContainerEntityManagerFactoryBean.class) | ||
| @ConditionalOnBean(AbstractEntityManagerFactoryBean.class) | ||
| protected static class FlywayInitializerJpaDependencyConfiguration |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We'll still need something that's the equivalent of this to ensure that Flyway migrations have been run for Hibernate is initialized.
| } | ||
| if (!CollectionUtils.isEmpty(this.flywayCallbacks)) { | ||
| for (FlywayCallback flywayCallback : this.flywayCallbacks) { | ||
| flyway.setCallbacks(flywayCallback); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This logic means that only the last callback will be used. A test that verifies that multiple callbacks are called, and that they're called in a well-defined and predictable order would be useful.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will take a look to fix this. Thanks
|
@wilkinsona I have updated the PR keeping the |
|
Is there any reason why this cannot be included in 1.4 release train? |
|
PR rebased and now all tests are running ok. |
@ptahchiev No specific reason. A new major version suggested to me that there would be breaking changes which, generally speaking, we avoid in minor releases of Boot. If you'd like to see this in 1.4, some research into what the breaking changes are, if indeed there are any, would be very useful. |
|
When upgrading to flyway4 please notice that the |
* gh-5344: Polish "Upgrade to Flyway 4.0" Upgrade to Flyway 4.0
|
I've merged this into master. Thanks for yet another PR, @eddumelendez! |
See gh-5296