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

add s3.useVirtualAddressing config #1253

Merged
merged 1 commit into from
Apr 12, 2022
Merged

add s3.useVirtualAddressing config #1253

merged 1 commit into from
Apr 12, 2022

Conversation

h0hmj
Copy link
Contributor

@h0hmj h0hmj commented Apr 8, 2022

What problem does this PR solve?

Issue Number: close #xxx

Problem Summary:

We do not support virtual host.

What is changed and how it works?

What's Changed:

Support both virtual host and path style

How it Works:

Add a config, init client with config

Side effects(Breaking backward compatibility? Performance regression?):

Check List

  • Relevant documentation/comments is changed or added
  • I acknowledge that all my contributions will be made under the project's license

@@ -132,6 +132,8 @@ void InitS3AdaptorOptionExceptS3InfoOption(Configuration* conf,
&s3Opt->bpsReadMB));
LOG_IF(FATAL, !conf->GetUInt64Value("s3.throttle.bpsWriteMB",
&s3Opt->bpsWriteMB));
LOG_IF(FATAL, !conf->GetBoolValue("s3.useVirtualAddressing",
&s3Opt->useVirtualAddressing));
Copy link
Contributor

Choose a reason for hiding this comment

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

also need add this config in func InitS3AdaptorOption?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

InitS3AdaptorOption will reuse InitS3AdaptorOptionExceptS3InfoOption

@aspirer
Copy link
Contributor

aspirer commented Apr 12, 2022

tests passed:

s3.useVirtualAddressing: false

"115.236.119.140" "-" "12/Apr/2022:12:17:23 +0800" "PUT /wpjuicefs3/1_16777217_2_0_0 HTTP/1.1" "200" "25" "-" "S3 Browser" "-" "0.067" "2538" "3242" "nos-eastchina1.126.net" "0.065" "10.176.14.14:8182" "wpjuicefs3" "6165676125881331054" "986654c8a49a4118ba40690aa4f1e604" "c978a2cf-231c-4251-b3e8-23df4eed1964" "PutObject" "DFS" "STANDARD/-127" "-" "http" "outer" "-" "-"
s3.useVirtualAddressing: true
"115.236.119.140" "-" "12/Apr/2022:12:13:27 +0800" "PUT /1_16777216_1_0_0 HTTP/1.1" "200" "25" "-" "S3 Browser" "-" "0.021" "2538" "3242" "wpjuicefs3.nos-eastchina1.126.net" "0.015" "10.176.14.17:9192" "wpjuicefs3" "6165676125881331054" "986654c8a49a4118ba40690aa4f1e604" "40acc159-99d1-4ec0-9f80-772afcc61cb2" "PutObject" "DFS" "STANDARD/-127" "-" "http" "outer" "-" "-"

@aspirer aspirer merged commit 2a84e86 into opencurve:master Apr 12, 2022
@wu-hanqing wu-hanqing mentioned this pull request Jul 21, 2022
2 tasks
@h0hmj h0hmj deleted the add-config branch May 30, 2023 07:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants