在搭建maven项目测试时,报The server time zone value '�й���ʱ��' is unrecognized or represents more than one time zone. 错误
解决办法:
在config.properties配置文件中对于MySQL的URL后面加上时区配置
serverTimezone=Asia/Shanghai
config.properties
jdbc.driverClassName=com.mysql.jdbc.Driver jdbc.url=jdbc:mysql://localhost:3306/alice?serverTimezone=Asia/Shanghai&useSSL=false&useUnicode=true&characterEncoding=utf8 jdbc.username=root jdbc.password=****