久々のSpringBoot バージョン は、2.3.1
mybatis-spring-boot-starter Version : 2.1.3 を使い、
mysql-connector-java Version: 8.2.20 を使って、MySQL に接続する。
Spring の アプリケーション起動していきなり、
java.sql.SQLException: The server time zone value '���� (�W����)' is unrecognized or represents more than one time zone.
You must configure either the server or JDBC driver (via the 'serverTimezone' configuration property)
to use a more specifc time zone value if you want to utilize time zone support.
サーバタイムゾーンを接続情報として接続せよ?
mysql-connector-java のバージョンの影響かな?
解決するために、application.yml の設定、
JDBC url で、serverTimezone を書く。
spring: datasource: driver-class-name: com.mysql.cj.jdbc.Driver url: jdbc:mysql://127.0.0.1:3306/testDB?serverTimezone=JST username: root password: xxxxxxxxxxx