Skip to content

fix(blob): require explicit opt-in for managed storage - #9891

Merged
jackye1995 merged 5 commits into
lance-format:mainfrom
jackye1995:codex/managed-blobs-opt-in
Oct 12, 2026
Merged

jackye1995 merged 5 commits into
lance-format:mainfrom
jackye1995:codex/managed-blobs-opt-in

Conversation

@jackye1995

@jackye1995 jackye1995 commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

Ordinary Blob V2 writes currently activate FLAG_MANAGED_BLOBS and require newer readers, even when callers never requested managed storage. Keep default writes and compaction on Inline/Packed/Dedicated descriptors, and require explicit schema metadata lance.blob.managed=true for managed storage and sidecar reuse. Committing the opt-in activates the sticky reader/writer fence immediately, protecting in-flight writes even if later commits remove the metadata. Reject prepared managed descriptors without the opt-in.

Deep clones preserve existing managed references even after the source disables or removes its opt-in. The clone rewrite uses a temporary writer opt-in while preserving the dataset's schema metadata and sticky fence, and copies/rebinds registered Packed/Dedicated sidecars in mixed snapshots. Add regression coverage for default writes/compaction, prepared descriptor rejection, clone/cleanup lifecycle, and released-client compatibility.

Managed blobs first shipped in v14.0.0-beta.4; no stable Lance release contains them. Verified that the latest stable v13.0.0 tag and published lance-table crate lack the flag. Existing beta-written flagged datasets retain their fence.

Rust formatting and pre-commit checks pass. Local builds, tests, clippy, and the full Python lint workflow are skipped at the user's request; Python setup requires compiling the local extension.

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Claude Code Review

This pull request is from a fork — automated review is disabled. A repository maintainer can comment @claude review to run a one-time review.

@github-actions github-actions Bot added A-python Python bindings bug Something isn't working labels Oct 12, 2026
lance-gatekeeper[bot]

This comment was marked as outdated.

@lance-gatekeeper lance-gatekeeper Bot added K-approved Latest Gatekeeper recommendation permits acceptance. K-risk Latest Gatekeeper recommendation includes a non-blocking risk. labels Oct 12, 2026
@lance-gatekeeper lance-gatekeeper Bot removed K-risk Latest Gatekeeper recommendation includes a non-blocking risk. K-approved Latest Gatekeeper recommendation permits acceptance. labels Oct 12, 2026
lance-gatekeeper[bot]

This comment was marked as outdated.

@lance-gatekeeper lance-gatekeeper Bot added the K-approved Latest Gatekeeper recommendation permits acceptance. label Oct 12, 2026
@lance-gatekeeper lance-gatekeeper Bot removed the K-approved Latest Gatekeeper recommendation permits acceptance. label Oct 12, 2026

@lance-gatekeeper lance-gatekeeper Bot 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.

✅ Gate recommendation: approve.

The earlier clone limitation remains fixed, including snapshots with mixed Managed and registered Packed/Dedicated sidecars after the opt-in is disabled or removed. Ordinary writes retain the released storage layout, and clones preserve the source schema metadata and sticky capability fence.

@lance-gatekeeper lance-gatekeeper Bot added the K-approved Latest Gatekeeper recommendation permits acceptance. label Oct 12, 2026
@jackye1995
jackye1995 merged commit e63f8cb into lance-format:main Oct 12, 2026
hamersaw added a commit to lancedb/lancedb that referenced this pull request Oct 13, 2026
Lance v14.0.0-beta.15 (lance-format/lance#9891) only writes Managed blob
descriptors when the schema opts in, so default refresh output now uses
Dedicated/Packed layouts per the column's size thresholds.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Xuanwo added a commit that referenced this pull request Oct 23, 2026
Blob v2's logical input, physical descriptors, object resolution, and
lifetime rules are spread across the implementation and user guide. This
spec brings those contracts together, distinguishing the table's logical
schema from the data file's descriptor schema and defining ownership
through rewrites, cleanup, and cloning.

The spec reflects the Managed implementation merged in #9293 and the
explicit opt-in added in #9891. Kind 4 uses the data file's implicit
base; kind 5 carries a registered base ID. Ordinary writes retain
Inline/Packed/Dedicated placement. Enabling `lance.blob.managed=true`
activates the paired sticky capability flags and requires all
maintenance clients to support Managed storage, including clients using
cached or historical handles.

This PR documents existing behavior and adds documentation links; it
contains no runtime implementation changes.

Closes #9014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-python Python bindings bug Something isn't working K-approved Latest Gatekeeper recommendation permits acceptance.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants