| 195 | progress progressState // stall detection state |
| 196 | |
| 197 | // logger carries user+pid for in-session WARN/ERROR. Discarded on |
| 198 | // DestroySession so a hot-idle reuse cannot leak the previous user. |
| 199 | logger *slog.Logger |
| 200 | } |
| 201 | |
| 202 | // QueryHandle stores an ad-hoc query awaiting its DoGet. |
| 203 | type QueryHandle struct { |
| 204 | Query string |
| 205 | Schema *arrow.Schema |
| 206 | TxnID string |
| 207 | createdAt time.Time // when registered; the reaper drops a stale ad-hoc handle whose DoGet never arrived (guarded by Session.mu) |
| 208 | // finishOperation is the session operation token for an ad-hoc query |
| 209 | // awaiting its DoGet. |
| 210 | finishOperation func() |
| 211 | // finishDrain is the drain token of an ad-hoc query awaiting its DoGet. |
| 212 | finishDrain func() |
| 213 | } |
| 214 | |
| 215 | func releaseDrainFunc(release func()) { |
| 216 | if release != nil { |