簡體   English   中英

Caused by: java.lang.RuntimeException: Driver com.mysql.cj.jdbc.Driver claims to not accept jdbcUrl

[英]Caused by: java.lang.RuntimeException: Driver com.mysql.cj.jdbc.Driver claims to not accept jdbcUrl

無法弄清楚導致問題的原因。

我的 application.properties 文件

    spring.datasource.url = "jdbc:mysql://localhost:3306/Medical_Tracking?useSSL=false"
    spring.datasource.username=root
    spring.datasource.password=root
    spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
    spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL5InnoDBDialect
    spring.jpa.show-sql=true
    spring.jpa.hibernate.ddl-auto=update
    spring.jpa.generate-ddl=true

快速幫助表示贊賞

your config spring.datasource.url should not use "", use spring.datasource.url = jdbc:mysql://localhost:3306/Medical_Tracking?useSSL=false instead

嘗試在 applications.properties 文件中進行以下更改:

代替

 spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver

spring.datasource.driverClassName=com.mysql.cj.jdbc.Driver

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM