Spring Boot 集成bug异常汇总

Spring Boot 集成bug异常汇总

  • Spring Boot 集成bug异常汇总
    • mybatis plus java.lang.AbstractMethodError: null
    • java.sql.SQLException: The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized

Spring Boot 集成bug异常汇总

你好! 这是你第一次使用 Markdown编辑器 所展示的欢迎页。如果你想学习如何使用Markdown编辑器, 可以仔细阅读这篇文章,了解一下Markdown的基本语法知识。

mybatis plus java.lang.AbstractMethodError: null

找到github官方地址:
https://github.com/baomidou/mybatis-plus-samples

查看pom.xml
https://github.com/baomidou/mybatis-plus-samples/blob/master/pom.xml

找到Spring Boot parent配置:使用以下的version

    <parent>
        <groupId>org.springframework.bootgroupId>
        <artifactId>spring-boot-starter-parentartifactId>
        <version>2.1.3.RELEASEversion>
        <relativePath/> 
    parent>

java.sql.SQLException: The server time zone value ‘Öйú±ê׼ʱ¼ä’ is unrecognized

异常全部:
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.

配置中jdbc连接符需要添加时区配置 serverTimezone=GMT%2B8

spring:
  application:
    name: service-goods
  datasource:
    username: root
    password: root
    driver-class-name: com.mysql.jdbc.Driver
    url: jdbc:mysql://localhost:3306/mall?characterEncoding=utf8&useSSL=false&serverTimezone=GMT%2B8

你可能感兴趣的:(后端)