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: Skip verify region if the provider is ceph or minio #42366

Closed
wants to merge 2 commits into from

Conversation

Fife86
Copy link

@Fife86 Fife86 commented Mar 17, 2023

What problem does this PR solve?

Issue Number: close #42033

Problem Summary:

When we use br with our infra, our endpoint didn't provide the correct region to our infra. In fact, it send us no region at all. The region test was failing, so we decided to skip this check for our ceph and minio providers.

What is changed and how it works?

We skip the region check in br if the provider is ceph or minio

Release note

Please refer to Release Notes Language Style Guide to write a quality release note.

None

@ti-chi-bot
Copy link
Member

ti-chi-bot commented Mar 17, 2023

[REVIEW NOTIFICATION]

This pull request has been approved by:

  • Leavrth

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 do-not-merge/invalid-title do-not-merge/needs-triage-completed do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. labels Mar 17, 2023
@ti-chi-bot
Copy link
Member

Welcome @Fife86!

It looks like this is your first PR to pingcap/tidb 🎉.

I'm the bot to help you request reviewers, add labels and more, See available commands.

We want to make sure your contribution gets all the attention it needs!



Thank you, and welcome to pingcap/tidb. 😃

@ti-chi-bot ti-chi-bot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. needs-ok-to-test Indicates a PR created by contributors and need ORG member send '/ok-to-test' to start testing. labels Mar 17, 2023
@ti-chi-bot
Copy link
Member

Hi @Fife86. Thanks for your PR.

I'm waiting for a pingcap member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@sre-bot
Copy link
Contributor

sre-bot commented Mar 17, 2023

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
1 out of 2 committers have signed the CLA.

✅ Fife86
❌ Florian Gabillé


Florian Gabillé seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@lance6716
Copy link
Contributor

/cc @WangLe1321 @Leavrth

@dveeden dveeden changed the title Skip verif region if the provider is ceph or minio Skip verify region if the provider is ceph or minio Mar 22, 2023
@dveeden dveeden changed the title Skip verify region if the provider is ceph or minio br: Skip verify region if the provider is ceph or minio Mar 22, 2023
@dveeden
Copy link
Contributor

dveeden commented Mar 22, 2023

/check-issue-triage-complete

br/pkg/storage/s3.go Outdated Show resolved Hide resolved

// s3manager.GetBucketRegionWithClient failed to get region from client if the client is ceph or minio
// It defaut back to us-west-1 which break the code if a region is already set
if qs.Provider != "ceph" && qs.Provider != "minio" {
Copy link
Contributor

Choose a reason for hiding this comment

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

  1. Not sure if excluding ceph and minio is the right solution, maybe we should check if qs.Provider == "s3" (or GCS?)
  2. Maybe we should separate the provider config from the logic here. And check if ProviderConfig.check_bucket_with_region == true and then elsewhere store the config for each provider.

These are just ideas, I have no objections on merging this as-is.

Copy link
Author

Choose a reason for hiding this comment

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

1 . I'm not sure about the list. We add ceph and minio because it's what we are working with and had troubles, but the issues may be wider.
2 Would it be simpler to add a parameter like qs.SkipBucketRegionCheck and a tag --skip-bucket-region-check when we launch br ? ( the wording is a bit long ^^")

@dveeden
Copy link
Contributor

dveeden commented Mar 22, 2023

Would be good to add a test to ensure this doesn't break again in the future.

Co-authored-by: Daniël van Eeden <github@myname.nl>
@dveeden
Copy link
Contributor

dveeden commented Mar 23, 2023

Could you add a release note?

This can be done by adding something like this to the description of the PR:

```release-note
Compatibility issues with Ceph and MinIO related to region checks have been fixed
```

@dveeden
Copy link
Contributor

dveeden commented Mar 23, 2023

@Fife86 Looks like author email that you used for 2242370 isn't linked to your GitHub account causing the CLA checks to fail.

Please try to add that email address to your GitHub account or squash the commits and set the author to be the email address you use for GitHub.

@mjonss
Copy link
Contributor

mjonss commented Mar 23, 2023

/ok-to-test

@ti-chi-bot ti-chi-bot added ok-to-test Indicates a PR is ready to be tested. and removed needs-ok-to-test Indicates a PR created by contributors and need ORG member send '/ok-to-test' to start testing. labels Mar 23, 2023
@ti-chi-bot
Copy link
Member

@Fife86: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
idc-jenkins-ci-tidb/build d5c6e62 link true /test build
idc-jenkins-ci-tidb/unit-test d5c6e62 link true /test unit-test

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

// s3manager.GetBucketRegionWithClient failed to get region from client if the client is ceph or minio
// It defaults back to us-west-1 which breaks the code if a region is already set
if qs.Provider != "ceph" && qs.Provider != "minio" {

Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change

From the CI checks:

br/pkg/storage/s3.go:365:53: empty-lines: extra empty line at the start of a block (all_revive)

@ti-chi-bot ti-chi-bot added status/LGT1 Indicates that a PR has LGTM 1. release-note-none Denotes a PR that doesn't merit a release note. and removed do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. labels Mar 24, 2023
@Leavrth
Copy link
Contributor

Leavrth commented Mar 24, 2023

I have added the default release note into the first comment, like this:

```release-note
None
```

you can modify the None if in need, refer to #42366 (comment)

@ti-chi-bot
Copy link
Member

@Fife86: PR needs rebase.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@ti-chi-bot ti-chi-bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Mar 30, 2023
@dveeden
Copy link
Contributor

dveeden commented Mar 30, 2023

Thank you for the pull request, issue and all the work you did on this. Let's close this as a very similar PR has been merged that should fix the issue. Feel free to add a note here or on the issue if testing shows that this isn't completely fixed or if there are any other concerns. Thank you for choosing TiDB!

@dveeden dveeden closed this Mar 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. ok-to-test Indicates a PR is ready to be tested. release-note-none Denotes a PR that doesn't merit a release note. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. status/LGT1 Indicates that a PR has LGTM 1.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

BR - S3 Endpoint is not set when get bucket informations
7 participants