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

br-stream: add precheck before create task #33088

Merged
merged 3 commits into from
Mar 17, 2022

Conversation

3pointer
Copy link
Contributor

What problem does this PR solve?

Issue Number: close #33087

Problem Summary:
make sure that all stores support log backup then create log backup tasks.

What is changed and how it works?

  1. add a check before task starts.
  2. use tikv status_address to get config and check when log backup is enabled.

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No code

Release note

None

@ti-chi-bot
Copy link
Member

ti-chi-bot commented Mar 15, 2022

[REVIEW NOTIFICATION]

This pull request has been approved by:

  • YuJuncen
  • joccau

To complete the pull request process, please ask the reviewers in the list to review by filling /cc @reviewer in the comment.
After your PR has acquired the required number of LGTMs, you can assign this pull request to the committer in the list by filling /assign @committer in the comment to help you merge this pull request.

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

Reviewer can indicate their review by submitting an approval review.
Reviewer can cancel approval by submitting a request changes review.

@ti-chi-bot ti-chi-bot added release-note-none Denotes a PR that doesn't merit a release note. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. labels Mar 15, 2022
@3pointer 3pointer requested review from joccau, YuJuncen and kennytm March 15, 2022 09:46
@joccau
Copy link
Member

joccau commented Mar 15, 2022

rest LGTM

@joccau
Copy link
Member

joccau commented Mar 15, 2022

(https://ci.pingcap.net/blue/organizations/jenkins/tidb_ghpr_check/detail/tidb_ghpr_check/54908/pipeline#step-73-log-213)[2022-03-15T09:58:01.697Z] br/pkg/task/stream.go:22: File is not goimports-ed (goimports)

[2022-03-15T09:58:01.697Z] "github.com/pingcap/kvproto/pkg/metapb"

[2022-03-15T09:58:01.697Z] "github.com/pingcap/tidb/br/pkg/httputil"

[2022-03-15T09:58:01.697Z] br/pkg/task/stream_test.go:19: File is not goimports-ed (goimports)

[2022-03-15T09:58:01.697Z] "fmt"

[2022-03-15T09:58:01.697Z] br/pkg/task/stream.go:359:28: response body must be closed (bodyclose)

[2022-03-15T09:58:01.697Z] resp, e := s.httpCli.Get(addr)

[2022-03-15T09:58:01.697Z] ^

[2022-03-15T09:58:01.697Z] level=info msg="File cache stats: 1702 entries of total size 26.3MiB"

[2022-03-15T09:58:01.697Z] level=info msg="Memory: 2299 samples, avg is 1943.3MB, max is 10864.1MB"

[2022-03-15T09:58:01.697Z] level=info msg="Execution took 4m7.969458773s"

[2022-03-15T09:58:01.697Z] make: *** [check-static] Error 1

Copy link
Contributor

@YuJuncen YuJuncen left a comment

Choose a reason for hiding this comment

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

LGTM

@ti-chi-bot ti-chi-bot added the status/LGT1 Indicates that a PR has LGTM 1. label Mar 16, 2022
Copy link
Member

@joccau joccau left a comment

Choose a reason for hiding this comment

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

LGTM

@ti-chi-bot ti-chi-bot added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Mar 17, 2022
@3pointer 3pointer merged commit 76f0ab1 into pingcap:br-stream Mar 17, 2022
3pointer added a commit that referenced this pull request Mar 21, 2022
* add switch check before stream starts
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release-note-none Denotes a PR that doesn't merit a release note. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. status/LGT2 Indicates that a PR has LGTM 2.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants