Skip to content

test: release disk cache read vectors - #33065

Merged
XuPeng-SH merged 1 commit into
matrixorigin:mainfrom
XuPeng-SH:fix/ci-fileservice-readrange-release
Nov 22, 2026
Merged

XuPeng-SH merged 1 commit into
matrixorigin:mainfrom
XuPeng-SH:fix/ci-fileservice-readrange-release

Conversation

@XuPeng-SH

Copy link
Copy Markdown
Contributor

What type of PR is this?

  • API-change
  • Test and CI
  • BUG
  • Improvement
  • Documentation
  • Feature
  • Code Refactoring

Which issue(s) this PR fixes:

Related to #32745

What this PR does / why we need it:

The main UT job failed with a checked-allocator missing free while TestPreloadUsageObjectsAreBounded was running. The allocation came from an earlier successful disk-cache readRange test read: its IOVector was never released, so a later garbage collection reported the leak against whichever test happened to be active.

Make the test fixture own each read: cancel and join its reader before releasing the vector exactly once. Release the other locally owned read vectors and cover the case where the test exits with an unconsumed pending read. This changes test cleanup only.

Validation

  • Reproduced the same 5-byte checked-allocator panic and allocation stack on the clean main test with MO_MALLOC_DEBUG=1, GOGC=10, and -race.
  • Ran the affected download/read/preload tests 20 times under -race with checked allocation and aggressive GC, including the pending-read cleanup witness.
  • Ran the complete pkg/fileservice package with -race; the repository SCA selector chose that package alone (1/503), and its pinned molint, golangci-lint and go vet checks passed.
  • Independent gpt-6.2-astra/high design and gpt-6.2-sol/xhigh review.

@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 22, 2026 •

Copy link
Copy Markdown
Contributor

This pull request is merged.

@XuPeng-SH
XuPeng-SH merged commit d8eea40 into matrixorigin:main Nov 22, 2026

This branch was successfully deployed

No deployments
ci — 90cac257 Deployed Nov 22, 2026 by XuPeng-SH
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/test-ci size/S Denotes a PR that changes [10,99] lines

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants