相关疑难解决方法(0)

无法加载驱动程序类:com.mysql.jdbc.Driver Spring

spring.freemarker.cache:false


spring.datasource.url=jdbc:mysql://localhost/mydb
spring.datasource.username=user
spring.datasource.password=pass
spring.datasource.driver-class-name=com.mysql.jdbc.Driver
Run Code Online (Sandbox Code Playgroud)

我甚至在驱动程序类名称的情况下得到此错误

java.lang.IllegalStateException:无法加载驱动程序类:com.mysql.jdbc.Driver at org.springframework.util.Assert.state(Assert.java:392)〜[spring-core-4.2.1.RELEASE.jar:4.2 .1.RELEASE] org.springframework.boot.autoconfigure.jdbc.DataSourceProperties.getDriverClassName(DataSourceProperties.java:153)〜[spring-boot-autoconfigure-1.3.0.M5.jar:1.3.0.M5] at org .springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration $ NonEmbeddedConfiguration.dataSource(DataSourceAutoConfiguration.java:119)〜[spring-boot-autoconfigure-1.3.0.M5.jar:1.3.0.M5] at sun.reflect.NativeMethodAccessorImpl. invoke0(Native Method)〜[na:1.8.0_60] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)〜[na:1.8.0_60] at ......

它继续下去

spring

29
推荐指数
4
解决办法
5万
查看次数

标签 统计

spring ×1