-
Notifications
You must be signed in to change notification settings - Fork 523
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
backend/s3: Anonymous access not supported #54
Comments
This comment was marked as resolved.
This comment was marked as resolved.
It's buggy now. The behavior between keeping
I'm considering removing the
|
Thank you. The |
A bit complex but it is possible. SDK's maintainer gives a workaround: awslabs/aws-sdk-rust#425 (comment) And I think we can inject the let builder = aws_smithy_client::Builder::dyn_https()
.middleware(AwsS3::middleware::DefaultMiddleware::new()) <-- inject middleware here.
.build();
Ok(Arc::new(Backend {
// Make `/` as the default of root.
root,
bucket: self.bucket.clone(),
client: AwsS3::Client::with_config(builder, cfg.build()),
})) We can config But it may take some time to figure out how to make it works. |
Thanks. |
Maybe we can use: let client = aws_sdk_s3::Client::with_config(
aws_sdk_s3::client::Builder::new()
.connector(DynConnector::new(my_custom_connector)) // Now with `DynConnector`
.middleware(DynMiddleware::new(my_custom_middleware)) // Now with `DynMiddleware`
.default_async_sleep()
.build(),
config
); Read https://github.com/awslabs/aws-sdk-rust/releases/tag/v0.7.0 for more details. |
Just to note, here is my today's exploration, I get the use aws_smithy_client::{Builder, Client};
let hyper_connector = aws_smithy_client::hyper_ext::Adapter::builder()
.build(aws_smithy_client::conns::https());
// let connector = DynConnector::new()
let x = aws_smithy_client::Builder::new()
.connector(hyper_connector)
.middleware(aws_smithy_client::erase::DynMiddleware::new(
tower::util::MapRequestLayer::new(|req: aws_smithy_http::operation::Request| {
let (inner, mut props) = req.into_parts();
{
let mut p = props.acquire_mut();
let x = p.get_mut::<usize>();
println!("{:?}", x);
}
aws_smithy_http::operation::Request::from_parts(inner, props)
}),
))
.build();
let _ = aws_sdk_s3::Client::with_config(x.into_dyn(), cfg.build()); |
Background
The
s3://repo.databend.rs/dataset/stateful/ontime.csv
ACL is Everyone (public access) on AWS S3.If the credentials not set for OpenDAL:
will get the error:
Enhancement
It would be better to add a test for minio bucket with public ACL.
The text was updated successfully, but these errors were encountered: