Skip to content
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

Delete txn scope code #1587

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open

Conversation

ekexium
Copy link
Contributor

@ekexium ekexium commented Feb 19, 2025

Part of pingcap/tidb#58838

Some changes that I'm not sure about:

  1. Test TestMinSafeTsFromMixed1 and TestMinSafeTsFromMixed2
  2. updateGlobalTxnScopeTSFromPD

@ti-chi-bot ti-chi-bot bot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. dco-signoff: yes Indicates the PR's author has signed the dco. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Feb 19, 2025
@ekexium ekexium force-pushed the remove-txn-scope-code branch from 72d2742 to cf6688e Compare February 26, 2025 11:50
Signed-off-by: ekexium <[email protected]>
@ekexium ekexium force-pushed the remove-txn-scope-code branch from cf6688e to 13eacc3 Compare February 26, 2025 11:53
@ti-chi-bot ti-chi-bot bot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Feb 26, 2025
Signed-off-by: ekexium <[email protected]>
@ti-chi-bot ti-chi-bot bot added size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. and removed size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Feb 26, 2025
Signed-off-by: ekexium <[email protected]>
@ekexium ekexium force-pushed the remove-txn-scope-code branch from ebcff5c to 53fe1c7 Compare February 27, 2025 13:21
@ti-chi-bot ti-chi-bot bot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Feb 27, 2025
@ekexium ekexium force-pushed the remove-txn-scope-code branch from 53fe1c7 to 4ab4b5f Compare February 27, 2025 13:30
@ekexium ekexium marked this pull request as ready for review February 27, 2025 13:45
@ti-chi-bot ti-chi-bot bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Feb 27, 2025
@cfzjywxk
Copy link
Contributor

@JmPotato PTAL

config/config.go Outdated
TxnScope string
EnableAsyncCommit bool
Enable1PC bool
// FIXME: rename
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you provide more explanation about this comment?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated

Comment on lines 43 to 46
// Option represents available options for the oracle.Oracle.
// TODO: remove this struct
type Option struct {
TxnScope string
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not just remove it in this PR?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To minimize the change.. It has hundreds of usages. I prefer keeping this PR (relatively) small

Copy link
Contributor

@zyguan zyguan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally LGTM, any plan to deprecate (or rename) oracle.GlobalTxnScope?

@ekexium
Copy link
Contributor Author

ekexium commented Mar 6, 2025

any plan to deprecate (or rename) oracle.GlobalTxnScope?

Yes, I think it's the last step. After we deprecated txn-scope related code, we can rename those left to names like ReadReplicaScope

Copy link

ti-chi-bot bot commented Mar 6, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: zyguan

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ti-chi-bot ti-chi-bot bot added the needs-1-more-lgtm Indicates a PR needs 1 more LGTM. label Mar 6, 2025
Copy link

ti-chi-bot bot commented Mar 6, 2025

[LGTM Timeline notifier]

Timeline:

  • 2025-03-06 07:36:42.769818444 +0000 UTC m=+513515.898738189: ☑️ agreed by zyguan.

@ti-chi-bot ti-chi-bot bot added the approved label Mar 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved dco-signoff: yes Indicates the PR's author has signed the dco. needs-1-more-lgtm Indicates a PR needs 1 more LGTM. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants