Skip to content

[Improvement] Prevent stale Lance schema repair from overwriting newer metadata #12957

Description

@yuqi1129

What would you like to be improved?

Schema repair can capture dataset version 8, then overwrite metadata already updated to version 9 with the older schema/version. Metadata-store CAS does not validate the earlier dataset observation.

Parent: #9087. Follow-up from the review of #12954.

How should we improve?

Validate the observed table identity, location, and version before applying repair. Re-read when they change or a concurrency conflict occurs instead of replaying stale state. A version-only comparison is insufficient across replacement or location changes.

Add a deterministic regression test for the version-8/version-9 interleaving, replacement/location changes, and concurrent repair. Include integration coverage that verifies reads cannot persist stale schema metadata.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    improvementImprovements on everything

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions