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

GH-38844: [C++] S3FileSystem export s3 sdk config "use_virtual_addressing" to arrow::fs::S3Options #38858

Merged
merged 7 commits into from
Dec 5, 2023
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion cpp/src/arrow/filesystem/s3fs.cc
Original file line number Diff line number Diff line change
Expand Up @@ -951,7 +951,8 @@ class ClientBuilder {
client_config_.caPath = ToAwsString(internal::global_options.tls_ca_dir_path);
}

const bool use_virtual_addressing = options_.endpoint_override.empty();
const bool use_virtual_addressing =
options_.endpoint_override.empty() || options_.force_virtual_addressing;

// Set proxy options if provided
if (!options_.proxy_options.scheme.empty()) {
Expand Down
6 changes: 6 additions & 0 deletions cpp/src/arrow/filesystem/s3fs.h
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,12 @@ struct ARROW_EXPORT S3Options {
/// Type of credentials being used. Set along with credentials_provider.
S3CredentialsKind credentials_kind = S3CredentialsKind::Default;

/// Whether to use virtual addressing of buckets
liangjiawei1110 marked this conversation as resolved.
Show resolved Hide resolved
///
/// If true, then virtual addressing is always enabled.
/// If false, then virtual addressing is only enabled if `endpoint_override` is empty.
pitrou marked this conversation as resolved.
Show resolved Hide resolved
bool force_virtual_addressing = false;

/// Whether OutputStream writes will be issued in the background, without blocking.
bool background_writes = true;

Expand Down
Loading