Skip to content

Release RAM-backed splits after serialization - #6904

Open
PSeitz wants to merge 1 commit into
quickwit-oss:mainfrom
PSeitz:fix/release-ram-after-serialization
Open

PSeitz wants to merge 1 commit into
quickwit-oss:mainfrom
PSeitz:fix/release-ram-after-serialization

Conversation

@PSeitz

@PSeitz PSeitz commented Oct 14, 2026

Copy link
Copy Markdown
Collaborator

Summary

With in-memory indexing enabled, persisting a split copies its files to disk but leaves the returned Tantivy Index owning the RAM directory. This keeps the RAM files alive through packaging.

Reopen the persisted split from disk so the original RAM owners drop before the finalized split reaches the packager.

Changes

  • Return a disk-backed Index through the existing ControlledDirectory.
  • Explain when the builder's RAM handle and the shadowed original Index drop.
  • Add one ownership regression test and one integration smoke test for in-memory ingestion through publication and search. The integration test sets the cached environment flag in a child process, without modifying other tests' environment.

User impact

Shorter RAM retention when QW_ENABLE_IN_MEMORY_INDEXING=true.

Verification

  • Indexing library tests plus the new integration test: 234 passed. Other integration tests and the existing ignored indexing test were not run.
  • make fmt and git diff --check passed.
  • No production memory benchmark performed.
cargo nextest run --locked --offline \
  -p quickwit-integration-tests -p quickwit-indexing --lib \
  -E 'package(quickwit-indexing) | test(in_memory_indexing_tests)'

@PSeitz
PSeitz requested a review from a team as a code owner October 14, 2026 09:48
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 14, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-14T09:53:26.014630Z 1ca42ca PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant