Spring EERROR:org.hibernate.tool.hbm2ddl.SchemaExport-HHH000231:架构导出失败

Spring EERROR:org.hibernate.tool.hbm2ddl.SchemaExport-HHH000231:架构导出失败,spring,hibernate,maven,jpa,Spring,Hibernate,Maven,Jpa,我使用Junit4测试代码,在第一行代码中: ApplicationContext context=new ClassPathXmlApplicationContext( 新字符串[]{“applicationContext.xml”})异常是由 未知数据库“appeldoffre” 创建此数据库,异常应消失。我得到了以下信息: INFO:org.springframework.context.support.ClassPathXmlApplicationContext-刷新org.spri

我使用Junit4测试代码,在第一行代码中:

ApplicationContext context=new ClassPathXmlApplicationContext(

新字符串[]{“applicationContext.xml”})异常是由

未知数据库“appeldoffre”

创建此数据库,异常应消失。

我得到了以下信息:

INFO:org.springframework.context.support.ClassPathXmlApplicationContext-刷新org.springframework.context.support。ClassPathXmlApplicationContext@5a39699c:启动日期[Fri Apr 10 11:45:27 WEST 2015];上下文层次结构的根
信息:org.springframework.beans.factory.xml.XmlBeanDefinitionReader-从类路径资源[applicationContext.xml]加载xml bean定义
信息:org.springframework.jdbc.datasource.driverManager数据源-加载的jdbc驱动程序:com.mysql.jdbc.driver
信息:org.springframework.context.support.ClassPathXmlApplicationContext-类型为[class org.springframework.jdbc.dataSource.DriverManager dataSource]的Bean“dataSource”不符合由所有BeanPostProcessor处理的条件(例如:不符合自动代理的条件)
信息:org.springframework.context.support.ClassPathXmlApplicationContext-Bean'org.springframework.orm.jpa.vendor.hibernatejbavendorapter#3cef309d'类型[class org.springframework.orm.jpa.vendor.hibernatejbavendorapter]不符合由所有BeanPostProcessor处理的条件(例如:不符合自动代理的条件)
信息:org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean-为持久化单元“default”构建jpa容器EntityManagerFactory
警告:org.hibernate.ejb.HibernatePersistence-HHH015016:遇到不推荐的javax.persistence.spi.PersistenceProvider[org.hibernate.ejb.HibernatePersistence];改用[org.hibernate.jpa.HibernatePersistenceProvider]。
信息:org.hibernate.jpa.internal.util.LogHelper-hh000204:处理PersistenceUnitInfo[
名称:默认值
...]
信息:org.hibernate.Version-hh000412:hibernate核心{4.3.5.Final}
信息:org.hibernate.cfg.Environment-hh000206:hibernate.properties未找到
信息:org.hibernate.cfg.Environment-hh000021:字节码提供程序名称:javassist
信息:org.hibernate.annotations.common.Version-HCANN000001:hibernate Commons注解{4.0.4.Final}
信息:org.hibernate.dialogue.dialogue-HHH000400:使用方言:org.hibernate.dialogue.mysql5dialogue
信息:org.hibernate.hql.internal.ast.ASTQueryTranslatorFactory-hh000397:使用ASTQueryTranslatorFactory
信息:org.hibernate.search.Version-HSEARCH000034:hibernate search 4.2.0.Final
警告:org.hibernate.search.impl.ConfigContext-HSEARCH000075:未指定配置设置hibernate.search.lucene\u版本,使用lucene\u CURRENT。
信息:org.hibernate.tool.hbm2ddl.SchemaUpdate-HHH000228:运行hbm2ddl架构更新
信息:org.hibernate.tool.hbm2ddl.SchemaUpdate-HHH000102:获取数据库元数据
信息:org.hibernate.tool.hbm2ddl.SchemaUpdate-hh000396:更新架构
信息:org.hibernate.tool.hbm2ddl.SchemaUpdate-hh000232:架构更新完成
信息:org.springframework.context.support.ClassPathXmlApplicationContext-Bean“myEmf”类型[class org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean]不符合由所有BeanPostProcessor处理的条件(例如:不符合自动代理的条件)

信息:org.springframework.beans.factory.support.DefaultListableBeanFactory-在org.springframework.beans.factory.support中预实例化单例。DefaultListableBeanFactory@27f723:定义bean[myEmf,数据源,transactionManager,org.springframework.aop.config.internalAutoProxyCreator,org.springframework.transaction.annotation.AnnotationTransactionAttributeSource#0,org.springframework.transaction.internalTransactionReceptor#0,org.springframework.transaction.config.internalTransactionAdvisor,persistenceExceptionTranslationPostProcessor];工厂层次结构的根目录
异常是由数据源配置引起的,您可以使用其他数据源(BoneCP)。您可以尝试