From e4f7beb257aa1b4447fe8aa03e3032dd93f243d8 Mon Sep 17 00:00:00 2001 From: Wenqi Mou Date: Mon, 22 Mar 2021 08:43:38 -0700 Subject: [PATCH] Fix release error (#235) --- .github/workflows/documentation.yml | 2 +- .github/workflows/python_test.yml | 6 +++--- Cargo.toml | 18 +++++++++--------- auth/Cargo.toml | 8 ++++---- auth/README.md | 2 ++ bindings/Cargo.toml | 14 +++++++------- bindings/{Readme.md => README.md} | 0 channel/Cargo.toml | 4 ++-- channel/README.md | 2 ++ channel/src/lib.rs | 5 +++++ config/Cargo.toml | 10 +++++----- config/README.md | 2 ++ config/src/lib.rs | 2 +- connection_pool/Cargo.toml | 6 +++--- connection_pool/README.md | 2 ++ controller-client/Cargo.toml | 15 +++++++-------- controller-client/{Readme.md => README.md} | 0 controller-client/src/lib.rs | 2 +- examples/Cargo.toml | 8 ++++---- integration_test/Cargo.toml | 4 ++-- integration_test/build.rs | 6 +++--- integration_test/src/disconnection_tests.rs | 4 ++-- retry/Cargo.toml | 4 ++-- retry/README.md | 2 ++ shared/Cargo.toml | 4 ++-- shared/{Readme.md => README.md} | 0 src/byte_stream.rs | 2 +- src/event_stream_writer.rs | 2 +- src/segment_reader.rs | 5 +++-- src/segment_slice.rs | 1 + src/transaction/mod.rs | 2 +- wire_protocol/Cargo.toml | 12 ++++++------ wire_protocol/README.md | 3 +++ 33 files changed, 89 insertions(+), 70 deletions(-) create mode 100644 auth/README.md rename bindings/{Readme.md => README.md} (100%) create mode 100644 channel/README.md create mode 100644 config/README.md create mode 100644 connection_pool/README.md rename controller-client/{Readme.md => README.md} (100%) create mode 100644 retry/README.md rename shared/{Readme.md => README.md} (100%) create mode 100644 wire_protocol/README.md diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 06032a037..a7a85f314 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -33,7 +33,7 @@ jobs: - name: Generate Pravega Python API documentation. run: | - pip install maturin virtualenv pdoc3 + pip install 'maturin==0.8.3' virtualenv pdoc3 virtualenv venv source venv/bin/activate maturin develop -m bindings/Cargo.toml diff --git a/.github/workflows/python_test.yml b/.github/workflows/python_test.yml index d94463d59..583cedb94 100644 --- a/.github/workflows/python_test.yml +++ b/.github/workflows/python_test.yml @@ -24,9 +24,9 @@ jobs: java-version: '11' # The JDK version to make available on the path. - name: Download and Run Pravega standalone run: | - wget https://github.com/Tristan1900/pravega/releases/download/hostname/pravega-0.9.0-2711.b899fe6-SNAPSHOT.tgz - tar -xzvf pravega-0.9.0-2711.b899fe6-SNAPSHOT.tgz - pravega-0.9.0-2711.b899fe6-SNAPSHOT/bin/pravega-standalone > pravega.log 2>&1 & + wget https://github.com/pravega/pravega/releases/download/v0.9.0/pravega-0.9.0.tgz + tar -xzvf pravega-0.9.0.tgz + pravega-0.9.0/bin/pravega-standalone > pravega.log 2>&1 & sleep 120 && echo "Started standalone" - name: Set up Python uses: actions/setup-python@v2 diff --git a/Cargo.toml b/Cargo.toml index 2180a7af3..a2ee5a75e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -9,7 +9,7 @@ name = "pravega-client" # - Create git tag. version = "0.1.0" edition = "2018" -categories = ["Network programming"] +categories = ["network-programming"] keywords = ["streaming", "client", "pravega"] readme = "README.md" documentation = "https://docs.rs/pravega-client/0.1.0/" @@ -38,14 +38,14 @@ members = [ ] [dependencies] -pravega-client-shared = { path = "./shared"} -pravega-controller-client = { path = "./controller-client"} -pravega-wire-protocol = { path = "./wire_protocol"} -pravega-client-retry = {path = "./retry"} -pravega-connection-pool = {path = "connection_pool" } -pravega-client-channel = {path = "./channel"} -pravega-client-auth = {path = "./auth"} -pravega-client-config = {path = "./config"} +pravega-client-shared = { path = "./shared", version = "0.1"} +pravega-controller-client = { path = "./controller-client", version = "0.1"} +pravega-wire-protocol = { path = "./wire_protocol", version = "0.1"} +pravega-client-retry = {path = "./retry", version = "0.1"} +pravega-connection-pool = {path = "./connection_pool", version = "0.1" } +pravega-client-channel = {path = "./channel", version = "0.1"} +pravega-client-auth = {path = "./auth", version = "0.1"} +pravega-client-config = {path = "./config", version = "0.1"} async-trait = "0.1" futures = "0.3" snafu = "0.6" diff --git a/auth/Cargo.toml b/auth/Cargo.toml index b6cda3af6..447ce2077 100644 --- a/auth/Cargo.toml +++ b/auth/Cargo.toml @@ -2,9 +2,9 @@ name = "pravega-client-auth" version = "0.1.0" edition = "2018" -categories = ["Network programming"] +categories = ["network-programming"] keywords = ["streaming", "client", "pravega"] -readme = "Readme.md" +readme = "README.md" repository = "https://github.com/pravega/pravega-client-rust" license = "Apache-2.0" description = "An internal library used by the Rust client for Pravega." @@ -14,8 +14,8 @@ authors = ["Tom Kaitchuck ", "Wenqi Mou ChannelSender { Ok(()) } + pub fn send_without_bp(&self, message: T) -> Result<(), SendError<(T, usize)>> { + self.sender.send((message, 0))?; + Ok(()) + } + pub fn remain(&self) -> usize { self.semaphore.permits() } diff --git a/config/Cargo.toml b/config/Cargo.toml index 8d90a7e0f..3da99bceb 100644 --- a/config/Cargo.toml +++ b/config/Cargo.toml @@ -2,9 +2,9 @@ name = "pravega-client-config" version = "0.1.0" edition = "2018" -categories = ["Network programming"] +categories = ["network-programming"] keywords = ["streaming", "client", "pravega"] -readme = "Readme.md" +readme = "README.md" repository = "https://github.com/pravega/pravega-client-rust" license = "Apache-2.0" description = "An internal library used by the Rust client for Pravega." @@ -14,13 +14,13 @@ authors = ["Tom Kaitchuck ", "Wenqi Mou Duration { - Duration::from_secs(3600) + Duration::from_secs(30) } } diff --git a/connection_pool/Cargo.toml b/connection_pool/Cargo.toml index e186a4233..0db2a582e 100644 --- a/connection_pool/Cargo.toml +++ b/connection_pool/Cargo.toml @@ -2,9 +2,9 @@ name = "pravega-connection-pool" version = "0.1.0" edition = "2018" -categories = ["Network programming"] +categories = ["network-programming"] keywords = ["streaming", "client", "pravega"] -readme = "Readme.md" +readme = "README.md" repository = "https://github.com/pravega/pravega-client-rust" license = "Apache-2.0" description = "A connection pool used by the Pravega Rust client." @@ -14,7 +14,7 @@ authors = ["Tom Kaitchuck ", "Wenqi Mou ", "Wenqi Mou ", "Wenxiao Zhang "] [dependencies] -pravega-client-shared = { path = "../shared"} -pravega-wire-protocol = { path = "../wire_protocol"} -pravega-connection-pool = {path= "../connection_pool" } -pravega-client-retry = {path = "../retry"} -pravega-client-config = { path = "../config"} +pravega-client-shared = { path = "../shared", version = "0.1"} +pravega-wire-protocol = { path = "../wire_protocol", version = "0.1"} +pravega-client-retry = {path = "../retry", version = "0.1"} +pravega-connection-pool = {path = "../connection_pool", version = "0.1" } +pravega-client-config = {path = "../config", version = "0.1"} async-trait = "0.1" prost = "0.7" snafu = "0.6" @@ -32,7 +32,6 @@ im = "15" tracing = "0.1" jsonwebtoken = "7" serde = {version = "1.0", features = ["derive"] } -h2 = "0.2" [build-dependencies] tonic-build = "0.3" diff --git a/controller-client/Readme.md b/controller-client/README.md similarity index 100% rename from controller-client/Readme.md rename to controller-client/README.md diff --git a/controller-client/src/lib.rs b/controller-client/src/lib.rs index edeb5c6ca..f802d43ea 100644 --- a/controller-client/src/lib.rs +++ b/controller-client/src/lib.rs @@ -1216,7 +1216,7 @@ mod test { #[test] fn test_controller_client() { - let mut rt = Runtime::new().unwrap(); + let rt = Runtime::new().unwrap(); rt.spawn(run_server()); let config = ClientConfigBuilder::default() diff --git a/examples/Cargo.toml b/examples/Cargo.toml index 26aa3ae0c..f1755f39c 100644 --- a/examples/Cargo.toml +++ b/examples/Cargo.toml @@ -2,7 +2,7 @@ name = "pravega-rust-client-examples" version = "0.1.0" edition = "2018" -categories = ["Network programming"] +categories = ["network-programming"] keywords = ["streaming", "client", "pravega"] readme = "Readme.md" repository = "https://github.com/pravega/pravega-client-rust" @@ -14,9 +14,9 @@ authors = ["Tom Kaitchuck ", "Wenqi Mou { let len = reply.data.len(); + debug!("read data length of {}", len); if len == 0 && reply.end_of_segment { info!("Reached end of segment {:?} during read ", segment.clone()); let data = SegmentSealed { diff --git a/src/transaction/mod.rs b/src/transaction/mod.rs index c22c951fe..b1d9625f8 100644 --- a/src/transaction/mod.rs +++ b/src/transaction/mod.rs @@ -270,7 +270,7 @@ impl Transaction { impl Drop for Transaction { fn drop(&mut self) { - let _res = self.sender.send((Incoming::Close(), 0)); + let _res = self.sender.send_without_bp(Incoming::Close()); } } diff --git a/wire_protocol/Cargo.toml b/wire_protocol/Cargo.toml index 155729ebd..95989ee65 100644 --- a/wire_protocol/Cargo.toml +++ b/wire_protocol/Cargo.toml @@ -2,9 +2,9 @@ name = "pravega-wire-protocol" version = "0.1.0" edition = "2018" -categories = ["Network programming"] +categories = ["network-programming"] keywords = ["streaming", "client", "pravega"] -readme = "Readme.md" +readme = "README.md" repository = "https://github.com/pravega/pravega-client-rust" license = "Apache-2.0" description = "An internal library used by the Pravega Rust client." @@ -14,10 +14,10 @@ authors = ["Tom Kaitchuck ", "Wenqi Mou