You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@opendal.apache.org by ju...@apache.org on 2023/11/15 14:49:13 UTC

(incubator-opendal) branch bump/suppaftp updated (3298a7299 -> 4a2b9978d)

This is an automated email from the ASF dual-hosted git repository.

junouyang pushed a change to branch bump/suppaftp
in repository https://gitbox.apache.org/repos/asf/incubator-opendal.git


    omit 3298a7299 fix: fix code
    omit 77b239dcb fix: let ftp service to suppaftp 5.2 API
    omit b53b4aa4e chore: bump suppaftp version to 5.2
     add b4a222196 RFC: Concurrent Stat in List (#3574)
     new 5883c6c3e chore: bump suppaftp version to 5.2
     new dd8c984e0 fix: let ftp service to suppaftp 5.2 API
     new 4a2b9978d fix: fix code

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (3298a7299)
            \
             N -- N -- N   refs/heads/bump/suppaftp (4a2b9978d)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 core/src/docs/rfcs/3574_concurrent_stat_in_list.md | 80 ++++++++++++++++++++++
 core/src/docs/rfcs/mod.rs                          |  3 +
 2 files changed, 83 insertions(+)
 create mode 100644 core/src/docs/rfcs/3574_concurrent_stat_in_list.md


(incubator-opendal) 03/03: fix: fix code

Posted by ju...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

junouyang pushed a commit to branch bump/suppaftp
in repository https://gitbox.apache.org/repos/asf/incubator-opendal.git

commit 4a2b9978dd59ff3defbf9cbd60b6658738275a0d
Author: owl <ou...@gmail.com>
AuthorDate: Wed Nov 15 22:41:09 2023 +0800

    fix: fix code
---
 core/Cargo.toml                  |  1 -
 core/src/services/ftp/backend.rs | 11 +++++++----
 2 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/core/Cargo.toml b/core/Cargo.toml
index 85aa539b4..9b74ff691 100644
--- a/core/Cargo.toml
+++ b/core/Cargo.toml
@@ -51,7 +51,6 @@ default = [
   "services-webdav",
   "services-webhdfs",
   "services-azfile",
-  "services-ftp",
 ]
 
 # Build docs or not.
diff --git a/core/src/services/ftp/backend.rs b/core/src/services/ftp/backend.rs
index d0d9d9bb9..27d94f3b9 100644
--- a/core/src/services/ftp/backend.rs
+++ b/core/src/services/ftp/backend.rs
@@ -28,14 +28,14 @@ use futures::AsyncRead;
 use futures::AsyncReadExt;
 use http::Uri;
 use log::debug;
-use suppaftp::AsyncNativeTlsFtpStream;
+use suppaftp::async_native_tls::TlsConnector;
 use suppaftp::list::File;
 use suppaftp::types::FileType;
 use suppaftp::types::Response;
+use suppaftp::AsyncNativeTlsConnector;
+use suppaftp::AsyncNativeTlsFtpStream;
 use suppaftp::FtpError;
 use suppaftp::ImplAsyncFtpStream;
-use suppaftp::async_native_tls::TlsConnector;
-use suppaftp::AsyncNativeTlsConnector;
 use suppaftp::Status;
 use tokio::sync::OnceCell;
 
@@ -223,7 +223,10 @@ impl bb8::ManageConnection for Manager {
         // switch to secure mode if ssl/tls is on.
         let mut ftp_stream = if self.enable_secure {
             stream
-                .into_secure(AsyncNativeTlsConnector::from(TlsConnector::new()), &self.endpoint)
+                .into_secure(
+                    AsyncNativeTlsConnector::from(TlsConnector::new()),
+                    &self.endpoint,
+                )
                 .await?
         } else {
             stream


(incubator-opendal) 02/03: fix: let ftp service to suppaftp 5.2 API

Posted by ju...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

junouyang pushed a commit to branch bump/suppaftp
in repository https://gitbox.apache.org/repos/asf/incubator-opendal.git

commit dd8c984e003e52d858dc950e7fad2ccef889eaa8
Author: owl <ou...@gmail.com>
AuthorDate: Wed Nov 15 22:38:17 2023 +0800

    fix: let ftp service to suppaftp 5.2 API
---
 Cargo.lock                       | 13 +++++++++++++
 core/Cargo.toml                  |  2 ++
 core/src/services/ftp/backend.rs | 13 +++++++------
 3 files changed, 22 insertions(+), 6 deletions(-)

diff --git a/Cargo.lock b/Cargo.lock
index ce7263709..02bf97e81 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -297,6 +297,18 @@ dependencies = [
  "event-listener",
 ]
 
+[[package]]
+name = "async-native-tls"
+version = "0.5.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "9343dc5acf07e79ff82d0c37899f079db3534d99f189a1837c8e549c99405bec"
+dependencies = [
+ "futures-util",
+ "native-tls",
+ "thiserror",
+ "url",
+]
+
 [[package]]
 name = "async-recursion"
 version = "0.3.2"
@@ -6586,6 +6598,7 @@ version = "5.2.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "653aa9a6ebc0446a2d5c2be5b698b48a3192c7a098d0ed9a7c232e3a6340f091"
 dependencies = [
+ "async-native-tls",
  "async-std",
  "async-tls 0.12.0",
  "async-trait",
diff --git a/core/Cargo.toml b/core/Cargo.toml
index 10bbd2485..85aa539b4 100644
--- a/core/Cargo.toml
+++ b/core/Cargo.toml
@@ -51,6 +51,7 @@ default = [
   "services-webdav",
   "services-webhdfs",
   "services-azfile",
+  "services-ftp",
 ]
 
 # Build docs or not.
@@ -291,6 +292,7 @@ sled = { version = "0.34.7", optional = true }
 suppaftp = { version = "5.2", default-features = false, features = [
   "async-secure",
   "async-rustls",
+  "async-native-tls",
 ], optional = true }
 tikv-client = { version = "0.2.0", optional = true }
 tokio = "1.27"
diff --git a/core/src/services/ftp/backend.rs b/core/src/services/ftp/backend.rs
index 787da112f..d0d9d9bb9 100644
--- a/core/src/services/ftp/backend.rs
+++ b/core/src/services/ftp/backend.rs
@@ -21,7 +21,6 @@ use std::fmt::Formatter;
 use std::str;
 use std::str::FromStr;
 
-use async_tls::TlsConnector;
 use async_trait::async_trait;
 use bb8::PooledConnection;
 use bb8::RunError;
@@ -29,11 +28,14 @@ use futures::AsyncRead;
 use futures::AsyncReadExt;
 use http::Uri;
 use log::debug;
+use suppaftp::AsyncNativeTlsFtpStream;
 use suppaftp::list::File;
 use suppaftp::types::FileType;
 use suppaftp::types::Response;
 use suppaftp::FtpError;
-use suppaftp::FtpStream;
+use suppaftp::ImplAsyncFtpStream;
+use suppaftp::async_native_tls::TlsConnector;
+use suppaftp::AsyncNativeTlsConnector;
 use suppaftp::Status;
 use tokio::sync::OnceCell;
 
@@ -213,16 +215,15 @@ pub struct Manager {
 
 #[async_trait]
 impl bb8::ManageConnection for Manager {
-    type Connection = FtpStream;
+    type Connection = AsyncNativeTlsFtpStream;
     type Error = FtpError;
 
     async fn connect(&self) -> std::result::Result<Self::Connection, Self::Error> {
-        let stream = FtpStream::connect(&self.endpoint).await?;
-
+        let stream = ImplAsyncFtpStream::connect(&self.endpoint).await?;
         // switch to secure mode if ssl/tls is on.
         let mut ftp_stream = if self.enable_secure {
             stream
-                .into_secure(TlsConnector::default().into(), &self.endpoint)
+                .into_secure(AsyncNativeTlsConnector::from(TlsConnector::new()), &self.endpoint)
                 .await?
         } else {
             stream


(incubator-opendal) 01/03: chore: bump suppaftp version to 5.2

Posted by ju...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

junouyang pushed a commit to branch bump/suppaftp
in repository https://gitbox.apache.org/repos/asf/incubator-opendal.git

commit 5883c6c3e79fe6c38d9a1d63f55dad852037813c
Author: owl <ou...@gmail.com>
AuthorDate: Wed Nov 15 17:32:30 2023 +0800

    chore: bump suppaftp version to 5.2
---
 Cargo.lock      | 116 ++++++++++++++++++++++++++++++++++++++++++++------------
 core/Cargo.toml |   2 +-
 2 files changed, 92 insertions(+), 26 deletions(-)

diff --git a/Cargo.lock b/Cargo.lock
index 99f078297..ce7263709 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -382,10 +382,24 @@ dependencies = [
  "futures-core",
  "futures-io",
  "rustls 0.19.1",
- "webpki",
+ "webpki 0.21.4",
  "webpki-roots 0.21.1",
 ]
 
+[[package]]
+name = "async-tls"
+version = "0.12.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "cfeefd0ca297cbbb3bd34fd6b228401c2a5177038257afd751bc29f0a2da4795"
+dependencies = [
+ "futures-core",
+ "futures-io",
+ "rustls 0.20.9",
+ "rustls-pemfile",
+ "webpki 0.22.4",
+ "webpki-roots 0.22.6",
+]
+
 [[package]]
 name = "async-trait"
 version = "0.1.74"
@@ -412,7 +426,7 @@ dependencies = [
  "base64 0.21.4",
  "rand 0.8.5",
  "regex",
- "ring",
+ "ring 0.16.20",
  "serde",
  "serde_json",
  "tracing",
@@ -2996,7 +3010,7 @@ checksum = "6971da4d9c3aa03c3d8f3ff0f4155b534aad021292003895a469716b2a230378"
 dependencies = [
  "base64 0.21.4",
  "pem 1.1.1",
- "ring",
+ "ring 0.16.20",
  "serde",
  "serde_json",
  "simple_asn1",
@@ -3013,9 +3027,9 @@ dependencies = [
 
 [[package]]
 name = "lazy-regex"
-version = "2.5.0"
+version = "3.1.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "ff63c423c68ea6814b7da9e88ce585f793c87ddd9e78f646970891769c8235d4"
+checksum = "5d12be4595afdf58bd19e4a9f4e24187da2a66700786ff660a418e9059937a4c"
 dependencies = [
  "lazy-regex-proc_macros",
  "once_cell",
@@ -3024,14 +3038,14 @@ dependencies = [
 
 [[package]]
 name = "lazy-regex-proc_macros"
-version = "2.4.1"
+version = "3.1.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "8edfc11b8f56ce85e207e62ea21557cfa09bb24a8f6b04ae181b086ff8611c22"
+checksum = "44bcd58e6c97a7fcbaffcdc95728b393b8d98933bfadad49ed4097845b57ef0b"
 dependencies = [
  "proc-macro2",
  "quote",
  "regex",
- "syn 1.0.109",
+ "syn 2.0.38",
 ]
 
 [[package]]
@@ -4155,7 +4169,7 @@ dependencies = [
  "anyhow",
  "async-backtrace",
  "async-compat",
- "async-tls",
+ "async-tls 0.11.0",
  "async-trait",
  "atomic_lib",
  "await-tree",
@@ -5738,11 +5752,25 @@ dependencies = [
  "libc",
  "once_cell",
  "spin 0.5.2",
- "untrusted",
+ "untrusted 0.7.1",
  "web-sys",
  "winapi",
 ]
 
+[[package]]
+name = "ring"
+version = "0.17.5"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "fb0205304757e5d899b9c2e448b867ffd03ae7f988002e47cd24954391394d0b"
+dependencies = [
+ "cc",
+ "getrandom 0.2.10",
+ "libc",
+ "spin 0.9.8",
+ "untrusted 0.9.0",
+ "windows-sys 0.48.0",
+]
+
 [[package]]
 name = "rkyv"
 version = "0.7.42"
@@ -5941,9 +5969,21 @@ checksum = "35edb675feee39aec9c99fa5ff985081995a06d594114ae14cbe797ad7b7a6d7"
 dependencies = [
  "base64 0.13.1",
  "log",
- "ring",
+ "ring 0.16.20",
  "sct 0.6.1",
- "webpki",
+ "webpki 0.21.4",
+]
+
+[[package]]
+name = "rustls"
+version = "0.20.9"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "1b80e3dec595989ea8510028f30c408a4630db12c9cbb8de34203b89d6577e99"
+dependencies = [
+ "log",
+ "ring 0.16.20",
+ "sct 0.7.0",
+ "webpki 0.22.4",
 ]
 
 [[package]]
@@ -5953,7 +5993,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "cd8d6c9f025a446bc4d18ad9632e69aec8f287aa84499ee335599fabd20c3fd8"
 dependencies = [
  "log",
- "ring",
+ "ring 0.16.20",
  "rustls-webpki",
  "sct 0.7.0",
 ]
@@ -5985,8 +6025,8 @@ version = "0.101.6"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "3c7d5dece342910d9ba34d259310cae3e0154b873b35408b787b59bce53d34fe"
 dependencies = [
- "ring",
- "untrusted",
+ "ring 0.16.20",
+ "untrusted 0.7.1",
 ]
 
 [[package]]
@@ -6058,8 +6098,8 @@ version = "0.6.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "b362b83898e0e69f38515b82ee15aa80636befe47c3b6d3d89a911e78fc228ce"
 dependencies = [
- "ring",
- "untrusted",
+ "ring 0.16.20",
+ "untrusted 0.7.1",
 ]
 
 [[package]]
@@ -6068,8 +6108,8 @@ version = "0.7.0"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "d53dcdb7c9f8158937a7981b48accfd39a43af418591a5d008c7b22b5e1b7ca4"
 dependencies = [
- "ring",
- "untrusted",
+ "ring 0.16.20",
+ "untrusted 0.7.1",
 ]
 
 [[package]]
@@ -6542,12 +6582,13 @@ checksum = "81cdd64d312baedb58e21336b31bc043b77e01cc99033ce76ef539f78e965ebc"
 
 [[package]]
 name = "suppaftp"
-version = "4.7.0"
+version = "5.2.2"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "d865bcb2d4bfea8c0ab4ca6c3f79d011ad04db5ef1fc693e720299bb60c58018"
+checksum = "653aa9a6ebc0446a2d5c2be5b698b48a3192c7a098d0ed9a7c232e3a6340f091"
 dependencies = [
  "async-std",
- "async-tls",
+ "async-tls 0.12.0",
+ "async-trait",
  "chrono",
  "lazy-regex",
  "log",
@@ -7424,6 +7465,12 @@ version = "0.7.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "a156c684c91ea7d62626509bce3cb4e1d9ed5c4d978f7b4352658f96a4c26b4a"
 
+[[package]]
+name = "untrusted"
+version = "0.9.0"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1"
+
 [[package]]
 name = "ureq"
 version = "2.8.0"
@@ -7663,8 +7710,18 @@ version = "0.21.4"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "b8e38c0608262c46d4a56202ebabdeb094cef7e560ca7a226c6bf055188aa4ea"
 dependencies = [
- "ring",
- "untrusted",
+ "ring 0.16.20",
+ "untrusted 0.7.1",
+]
+
+[[package]]
+name = "webpki"
+version = "0.22.4"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "ed63aea5ce73d0ff405984102c42de94fc55a6b75765d621c65262469b3c9b53"
+dependencies = [
+ "ring 0.17.5",
+ "untrusted 0.9.0",
 ]
 
 [[package]]
@@ -7673,7 +7730,16 @@ version = "0.21.1"
 source = "registry+https://github.com/rust-lang/crates.io-index"
 checksum = "aabe153544e473b775453675851ecc86863d2a81d786d741f6b76778f2a48940"
 dependencies = [
- "webpki",
+ "webpki 0.21.4",
+]
+
+[[package]]
+name = "webpki-roots"
+version = "0.22.6"
+source = "registry+https://github.com/rust-lang/crates.io-index"
+checksum = "b6c71e40d7d2c34a5106301fb632274ca37242cd0c9d3e64dbece371a40a2d87"
+dependencies = [
+ "webpki 0.22.4",
 ]
 
 [[package]]
diff --git a/core/Cargo.toml b/core/Cargo.toml
index d4572ded4..10bbd2485 100644
--- a/core/Cargo.toml
+++ b/core/Cargo.toml
@@ -288,7 +288,7 @@ serde = { version = "1", features = ["derive"] }
 serde_json = "1"
 sha2 = { version = "0.10", optional = true }
 sled = { version = "0.34.7", optional = true }
-suppaftp = { version = "4.5", default-features = false, features = [
+suppaftp = { version = "5.2", default-features = false, features = [
   "async-secure",
   "async-rustls",
 ], optional = true }