Repository navigation
fix(iscp): retry drain while executor initializes - #26183
Conversation
Qodo reviews are paused for this user.Troubleshooting steps vary by plan Learn more → On a Teams plan? Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center? |
@ck89119 please review again |
94f936a to
ff0a3fa
Compare
|
Follow-up safety correction in The in-process dual-copy state is also linearized under one lock order:
New deterministic regressions cover renew-before-initial-drain rejection, active renewal, remove-then-late-renew rejection, stale executor renewal, old-executor re-publication, and pending-executor renewal. Post-rebase validation:
|
XuPeng-SH
left a comment
There was a problem hiding this comment.
Latest-head update from another deep pass: I do not see new blockers beyond the remaining ownership-linearization gap already under discussion, but I also do not see that gap closed on the current head.
The convergence condition is still if _, ok := fencedRunners[runnerCN]; ok { break } after a fresh runner read (pkg/sql/compile/iscp_util.go:359-363). That proves only that the current CN UUID was seen/fenced before; it does not prove that no different runner owned the daemon task in between. The new tests cover A -> B -> B handoff and same-owner revalidation after a long drain (pkg/sql/compile/iscp_util_extra_test.go:560-639, 924-997), but they still do not cover A -> B -> A. A transient B owner can still admit a consumer because fences are CN-scoped and an already-running consumer is only canceled on a later failed lease check, not immediately on ownership change (pkg/iscp/executor.go:516-523, pkg/iscp/iteration.go:517-539).
So my latest-head conclusion is: the renew/remove/generation fixes look good, but the drain loop still lacks a true ownership linearization point / terminal quiescence proof.
Summary
Fixes #26181.
Validation
.agents/skills/mo-dev/scripts/mo-cgo-test -race -count=1 -timeout=600s ./pkg/cnservice ./pkg/sql/compileGOWORK=off go build -mod=readonly ./pkg/cnservice ./pkg/sql/compileGOWORK=off go vet -mod=readonly ./pkg/cnservice ./pkg/sql/compile