gpt4 book ai didi

hibernate - Spring Boot 出现 JDBCConnectionException "Unable to acquire JDBC Connection"

转载 作者:行者123 更新时间:2023-12-03 06:48:14 31 4
gpt4 key购买 nike

当我使用 Japser 报告生成报告时,我的 Spring Boot 工作正常。

我面临的问题是应用程序抛出 hibernate 异常:

Unable to acquire JDBC Connection

多次生成报告后出现此错误。

1 running delayed actions on {type: MASTER, group: null, band: 0}
2018-09-20 14:27:55.536 DEBUG 46148 --- [ XNIO-2 task-27]
n.s.j.engine.fill.JRBaseFiller : Fill 1: ended
2018-09-20 14:27:55.536 DEBUG 46148 --- [ XNIO-2 task-27]
n.s.j.engine.fill.JRFillDataset : Fill 1: closing query executer
2018-09-20 14:27:55.539 DEBUG 46148 --- [ XNIO-2 task-27]
n.s.j.engine.export.JRPdfExporter : glyph renderer block DEVANAGARI
2018-09-20 14:27:55.539 DEBUG 46148 --- [ XNIO-2 task-27]
n.s.j.engine.export.JRPdfExporter : glyph renderer block BENGALI
2018-09-20 14:27:55.539 DEBUG 46148 --- [ XNIO-2 task-27]
n.s.j.engine.export.JRPdfExporter : glyph renderer block TELUGU
2018-09-20 14:27:55.539 DEBUG 46148 --- [ XNIO-2 task-27]
n.s.j.engine.export.JRPdfExporter : glyph renderer block TAMIL
2018-09-20 14:27:55.539 DEBUG 46148 --- [ XNIO-2 task-27]
n.s.j.engine.export.JRPdfExporter : glyph renderer block GUJARATI
2018-09-20 14:27:55.539 DEBUG 46148 --- [ XNIO-2 task-27]
n.s.j.engine.export.JRPdfExporter : glyph renderer block KANNADA
2018-09-20 14:27:55.539 DEBUG 46148 --- [ XNIO-2 task-27]
n.s.j.engine.export.JRPdfExporter : glyph renderer block MALAYALAM
2018-09-20 14:27:55.539 DEBUG 46148 --- [ XNIO-2 task-27]
n.s.j.engine.export.JRPdfExporter : glyph renderer block ORIYA
2018-09-20 14:27:55.539 DEBUG 46148 --- [ XNIO-2 task-27]
n.s.j.engine.export.JRPdfExporter : glyph renderer block GURMUKHI
2018-09-20 14:27:55.539 DEBUG 46148 --- [ XNIO-2 task-27]
n.s.j.engine.export.JRPdfExporter : glyph renderer block SINHALA
2018-09-20 14:27:55.539 DEBUG 46148 --- [ XNIO-2 task-27]
n.s.j.engine.export.JRPdfExporter : glyph renderer block TIBETAN
2018-09-20 14:27:55.539 DEBUG 46148 --- [ XNIO-2 task-27]
n.s.j.engine.export.JRPdfExporter : glyph renderer block KHMER
2018-09-20 14:28:25.549 WARN 46148 --- [ XNIO-2 task-27]
o.h.engine.jdbc.spi.SqlExceptionHelper : SQL Error: 0, SQLState: null
2018-09-20 14:28:25.550 ERROR 46148 --- [ XNIO-2 task-27]
o.h.engine.jdbc.spi.SqlExceptionHelper : HikariPool-1 - Connection is not
available, request timed out after 30000ms.
2018-09-20 14:28:25.556 ERROR 46148 --- [ XNIO-2 task-27]
c.n.xx.aop.logging.LoggingAspect : Exception in
com.xx.xx.web.rest.GrueResource.generateRapportGrue() with cause =
'org.hibernate.exception.JDBCConnectionException: Unable to acquire JDBC
Connection' and exception = 'Could not open JPA EntityManager for
transaction; nested exception is
org.hibernate.exception.JDBCConnectionException: Unable to acquire JDBC
Connection'

org.springframework.transaction.CannotCreateTransactionException: Could not
open JPA EntityManager for transaction; nested exception is
org.hibernate.exception.JDBCConnectionException: Unable to acquire JDBC
Connection

最佳答案

您的连接已用完。

尝试将 Hikari 连接池设置为更大的数字:

spring.datasource.hikari.maximum-pool-size=10

关于hibernate - Spring Boot 出现 JDBCConnectionException "Unable to acquire JDBC Connection",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52426535/

31 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com