samedi 11 avril 2015

Liquibase Hibernate Java 8 support

I hope someone had the same problem before, and asking here is quicker than the trial and error.


I have a Java 8 project, where I am trying to use Liquibase, and generate my changelog from my Entities:



liquibase --changeLogFile=changeLog.yaml
--url=hibernate:spring:com.example.domain?dialect=org.hibernate.dialect.MySQL5InnoDBDialect
--logLevel=debug generateChangeLog


I got the following error:



SEVERE 11/04/15 09:55: liquibase: Failed to scan classpath for unlisted classes
liquibase.exception.DatabaseException: javax.persistence.PersistenceException: Failed to scan classpath for unlisted classes
...
Caused by: org.springframework.core.NestedIOException: ASM ClassReader failed to parse class file - probably due to a new Java class file version that isn't supported yet: file [.../Example.class]; ...


I compiled my project using Java 7, and liquibase works fine.


Liquibase Version: 3.3.2

Liquibase Hibernate4.2 Version: 3.5


As liquibase is open source, I can try and rebuild it using Java 8, but I have no idea if it will help.


Aucun commentaire:

Enregistrer un commentaire