The following exception is thrown whenever AvailableSettings.HBM2DDL_AUTO property is set to "update" (or "validate") but not when left unset.
Caused by: javax.persistence.PersistenceException: [PersistenceUnit: default] Unable to build Hibernate SessionFactory at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.persistenceException(EntityManagerFactoryBuilderImpl.java:874) at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.build(EntityManagerFactoryBuilderImpl.java:802) at org.hibernate.jpa.HibernatePersistenceProvider.createContainerEntityManagerFactory(HibernatePersistenceProvider.java:152) at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:343) at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:318) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1633) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1570) ... 41 more Caused by: java.lang.ClassCastException: java.util.Collections$EmptyIterator cannot be cast to java.lang.Iterable at org.hibernate.tool.schema.extract.internal.SequenceInformationExtractorNoOpImpl.extractMetadata(SequenceInformationExtractorNoOpImpl.java:45) at org.hibernate.tool.schema.extract.internal.legacy.DatabaseInformationImpl.initializeSequences(DatabaseInformationImpl.java:89) at org.hibernate.tool.schema.extract.internal.legacy.DatabaseInformationImpl.<init>(DatabaseInformationImpl.java:85) at org.hibernate.tool.hbm2ddl.SchemaUpdate.execute(SchemaUpdate.java:136) at org.hibernate.tool.hbm2ddl.SchemaUpdate.execute(SchemaUpdate.java:114) at org.hibernate.internal.SessionFactoryImpl.<init>(SessionFactoryImpl.java:461) at org.hibernate.boot.internal.SessionFactoryBuilderImpl.build(SessionFactoryBuilderImpl.java:462) at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.build(EntityManagerFactoryBuilderImpl.java:799) ... 46 more
|