spring cloud抛了一个错误:
java.sql.SQLException: The server time zone value ‘�й���ʱ��’ is unrecognized or represents more…
ERROR o.a.tomcat.jdbc.pool.ConnectionPool - Unable to create initial connections of pool.
ERROR o.a.tomcat.jdbc.pool.ConnectionPool - Unable to create initial connections of pool.
java.sql.SQLException: The server time zone value '�й���ʱ��' 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.
在配置datasource.url时不能简单的配,需要加上一些必要的信息:
spring:
datasource:
url: jdbc:mysql://localhost:3306/eesy?useUnicode=true&useJDBCCompliantTimezoneShift=true&useLegacyDatetimeCode=false&serverTimezone=UTC