-
Notifications
You must be signed in to change notification settings - Fork 2
feat(lease-read): leader-local lease read for coordinator and engine #549
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
43 commits
Select commit
Hold shift + click to select a range
eb7b34c
docs: lease read design
bootjp 61feb0e
docs(lease-read): bump safety margin to 300ms
bootjp 55d092e
feat(lease-read): add LeaseRead to coordinator and engine surface
bootjp 0d299fb
feat(lease-read): use LeaseRead in Lua scripts and refresh on Dispatch
bootjp fde9540
feat(lease-read): wrap Redis GET and DynamoDB getItem in LeaseRead
bootjp 2a70b72
test(lease-read): unit tests for leaseState
bootjp b9ac2b8
style(lease-read): linter formatting on lease_state_test.go
bootjp f28bf0d
fix(lease-read): pre-Propose time capture and monotonic extend
bootjp f86c689
fix(lease-read): invalidate lease on leader-loss
bootjp 9994bbb
fix(lease-read): per-shard lease refresh on Dispatch via leaseRefresh…
bootjp 5b3ab7c
test(lease-read): coordinator LeaseRead and leader-loss invalidation
bootjp 4f24db6
fix(lease-read): address external review (Copilot/CodeRabbit)
bootjp 6d30563
test(lease-read): amortization end-to-end + design doc closure
bootjp 9c15a89
fix(lease-read): plug invalidate/extend race + fire callbacks on shut…
bootjp 22448db
fix(lease-read): Copilot 2nd-pass nits on PR #549
bootjp 33eef30
docs(lease-read): clarify RegisterLeaderLossCallback does NOT fire on…
bootjp 8d3511f
fix(lease-read): panic-protect leader-loss callbacks + sync.Mutex in …
bootjp 76a93d7
fix(lease-read): only refresh lease when Raft commit actually happened
bootjp f83fed5
fix(lease-read): fire callbacks from fail(), log panic recoveries,
bootjp 571cd93
fix(lease-read): leaseRefreshingTxn forwards Close + unify GET context
bootjp f60d744
style(lease-read): Copilot nits on test busy-loop + comment accuracy
bootjp 90f78f0
docs(lease-read): clarify pre-dispatch sampling is strictly conservative
bootjp b82ba32
fix(lease-read): sample generation BEFORE quorum op (Critical race)
bootjp f3ba1b1
fix(lease-read): deregister API + idempotent Txn wrapping
bootjp 83b4323
fix(lease-read): short-circuit when LeaseDuration <= 0
bootjp 5238eea
fix(lease-read): plug engine callback leak via Coordinate.Close
bootjp b630541
fix(lease-read): correct shard for DynamoDB item lease + redis base ctx
bootjp 2c33582
docs(lease-read): sync API + pseudocode with final signatures
bootjp c2185d1
fix(lease-read): root all Redis handler timeouts in server baseCtx
bootjp 17455da
fix(lease-read): round 13 review pass
bootjp 0f8c28f
style(dynamodb): fix gci alignment of dynamo const block
bootjp cc9a27d
fix(lease-read): DynamoDB schema-gen revalidation + async callback doc
bootjp b94ee7e
fix(lease-read): fast path also checks engine leader state
bootjp d9ca3f6
Potential fix for pull request finding
bootjp 8afa20b
Potential fix for pull request finding
bootjp 1343d19
fix(dynamodb): compare itemKey bytes (not just generation) after lease
bootjp 93377bf
fix(lease-read): zero tail before truncating leaderLossCbs slice
bootjp 5c5a820
fix(dynamodb): defer leaseCancel for panic-safety
bootjp f9265bf
refactor(lease-read): make lease read an optional Coordinator capability
bootjp 9cea2a8
perf(lease-read): make AppliedIndex lock-free via atomic.Uint64
bootjp b70f167
revert(lease-read): fire leader-loss callbacks synchronously
bootjp d1d255f
Potential fix for pull request finding
bootjp c087a7c
fix(lease-read): pin readTS in DynamoDB getItem + sync doc for leader…
bootjp File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The schema and item key are re-resolved here to detect routing changes during the lease check. While safe, resolveGetItemTarget involves loading the table schema, which may be expensive if not perfectly cached. Since schemas change rarely, consider if a simpler check (e.g., comparing schema generations) would be sufficient to detect shifts in item routing.