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

Liquibase/Flyway autoconfiguration order #537

Closed
uladzislau-belykh opened this issue Feb 25, 2021 · 4 comments
Closed

Liquibase/Flyway autoconfiguration order #537

uladzislau-belykh opened this issue Feb 25, 2021 · 4 comments
Assignees
Milestone

Comments

@uladzislau-belykh
Copy link

Hello,

I use your starter in our project and found an issue with the autoconfiguration order. Sometimes SqlSessionFactory and SqlSessionTemplate can be configured and used before liquibase/flyway initialized the database completely. That leads to
problems on startup in an empty environment.

As I checked, Liquibase/Flyway AutoConfiguration provides *DependsOnPostProcessors for standard JDBC beans (JdbcTemplate and EntityManager). That ensures the order in which beans will be initialized.

Now I added this dependency manually, but it will be nice if this will be in autoconfiguration.

Thank you in advance.

@kazuki43zoo
Copy link
Member

Hi @uladzislau-belykh , Thanks and Sorry for the late response.

We will consider to support the DependsOnPostProcessors on mybatis auto-configuration feature.
If possible, Could you provide a small reproduce project that occurred a problem and project that applied a workaround? We want to use it for testing.

@kazuki43zoo kazuki43zoo self-assigned this Mar 8, 2021
@uladzislau-belykh
Copy link
Author

You can find the sample here

@kazuki43zoo kazuki43zoo added this to the 2.3.0 milestone May 15, 2022
kazuki43zoo added a commit that referenced this issue May 29, 2022
SqlTemplate depends on flyway/liquibase execution
@eddumelendez
Copy link
Member

#648 is merged.

@kazuki43zoo
Copy link
Member

@uladzislau-belykh
We resolved this issue on 2.3.0(not release yet, but you can use the snapshot version). 2.3.0 require to use together with Spring Boot 2.5+.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants