diff --git a/nebula3/gclient/net/SessionPool.py b/nebula3/gclient/net/SessionPool.py index c3ad435c..658b2599 100644 --- a/nebula3/gclient/net/SessionPool.py +++ b/nebula3/gclient/net/SessionPool.py @@ -456,8 +456,9 @@ def _remove_idle_unusable_session(self): # release idle session and remove from the pool if idle_time > self._configs.idle_time: + conn = session._connection session.release() - session._connection.close() + conn.close() self._idle_sessions.remove(session) def _period_detect(self):