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

chore: Bump opendal to v0.36 #11624

Merged
merged 1 commit into from
May 30, 2023
Merged
Changes from all 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
11 changes: 6 additions & 5 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -103,7 +103,7 @@ members = [
[workspace.dependencies]
# databend maintains:
sled = { git = "https://github.com/datafuse-extras/sled", tag = "v0.34.7-datafuse.1", default-features = false }
opendal = { version = "0.35", features = [
opendal = { version = "0.36", features = [
"layers-tracing",
"layers-metrics",
"services-ipfs",
5 changes: 4 additions & 1 deletion src/common/storage/src/metrics.rs
Original file line number Diff line number Diff line change
@@ -23,11 +23,14 @@ use std::time::Instant;

use async_trait::async_trait;
use bytes::Bytes;
use opendal::ops::*;
use opendal::raw::oio;
use opendal::raw::Accessor;
use opendal::raw::Layer;
use opendal::raw::LayeredAccessor;
use opendal::raw::OpAppend;
use opendal::raw::OpList;
use opendal::raw::OpRead;
use opendal::raw::OpWrite;
use opendal::raw::RpAppend;
use opendal::raw::RpList;
use opendal::raw::RpRead;
8 changes: 7 additions & 1 deletion src/common/storage/src/runtime_layer.rs
Original file line number Diff line number Diff line change
@@ -32,12 +32,18 @@ use common_base::base::tokio::time;
use common_base::runtime::TrackedFuture;
use futures::ready;
use futures::Future;
use opendal::ops::*;
use opendal::raw::oio;
use opendal::raw::oio::ReadExt;
use opendal::raw::Accessor;
use opendal::raw::Layer;
use opendal::raw::LayeredAccessor;
use opendal::raw::OpAppend;
use opendal::raw::OpCreateDir;
use opendal::raw::OpDelete;
use opendal::raw::OpList;
use opendal::raw::OpRead;
use opendal::raw::OpStat;
use opendal::raw::OpWrite;
use opendal::raw::RpAppend;
use opendal::raw::RpCreateDir;
use opendal::raw::RpDelete;
8 changes: 3 additions & 5 deletions src/query/service/src/interpreters/interpreter_presign.rs
Original file line number Diff line number Diff line change
@@ -24,7 +24,6 @@ use common_expression::Scalar;
use common_expression::Value;
use common_storages_stage::StageTable;
use jsonb::Value as JsonbValue;
use opendal::ops::OpWrite;

use crate::interpreters::Interpreter;
use crate::pipelines::PipelineBuildResult;
@@ -68,12 +67,11 @@ impl Interpreter for PresignInterpreter {
let presigned_req = match self.plan.action {
PresignAction::Download => op.presign_read(&self.plan.path, self.plan.expire).await?,
PresignAction::Upload => {
let mut presign_args = OpWrite::new();
let mut fut = op.presign_write_with(&self.plan.path, self.plan.expire);
if let Some(content_type) = &self.plan.content_type {
presign_args = presign_args.with_content_type(content_type);
fut = fut.content_type(content_type);
}
op.presign_write_with(&self.plan.path, presign_args, self.plan.expire)
.await?
fut.await?
}
};

3 changes: 2 additions & 1 deletion src/query/sharing/src/layer.rs
Original file line number Diff line number Diff line change
@@ -24,7 +24,6 @@ use opendal::layers::LoggingLayer;
use opendal::layers::MetricsLayer;
use opendal::layers::RetryLayer;
use opendal::layers::TracingLayer;
use opendal::ops::*;
use opendal::raw::new_request_build_error;
use opendal::raw::parse_content_length;
use opendal::raw::parse_error_response;
@@ -36,6 +35,8 @@ use opendal::raw::AsyncBody;
use opendal::raw::ErrorResponse;
use opendal::raw::HttpClient;
use opendal::raw::IncomingAsyncBody;
use opendal::raw::OpRead;
use opendal::raw::OpStat;
use opendal::raw::Operation;
use opendal::raw::PresignedRequest;
use opendal::raw::RpRead;