Skip to content

Commit 3c4fa27

Browse files
committed
Dump version 0.2.0
1 parent 0431737 commit 3c4fa27

11 files changed

Lines changed: 28 additions & 24 deletions

File tree

Cargo.toml

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ members = ["core", "codec", "macros", "runtime/tokio", "runtime/smol", "stream",
33

44
[package]
55
name = "occams-rpc"
6-
version = "0.1.1"
6+
version = "0.2.0"
77
edition = "2024"
88
authors = ["plan <frostyplanet@gmail.com>"]
99
categories = ["concurrency", "network-programming"]
@@ -22,19 +22,18 @@ log = { version = "0.4", features = ["std", "kv_unstable"] }
2222
captains-log = ">=0.15"
2323
io-buffer = "1"
2424
serde = "1"
25-
occams-rpc-core = {path="core/", version="0"}
26-
occams-rpc-codec = {path="codec/", version="0", features=["msgpack"]}
27-
occams-rpc-stream = {path="stream/", version="0"}
28-
occams-rpc-api-macros = { path = "macros", version = "0" }
29-
occams-rpc-tokio = {path="runtime/tokio/", version = "0", optional=true}
30-
occams-rpc-smol = {path="runtime/smol/", version = "0", features=["global"], optional=true}
25+
occams-rpc-core = {path="core/", version=">=0.2"}
26+
occams-rpc-codec = {path="codec/", version=">=0.2", features=["msgpack"]}
27+
occams-rpc-stream = {path="stream/", version=">=0.2"}
28+
occams-rpc-api-macros = { path = "macros", version = ">=0.2" }
3129
async-trait = "0"
3230
rustc-hash = "2"
3331
crossfire = "2.1"
3432

3533
[dev-dependencies]
3634
serde_derive = "1"
3735
occams-rpc-smol = {path="runtime/smol/", version = "0", features=["global"]}
36+
occams-rpc-tokio = {path="runtime/tokio/", version = "0"}
3837
nix = "0"
3938
occams-rpc-tcp = {path="transport/tcp/", version = "0"}
4039
occams-rpc-codec = {path="codec/", version="0", features=["msgpack"]}

codec/Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "occams-rpc-codec"
3-
version = "0.1.0"
3+
version = "0.2.0"
44
edition = "2024"
55
authors = ["plan <frostyplanet@gmail.com>"]
66
categories = ["concurrency", "network-programming"]
@@ -16,7 +16,7 @@ with a low-level streaming interface, and high-level remote API call interface.
1616
"""
1717

1818
[dependencies]
19-
occams-rpc-core = {path="../core", version="0"}
19+
occams-rpc-core = {path="../core", version=">=0.2"}
2020
serde = "1"
2121
rmp-serde = {version=">=1.1.1", optional=true}
2222
log = "0.4"

core/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "occams-rpc-core"
3-
version = "0.1.1"
3+
version = "0.2.0"
44
edition = "2024"
55
authors = ["plan <frostyplanet@gmail.com>"]
66
categories = ["concurrency", "network-programming"]

macros/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "occams-rpc-api-macros"
3-
version = "0.1.0"
3+
version = "0.2.0"
44
edition = "2021"
55

66
[lib]

runtime/smol/Cargo.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "occams-rpc-smol"
3-
version = "0.1.1"
3+
version = "0.2.0"
44
edition = "2024"
55
authors = ["plan <frostyplanet@gmail.com>"]
66
categories = ["concurrency", "network-programming"]
@@ -17,8 +17,8 @@ with a low-level streaming interface, and high-level remote API call interface.
1717

1818
[dependencies]
1919
futures = "0.3"
20-
occams-rpc-core = { path = "../../core/", version="0" }
21-
occams-rpc-stream = { path = "../../stream", version="0" }
20+
occams-rpc-core = { path = "../../core/", version=">=0.2" }
21+
occams-rpc-stream = { path = "../../stream", version=">=0.2" }
2222
async-io = "2.6"
2323
async-executor = "1"
2424
smol = {version="2", optional=true}

runtime/smol/src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,12 +31,14 @@ use std::time::{Duration, Instant};
3131
pub struct SmolRT(Option<Arc<Executor<'static>>>);
3232

3333
impl SmolRT {
34+
/// spawn coroutine with smol::spawn, run globally
3435
#[cfg(feature = "global")]
3536
#[inline]
3637
pub fn new_global() -> Self {
3738
Self(None)
3839
}
3940

41+
/// spawn coroutine with specified Executor
4042
#[inline]
4143
pub fn new(executor: Arc<Executor<'static>>) -> Self {
4244
Self(Some(executor))
@@ -93,6 +95,7 @@ impl AsyncIO for SmolRT {
9395
Ok(SmolFD(Async::new(fd)?))
9496
}
9597

98+
/// Depends on how you initialize SmolRT, spawn with executor or globally
9699
#[inline]
97100
fn spawn_detach<F, R>(&self, f: F)
98101
where

runtime/tokio/Cargo.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "occams-rpc-tokio"
3-
version = "0.1.1"
3+
version = "0.2.0"
44
edition = "2024"
55
authors = ["plan <frostyplanet@gmail.com>"]
66
categories = ["concurrency", "network-programming"]
@@ -17,8 +17,8 @@ with a low-level streaming interface, and high-level remote API call interface.
1717

1818
[dependencies]
1919
tokio = { version = "1", features = ["net", "time", "rt"] }
20-
occams-rpc-core = { path = "../../core/", version="0" }
21-
occams-rpc-stream = { path = "../../stream", version="0" }
20+
occams-rpc-core = { path = "../../core/", version=">=0.2" }
21+
occams-rpc-stream = { path = "../../stream", version=">=0.2" }
2222

2323
[package.metadata.docs.rs]
2424
all-features = true

runtime/tokio/src/lib.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ use tokio::runtime::Handle;
2929
pub struct TokioRT(Handle);
3030

3131
impl TokioRT {
32+
/// Capture a tokio runtime handle to ensure background task can spawn
3233
#[inline]
3334
pub fn new(handle: Handle) -> Self {
3435
Self(handle)
@@ -86,6 +87,7 @@ impl AsyncIO for TokioRT {
8687
Ok(TokioFD(io::unix::AsyncFd::with_interest(fd, Interest::READABLE | Interest::WRITABLE)?))
8788
}
8889

90+
/// spawn background coroutine with captured runtime handle
8991
#[inline]
9092
fn spawn_detach<F, R>(&self, f: F)
9193
where

stream/Cargo.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "occams-rpc-stream"
3-
version = "0.1.0"
3+
version = "0.2.0"
44
edition = "2024"
55
authors = ["plan <frostyplanet@gmail.com>"]
66
categories = ["concurrency", "network-programming"]
@@ -16,8 +16,8 @@ with a low-level streaming interface, and high-level remote API call interface.
1616
"""
1717

1818
[dependencies]
19-
occams-rpc-core = {path="../core/", version="0"}
20-
occams-rpc-stream-macros = {path="macros", version="0"}
19+
occams-rpc-core = {path="../core/", version=">=0.2"}
20+
occams-rpc-stream-macros = {path="macros", version=">=0.2"}
2121
log = { version = "0.4", features = ["std", "kv_unstable"] }
2222
captains-log = ">=0.15"
2323
futures = "0.3"

stream/macros/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "occams-rpc-stream-macros"
3-
version = "0.1.1"
3+
version = "0.2.0"
44
edition = "2024"
55
authors = ["plan <frostyplanet@gmail.com>"]
66
categories = ["concurrency", "network-programming"]

0 commit comments

Comments
 (0)