-
Notifications
You must be signed in to change notification settings - Fork 489
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
parser: add AsOfClause for START TRANSACTION READ ONLY statement #1215
Conversation
Signed-off-by: JmPotato <ghzpotato@gmail.com>
Signed-off-by: JmPotato <ghzpotato@gmail.com>
33442f1
to
2dcbd7c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, plz reslove the conflict.
#1211 introduced a change to TiDB that is not forward compatible. I'm waiting for the merging of pingcap/tidb#24196, then I will resolve the conflict. |
Signed-off-by: JmPotato <ghzpotato@gmail.com>
ast/functions.go
Outdated
// TiDBBoundStaleness is used to determine the TS for a read only request. | ||
// It will be used in the Stale Read feature. | ||
// For more info, please see AsOfClause. | ||
TiDBBoundStaleness = "tidb_bound_staleness" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should be bounded staleness
rather than bound staleness
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's ok to use the passive voice bound
here as an adjective, and it's shorter than bounded
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you google bound staleness
, the results are all bounded staleness
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fair enough. So what about tidb_bounded_staleness
or tidb_staleness_bound
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I rename it to tidb_staleness_bound
, PTAL!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@morgo PTAL, what do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I prefer tidb_bounded_staleness
. :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I agree with @nolouch :-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@morgo @nolouch @djshow832 I finished the renaming, PTAL.
Co-authored-by: djshow832 <zhangming@pingcap.com>
Signed-off-by: JmPotato <ghzpotato@gmail.com>
Signed-off-by: JmPotato <ghzpotato@gmail.com>
Signed-off-by: JmPotato <ghzpotato@gmail.com>
/lgtm |
/lgtm |
/merge |
/run-all-tests |
@JmPotato merge failed. |
Signed-off-by: JmPotato <ghzpotato@gmail.com>
Signed-off-by: JmPotato ghzpotato@gmail.com
What problem does this PR solve?
Part of pingcap/tidb#24291. Add
AsOfClause
forSTART TRANSACTION READ ONLY
statement.What is changed and how it works?
START TRANSACTION READ ONLY
statement.TIDB_BOUNDED_STALENESS
built-in function.Check List
Tests
Related changes: #1206