Closed jkuradobery closed 9 months ago
@jkuradobery Can you show a stacktrace of deadlocked process?
Check please context which you put to db.Table().Do(ctx)
Check please context which you put to db.Table().Do(ctx) I have added logging of the context to the test. Here are unique contexts logged during the test.
WARN persistence/ydb.go:564 Context before ydb do context.Background.WithValue(type logging.loggerKey, val <not Stringer>).WithValue(type ctxlog.ctxKey, val <not Stringer>).WithCancel {"SYSLOG_IDENTIFIER": "disk-manager"} WARN persistence/ydb.go:564 Context before ydb do context.Background.WithValue(type logging.loggerKey, val <not Stringer>).WithValue(type ctxlog.ctxKey, val <not Stringer>).WithCancel.WithCancel {"SYSLOG_IDENTIFIER": "disk-manager"} WARN persistence/ydb.go:564 Context before ydb do context.Background.WithValue(type logging.loggerKey, val <not Stringer>).WithValue(type ctxlog.ctxKey, val <not Stringer>).WithCancel.WithCancel.WithValue(type xcontext.ctxIdempotentKey, val <not Stringer>).WithValue(type xcontext.markRetryCallKey, val <not Stringer>).WithCancel {"SYSLOG_IDENTIFIER": "disk-manager"} WARN persistence/ydb.go:564 Context before ydb do context.Background.WithValue(type logging.loggerKey, val <not Stringer>).WithValue(type ctxlog.ctxKey, val <not Stringer>).WithCancel.WithValue(type xcontext.ctxIdempotentKey, val <not Stringer>).WithValue(type xcontext.markRetryCallKey, val <not Stringer>).WithCancel {"SYSLOG_IDENTIFIER": "disk-manager"}
server.log Uploading more verbose log
ydb version 2.7.0
The problem seems to be solved in the recent ydbd versions.
Bug Report
YDB GO SDK version:
3.54.3
Environment Linux, Ubuntu 22.04. Linux ubuntu 5.15.0-91-generic #101-Ubuntu SMP.
Current behavior:
After the context cancellation on the ydb request execution, the next requests are being timed out. There are timeout message on the ydb server side.
Expected behavior:
YDB server continues to work properly and not freeze requests.
Steps to reproduce:
https://github.com/ydb-platform/nbs/blob/main/cloud/disk_manager/internal/pkg/dataplane/snapshot/storage/storage_ydb_test.go TestShallowCopySnapshotWithRandomFailure, run with ya.make Logs and test profile here: server.log profile007.pdf client.log