Spring Boot Jhipster Connection com.mysql.cj.jdbc.ConnectionImpl@48627c4f由于SQLSTATE(08003),ErrorCode(0)被标记为损坏

时间:2020-04-19 07:20:22

标签: mysql spring spring-boot hikaricp

今天,我更新了Maven。运行应用程序和异常后:

我尝试在Google上搜索。但是结果并不令人满意。

我花了很多时间。请帮助我处理此错误。非常感谢

[2m2020-04-19 14:10:39.393[0;39m [33m WARN[0;39m [35m5138[0;39m [2m---[0;39m [2m[lassroom-task-1][0;39m [36mcom.zaxxer.hikari.pool.ProxyConnection  [0;39m [2m:[0;39m Hikari - Connection com.mysql.cj.jdbc.ConnectionImpl@48627c4f marked as broken because of SQLSTATE(08003), ErrorCode(0)

java.sql.SQLNonTransientConnectionException: No operations allowed after connection closed.
    at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:110)
    at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:97)
    at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:89)
    at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:63)
    at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:73)
    at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:73)
    at com.mysql.cj.jdbc.ConnectionImpl.rollback(ConnectionImpl.java:1857)
    at com.zaxxer.hikari.pool.ProxyConnection.rollback(ProxyConnection.java:370)
    at com.zaxxer.hikari.pool.HikariProxyConnection.rollback(HikariProxyConnection.java)
    at liquibase.database.jvm.JdbcConnection.rollback(JdbcConnection.java:336)
    at liquibase.database.AbstractJdbcDatabase.rollback(AbstractJdbcDatabase.java:1114)
    at liquibase.lockservice.StandardLockService.acquireLock(StandardLockService.java:245)
    at liquibase.lockservice.StandardLockService.waitForLock(StandardLockService.java:207)
    at liquibase.Liquibase.update(Liquibase.java:184)
    at liquibase.Liquibase.update(Liquibase.java:179)
    at liquibase.integration.spring.SpringLiquibase.performUpdate(SpringLiquibase.java:353)
    at liquibase.integration.spring.SpringLiquibase.afterPropertiesSet(SpringLiquibase.java:305

aplication-dev.yml

datasource:
    type: com.zaxxer.hikari.HikariDataSource
    url: jdbc:mysql://localhost:3306/kmaclassroom?useUnicode=true&characterEncoding=utf8&useSSL=false&useLegacyDatetimeCode=false&serverTimezone=Asia/Ho_Chi_Minh&createDatabaseIfNotExist=true
    username: root
    password:
    hikari:
      poolName: Hikari
      idleTimeout: 600000
      maxLifetime: 1800000
      auto-commit: false
      data-source-properties:
        cachePrepStmts: true
        prepStmtCacheSize: 250
        prepStmtCacheSqlLimit: 2048
        useServerPrepStmts: true
  jpa:
    database-platform: org.hibernate.dialect.MySQL8Dialect
    database: MYSQL
    show-sql: true
    properties:
      hibernate.id.new_generator_mappings: true
      hibernate.connection.provider_disables_autocommit: true
      hibernate.cache.use_second_level_cache: true
      hibernate.cache.use_query_cache: false
      hibernate.generate_statistics: false

0 个答案:

没有答案