-
sqle/dsess: NewDetachedSession constructor for registry-owned sessions
发布于
2026-05-19 23:09:28 +00:00 The SessionRegistry from the previous commit needs a way to create a
DoltSession not bound to any specific SQL client connection. The
existing NewDoltSession already accepts any *sql.BaseSession --
including one returned by sql.NewBaseSession() -- but the call site
ended up reading like a workaround.NewDetachedSession wraps NewDoltSession and stamps the intent into the
constructor name: callers that don't have a per-connection
sql.BaseSession (the registry, tests) get a clear API; existing dolt
SQL paths keep using NewDoltSession unchanged.Co-Authored-By: Claude Opus 4.7 (1M context) noreply@anthropic.com
下载附件