-
Notifications
You must be signed in to change notification settings - Fork 5.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
strange behavior when begin transaction when 'tidb_snapshot' is set #25176
Comments
@cfzjywxk PTAL |
It seems when building a executor, getSnapshotTs's return uses sys var 'SnapshotTS' once it isset ignoring the txn's startTs. Lines 1397 to 1404 in fbbada3
And when opening PointGetExecutor, it will step to line 135 if for update read ts is bigger than txn read ts, thats why it only happends after a select ... for update clause. Lines 132 to 136 in fbbada3
|
@lcwangchao |
/cc |
I think we should narrow down the scope of tidb snapshot. |
I agree to limit the usage of this variable. IMHO it should never be used with transactions. But limiting its usage can potentially cause compatibility issues between new and old versions of TiDB. |
Bug Report
Please answer these questions before submitting your issue. Thanks!
1. Minimal reproduce step (Required)
s1, and s2 are two tidb connections.
2. What did you expect to see? (Required)
3. What did you see instead (Required)
4. What is your TiDB version? (Required)
master
The text was updated successfully, but these errors were encountered: