Skip to content

Preview time travel throws on a manual-only tag group and fails to resolve a valid auto tag #10283

Description

@LuciferYang

Search before asking

  • I searched in the issues and found no similar issues.

Paimon version

master (1.5-SNAPSHOT)

Compute Engine

Any engine using tag preview time travel (auto-tag WATERMARK / PROCESS_TIME mode).

Minimal reproduce step

  1. A table with tag auto-creation in preview mode and at least one manually created tag.
  2. Do a preview time travel whose target is resolved by the tags() fallback (i.e. tagExists misses and the live-snapshot traversal misses, so it falls to scanning all tagged snapshots).

What doesn't meet your expectations?

TagPreview.timeTravel's fallback streams every tagged snapshot's tag group through toOneAutoTag inside a .max(). toOneAutoTag calls checkAndGetOneAutoTag, which does checkState(autoTags.size() == 1). For a snapshot that has only manual tags, autoTags is empty, so it throws IllegalStateException: There are more than 1 auto-created tags of the same snapshot: . — a misleading message, since there are zero. Because .max() evaluates every group, one manual-only group poisons the whole fallback. Two effects: a preview target that genuinely can't be resolved throws that misleading error instead of the clean Cannot find snapshot or tag, and a valid auto tag <= the requested point that lives on another (often expired) tagged snapshot is never returned.

Anything else?

Manual vs auto is distinguished by name format (TagPeriodHandler.isAutoTag), so an ordinary manual tag name is non-auto and yields an empty group.

Are you willing to submit a PR?

  • I'm willing to submit a PR!

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions