一种是直接加进URL中,在UTC后面加上&useInformationSchema=true
<jdbcConnection connectionURL="jdbc:mysql://localhost:3306/news?userSSL=false&serverTimezone=UTC&useInformationSchema=true" driverClass="com.mysql.cj.jdbc.Driver" password="root" userId="root" />
一种是打断jdbcConnection / 生成结尾,在jdbcConnection 标签中写
<property name="useInformationSchema" value="true"/>
<jdbcConnection connectionURL="jdbc:mysql://localhost:3306/news?userSSL=false&serverTimezone=UTC" driverClass="com.mysql.cj.jdbc.Driver" password="root" userId="root" >
<property name="useInformationSchema" value="true"/>
</jdbcConnection>