feat(incrservice): add transactional offset resets#26085
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? |
a9e51c5 to
ccb4d81
Compare
ccb4d81 to
acf8a23
Compare
75b265e to
5dfb480
Compare
5dfb480 to
28d8664
Compare
28d8664 to
891781d
Compare
Merge Queue Status
This pull request spent 2 hours 52 minutes 48 seconds in the queue, including 1 hour 8 minutes 19 seconds running CI. Required conditions to merge
|
gouhongshen
left a comment
There was a problem hiding this comment.
Codex automated review
No findings. The prior lifecycle and memStore transactionality findings are fixed on this head. The epoch/private-cache transitions, rollback/commit cleanup, allocator shutdown, callers, and boundary handling are consistent. Diff/format checks and moerr tests passed; the incrservice race suite could not run because the required local libmo.dylib artifact is absent.
What type of PR is this?
Which issue(s) this PR fixes:
issue #23143
What this PR does / why we need it:
This is the next prerequisite after #26027. It does not expose
ALTER TABLE ... AUTO_INCREMENT=Nyet.The invariant in this PR is that an AUTO_INCREMENT offset reset and its allocator-cache transition belong to the same transaction:
The shared service interface now carries
autoIncrEpochandTxnOperatorthrough both production allocation callers.memStoreandsqlStoregain monotonicSetOffsetplus DDL-constrainedForceSetOffset; all implementations and mocks are updated atomically.Out of scope for this PR:
Diff size, separated for reviewability:
+1303 / -86+1832 / -8+292 / -18Validation:
go test -race ./pkg/incrservice -count=1go test ./pkg/sql/colexec/preinsert ./pkg/sql/colexec/table_clone ./pkg/frontend/test ./pkg/vm/engine/test/testutil -count=1go test ./pkg/... -run '^$'git diff --checkmo-pr-preflight-review: PASS at891781d3a927b80b54d38e381ebee0d749c1c589