Skip to content

Conversation

gouhongshen
Copy link
Contributor

@gouhongshen gouhongshen commented Jul 24, 2025

What type of PR is this?

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

Which issue(s) this PR fixes:

issue ##21978

What this PR does / why we need it:

consider the following example:
(within a session)
...
insert into t1 values (1) ---> commit ts (P2-L3)
insert into t1 values (2) ---> commit ts (P2-L4)
create table t2 clone t1 ---> the read snapshot ts is P2.

limited by the format for the snapshot read TS, the logic TS is truncated,
so in this example, the clone cannot read the newly inserted data.

so we try to increase the txn physical ts here to make sure the snapshot TS
the clone will get is greater than P2.

the same issue exists when create snapshot.

@matrix-meow matrix-meow added the size/S Denotes a PR that changes [10,99] lines label Jul 24, 2025
@mergify mergify bot added the kind/bug Something isn't working label Jul 24, 2025
@gouhongshen gouhongshen force-pushed the make_sure_snapshot_ts_greater_than_logic_ts branch from 14601e2 to de1be7c Compare July 24, 2025 12:49
@mergify mergify bot merged commit 9bfb8b1 into matrixorigin:main Jul 24, 2025
19 checks passed
@gouhongshen gouhongshen changed the title make sure the snapshot read TS greater than the TXN logic TS when create snapshot or clone. make sure the snapshot read TS greater than the TXN TS when create snapshot or clone. Jul 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working size/S Denotes a PR that changes [10,99] lines
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants