Skip to content

Conversation

@zz-jason
Copy link
Member

Signed-off-by: Jian Zhang zjsariel@gmail.com

What problem does this PR solve?

Issue Number: [to #67]

Problem Description: I found br relies on pingcap/parser, which makes the dependency hard to manage, i.e, upgrade some packages like kvproto to a newer version

What is changed and how does it work?

this pr aims to delete parser related functions and simplify the dependency

Code changes

  • Has exported function/method change
  • Has exported variable/fields change
  • Has interface methods change

Check List for Tests

This PR has been tested by at least one of the following methods:

  • Unit test
  • Integration test

Side effects

  • No side effects

Related changes

  • No related changes

Signed-off-by: Jian Zhang <zjsariel@gmail.com>
@zz-jason
Copy link
Member Author

zz-jason commented Mar 30, 2022

now only the following places directly relaies on parser, I'll try to remove them later in this PR:

➜ find . -name "*.go" | xargs grep --color "parser"
./pkg/task/backup.go:   "github.com/pingcap/tidb/parser/mysql"

Signed-off-by: Jian Zhang <zjsariel@gmail.com>
Signed-off-by: Jian Zhang <zjsariel@gmail.com>
@zz-jason zz-jason requested review from pingyu and zeminzhou March 30, 2022 05:11
@zz-jason zz-jason enabled auto-merge (squash) March 30, 2022 05:11
Signed-off-by: Jian Zhang <zjsariel@gmail.com>
)

// LoadRestoreStores loads the stores used to restore data.
func (rc *Client) LoadRestoreStores(ctx context.Context) error {
Copy link
Collaborator

Choose a reason for hiding this comment

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

These methods seems to be used to stop PD scheduling regions during restore, as we have pre-splitted regions. But need some changes (on the table codes).

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes. We can add it back once needed.

Copy link
Collaborator

@pingyu pingyu left a comment

Choose a reason for hiding this comment

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

LGTM

@zz-jason zz-jason merged commit 69ddf53 into tikv:main Mar 30, 2022
@zz-jason zz-jason deleted the fix/remove-parser-related-files branch March 30, 2022 12:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants