Skip to content

[4.2-dev] fix: bound lock backend retry waits - #32843

Merged
mergify[bot] merged 1 commit into
matrixorigin:4.2-devfrom
Ariznawlll:codex/issue-32834-lock-retry-42
Nov 17, 2026
Merged

mergify[bot] merged 1 commit into
matrixorigin:4.2-devfrom
Ariznawlll:codex/issue-32834-lock-retry-42

Conversation

@Ariznawlll

Copy link
Copy Markdown
Collaborator

What type of PR is this?

  • BUG
  • Test and CI

Which issue(s) this PR fixes:

Related to #32834. This PR addresses a demonstrated backend-wait budget gap; the incident's per-transaction root cause is not yet confirmed.

What this PR does / why we need it:

  • Propagate the established lock retry deadline as backend-availability metadata, and use it to bound MORPC backend selection, connection-creation waits, and retry backoff.
  • Bound allocator bind refresh by the same deadline. Keep the caller's cancellation/deadline and healthy backend request context intact, so an ordinary lock wait is not shortened to the backend retry budget.
  • Add focused tests for blocked backend creation, parent cancellation, healthy backend waits, nested budgets, bind refresh, and lock retry behavior.

Validation

  • On 4.2-dev at fc6c7fee10f14591dd60fd6b35464b6361d8ab42, a focused mock test failed before the change by reaching its 1-second outer deadline instead of the 50 ms backend budget.
  • On the same base with this patch, focused MORPC, lockservice and lockop tests passed 10 repetitions; their focused race tests passed 3 repetitions; the complete lockop package passed once.
  • After fast-forwarding to e8fd84b331f168eafd0ec28149b043eaebc7e39d (an unrelated checkpoint-test update), the same focused three-package tests passed again once. Full MORPC suite was not run because some tests delete shared fixed /tmp paths.
  • Not yet validated: a controlled 2-CN failure/recovery test, no-fault control, transaction cleanup and atomicity, and the original incident's transaction-specific blocked frame. The code change is targeted at the observed plausible wait path; it does not establish that every post-dispatch wait is bounded by the backend budget.

@qodo-code-review

Copy link
Copy Markdown

Qodo reviews are paused for this user.

Troubleshooting steps vary by plan Learn more →

On a Teams plan?
Reviews resume once this user has a paid seat and their Git account is linked in Qodo.
Link Git account →

Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center?
These require an Enterprise plan - Contact us
Contact us →

@mergify

mergify Bot commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

Queue requested — the merge queue status continues in this comment ↓.

@XuPeng-SH

XuPeng-SH commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

mo-bot review · mo-bot-local · done

Commit: 77c345bb85a0eead3f924b97b8e4c053b03d7c7d

Review completed. Read the assessment.

@XuPeng-SH XuPeng-SH left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mo-bot review · mo-bot-local · review

Commit: 77c345bb85a0eead3f924b97b8e4c053b03d7c7d

Assessment: approve

The scoped fix bounds backend-availability waits while preserving healthy lock-request deadlines and existing error/cleanup semantics. It reuses the established retry and context machinery. No actionable defects found.

Model: gpt-6.1-sol / max

Session: 01a1e395-a6d9-7ad1-bf20-81f1c6210100 · slot 2 · generation 0

Validation:

  • Reviewed all seven changed files, affected owners and consumers, linked issue, and all three discussion entries; retained review records and discussion assessment.

  • An isolated probe of the exact new context helper passed normally and under race instrumentation, including 100 repetitions. Receipts: 1794901236494673193-2.json and 1794901235643421692-2.json. These are helper-only checks.

  • The supplied CI snapshot reports successful build, UT, static analysis, coverage, compose/proxy BVT and multi-CN pessimistic BVT.

  • Isolation preflight, git diff --check, and source/discussion/provenance/receipt audit passed. Final audit: checks/1794901494819669604-2.json and source-audit-v2.log.

Limitations:

  • Local affected-package execution could not start because dependency downloads timed out. Detailed CI test selection and race mode were unavailable; no local MORPC, lockservice or lockop package pass is claimed.

  • Controlled CN-failure recovery and transaction atomicity were not validated. The original incident's root cause remains unconfirmed; approval covers this narrower wait-budget fix.

@mergify mergify Bot added the queued label Nov 17, 2026
@mergify
mergify Bot merged commit 2cf8201 into matrixorigin:4.2-dev Nov 17, 2026
@mergify

mergify Bot commented Nov 17, 2026

Copy link
Copy Markdown
Contributor

✅ Merged into 4.2-dev as 2cf8201 at 07:47 UTC

Less than a minute in the queue, with no time running CI.

So far

  • ✅ Entered the queue Tue 17 Nov, 07:47 · rule release-4.2 · triggered by rule Automatic queue on approval for release-4.2
  • ✅ Checks skipped · PR is already up-to-date
  • ✅ Merged 07:47 · 2cf8201 · squash
3 merge conditions met
  • #review-threads-unresolved = 0 · required by GitHub branch protection
  • github-review-approved · required by GitHub branch protection
  • any of · required by GitHub branch protection:
    • check-success = CI Required
    • check-neutral = CI Required
    • check-skipped = CI Required

Times in UTC · dashboard · how the merge queue works

This branch was previously deployed

1 inactive deployment
ci — 77c345bb Deployed Nov 17, 2026 by Ariznawlll
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/bug Something isn't working kind/test-ci size/M Denotes a PR that changes [100,499] lines

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants