From f3de3536686376524404d120a02ce5b0319ea803 Mon Sep 17 00:00:00 2001 From: Aleksei Pleshakov Date: Fri, 20 Dec 2024 17:56:45 +0100 Subject: [PATCH] update session status only after logging it, so we know real status when delete fails --- CHANGELOG.md | 2 ++ internal/table/session.go | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8d18c67fa..1ac33d340 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,5 @@ +* Fixed an error in logging session deletion events + ## v3.95.3 * Supported of `database/sql/driver.Valuer` interfaces for params which passed to query using sql driver * Exposed `credentials/credentials.OAuth2Config` OAuth2 config diff --git a/internal/table/session.go b/internal/table/session.go index 6110e88e3..b69100588 100644 --- a/internal/table/session.go +++ b/internal/table/session.go @@ -193,8 +193,8 @@ func (s *session) Close(ctx context.Context) (err error) { s, ) defer func() { - s.SetStatus(table.SessionClosed) onDone(err) + s.SetStatus(table.SessionClosed) }() if time.Since(s.LastUsage()) < s.config.IdleThreshold() {