From b9fbd915713be9549b762fba611f53e867816a57 Mon Sep 17 00:00:00 2001 From: hieplq Date: Fri, 26 Jan 2024 20:44:57 +0700 Subject: [PATCH] IDEMPIERE-6016:trx timeout make leak connection by call Connection.about but not call Connection.close (#2210) --- org.adempiere.base/src/org/compiere/util/Trx.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/org.adempiere.base/src/org/compiere/util/Trx.java b/org.adempiere.base/src/org/compiere/util/Trx.java index 3a284b1592..f4402b26a2 100644 --- a/org.adempiere.base/src/org/compiere/util/Trx.java +++ b/org.adempiere.base/src/org/compiere/util/Trx.java @@ -479,7 +479,10 @@ public class Trx // Close Connection try { + // Closes any physical connection to the database m_connection.abort(Runnable::run); + // return to pool manage (pool will validate and re-connect to database) + m_connection.close(); m_connection = null; m_active = false; fireAfterCloseEvent();