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 3.8.5, hibernate 5.4.10.Final, spring boot 2.2.4.RELEASE, and hibernate search 6 cause liquibase diff failed. #222

Closed
alexis-puska opened this issue Jan 30, 2020 · 11 comments

Comments

@alexis-puska
Copy link

alexis-puska commented Jan 30, 2020

Hi,
I have a project with liquibase 3.8.5, liquiabse hibernate 3.8, spring boot 2.2.4, hibernate 5.4.10 ans hibernate search, i get this error.

[ERROR] Failed to execute goal org.liquibase:liquibase-maven-plugin:3.8.5:diff (default-cli) on project master-hipster-2: Error setting up or running Liquibase: javax.persistence.PersistenceException: Unable to resolve persistence unit root URL: class path resource [] cannot be resolved to URL because it does not exist -> [Help 1]

In jhipster issues i have read that liquibase 3.7 know this error and it's not fixed. How can we configured liquibase to fixe this missing classpath resources ?

thank's

@DanielFran
Copy link
Contributor

You need to downgrade to liquibase <=3.6 like in jhipster

@DanielFran
Copy link
Contributor

We hope some help from @liquibase...

@alexis-puska
Copy link
Author

I’m stuck with this version. I look inside the server side dependencies and you downgrade hinernate to 5.3.X... I used hibernate search orm 6 to dissociate hibernate search and elastic search of lucene I need to use hibernate 5.4.X... if I configure the liquibase configuration with that I get conflict with hibernate search 6 annotation in my domain.

All issue with this plugins comes with the update of spring boot 2.1.X to spring boot 2.2.X. I think they change something in class loader to retrieve the hibernate session. @liquibase I think I’m not the only one with this problem and they look like recursive problem at every spring boot major version.

@pavankjadda
Copy link

@DanielFran It looks like the @liquibase team is not actively responding to the issues. It's better to switch to https://flywaydb.org/

@alexis-puska
Copy link
Author

Flyway can be a good alternative, but in the past i used that, and i don't think that can be the diff schama between spring/javax annotation and the current database schema. At this time liquibase can't create the diff but it can create the database changelog on the current schema. with that we can make all thing that flyway do.

i open a discussion on liquibase forum with this issues, here, and a ticket on her jira, i don't know how many developper works on liquibase at this time. i read that i work's on a major version (4.0.0).

@pavankjadda
Copy link

@alexis-puska Do you have Jira ticket link for me?

@alexis-puska
Copy link
Author

alexis-puska commented Feb 5, 2020

@jgribonvald
Copy link
Contributor

The problems seems related to that: liquibase/liquibase#927

jgribonvald added a commit to GIP-RECIA/esup-publisher that referenced this issue Feb 10, 2020
liquibase-hibernate5.version = 3.6 not updated to 3.8 due to an error on running `./mvnw compile liquibase:diff` that get this error:
"Error setting up or running Liquibase: javax.persistence.PersistenceException: Unable to resolve persistence unit root URL: class path resource [] cannot be resolved to URL because it does not exist"
and seems related to these issue:
liquibase/liquibase-hibernate#222
and possible PR: liquibase/liquibase#927
@alexis-puska
Copy link
Author

I see that the liquibase maven plugins 3.8.7 version is published, tested and approuved

@DanielFran in a jhipster project the 3.8.7 works !

@DanielFran
Copy link
Contributor

@alexis-puska Thanks for information, will update jhipster.

@alexis-puska
Copy link
Author

Probleme solved with PR : liquibase/liquibase#927

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

No branches or pull requests

4 participants