Spring Boot和Google SQL

我正在使用springboot和本指南https://github.com/GoogleCloudPlatform/cloud-sql-mysql-socket-factory。 本指南帮助我生成我的jdbc网址。 我在我的spring启动应用程序中使用了这个jdbc网址,但它总是带来错误:

org.springframework.beans.factory.BeanCreationException:在类路径资源[org / springframework / boot / autoconfigure / orm / jpa / HibernateJpaAutoConfiguration.class]中定义名称为'entityManagerFactory'的bean时出错:init方法的调用失败; 嵌套的异常是在java.lang.AbstractMethodError org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1628)〜[弹簧豆-4.3.7.RELEASE.jar:4.3.7.RELEASE]在org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:555)〜[弹簧豆-4.3.7.RELEASE.jar:4.3.7.RELEASE]在org.springframework.beans.factory.support .AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:483)〜[弹簧豆-4.3.7.RELEASE.jar:4.3.7.RELEASE]在org.springframework.beans.factory.support.AbstractBeanFactory $ 1.getObject(AbstractBeanFactory.java :306)〜[spring-beans-4.3.7.RELEASE.jar:4.3.7.RELEASE] at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)〜[spring-beans- 4.3.7.RELEASE.jar:4.3.7.RELEASE]在org.springframework.beans.factory.support.AbstractBeanFacto ry.doGetBean(AbstractBeanFactory.java:302)〜[spring-beans-4.3.7.RELEASE.jar:4.3.7.RELEASE] at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197 )〜[spring-beans-4.3.7.RELEASE.jar:4.3.7.RELEASE] at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:1081)〜[spring-context-4.3.7。 RELEASE.jar:4.3.7.RELEASE] at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:856)〜[spring-context-4.3.7.RELEASE.jar:4.3.7.RELEASE] at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:542)〜[spring-context-4.3.7.RELEASE.jar:4.3.7.RELEASE] at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext .refresh(EmbeddedWebApplicationContext.java:122)〜[spring-boot-1.5.2.RELEASE.jar:1.5.2.RELEASE] at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:737 )[spring-boot-1.5.2.RELEASE.jar:1.5.2.RELEASE] at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:370)[spring-boot-1.5.2.RELEASE.jar: 1.5.2.RELEASE]在org.springframework.boot.SpringApplication.run(SpringApplication.java:314)[spring-boot-1.5.2.RELEASE.jar:1.5.2.RELEASE] at org.springframework.boot.SpringApplication .run(SpringApplication.java:1162)[spring-boot-1.5.2.RELEASE.jar:1.5.2.RELEASE] at org.springframework.boot.SpringApplication.run(SpringApplication.java:1151)[spring-boot- 1.5.2.RELEASE.jar:1.5.2.RELEASE] at com.example.DemoApplication.main(DemoApplication.java:10)[classes /:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)〜[na :1.8.0_111]在sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)〜[NA:1.8.0_111]在sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)〜[NA:1.8.0_111 ]在org.springframew的java.lang.reflect.Method.invoke(Method.java:498)〜[na:1.8.0_111] ork.boot.devtools.restart.RestartLauncher.run(RestartLauncher.java:49)[spring-boot-devtools-1.5.2.RELEASE.jar:1.5.2.RELEASE]引发:java.lang.AbstractMethodError:null at org.hibernate.internal.SessionFactoryImpl。(SessionFactoryImpl.java:280)〜[hibernate-core-5.0.12.Final.jar:5.0.12.Final] at org.hibernate.boot.internal.SessionFactoryBuilderImpl.build(SessionFactoryBuilderImpl。 java:444)〜[hibernate-core-5.0.12.Final.jar:5.0.12.Final] at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.build(EntityManagerFactoryBuilderImpl.java:879)〜[hibernate-entitymanager -5.0.12.Final.jar:5.0.12.Final]在org.springframework.orm.jpa.vendor.SpringHibernateJpaPersistenceProvider.createContainerEntityManagerFactory(SpringHibernateJpaPersistenceProvider.java:60)〜[弹簧ORM-4.3.7.RELEASE.jar: 4.3.7.RELEASE]在org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:353)〜[spring-orm-4.3.7.RELEASE.j ar:4.3.7.RELEASE] at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.buildNativeEntityManagerFactory(AbstractEntityManagerFactoryBean.java:370)〜[spring-orm-4.3.7.RELEASE.jar:4.3.7.RELEASE] at org。 springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:359)〜[spring-orm-4.3.7.RELEASE.jar:4.3.7.RELEASE] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods (AbstractAutowireCapableBeanFactory.java:1687)〜[弹簧豆-4.3.7.RELEASE.jar:4.3.7.RELEASE]在org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1624)〜[ spring-beans-4.3.7.RELEASE.jar:4.3.7.RELEASE] ...省略了21个常用框架

请帮助我感谢所有

application.properties

链接地址: http://www.djcxy.com/p/60299.html

上一篇: Spring Boot and Google SQL

下一篇: Spring Transaction Management using aspectj