Skip to content
Merged
Show file tree
Hide file tree
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
39 changes: 0 additions & 39 deletions Cargo.lock

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

29 changes: 20 additions & 9 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,18 +14,18 @@ rust-version = "1.76"

[dependencies]
# we require serde even in non-rpc mode
serde = { version = "1", default-features = false }
serde = { workspace = true }
# just for the oneshot and mpsc queues
tokio = { version = "1.44", features = ["sync"], default-features = false }
tokio = { workspace = true, features = ["sync"] }
# for PollSender (which for some reason is not available in the main tokio api)
tokio-util = { version = "0.7.14", default-features = false }
# errors
thiserror = "2.0.12"

# used in the endpoint handler code when using rpc
tracing = { version = "0.1.41", optional = true }
tracing = { workspace = true, optional = true }
# used to ser/de messages when using rpc
postcard = { version = "1.1.1", features = ["alloc", "use-std"], optional = true }
postcard = { workspace = true, features = ["alloc", "use-std"], optional = true }
# currently only transport when using rpc
quinn = { version = "0.13.0", package = "iroh-quinn", optional = true }
# used as a buffer for serialization when using rpc
Expand All @@ -35,22 +35,23 @@ rustls = { version = "0.23.5", default-features = false, features = ["std"], opt
# used in the test utils to generate quinn endpoints
rcgen = { version = "0.13.2", optional = true }
# used in the test utils to generate quinn endpoints
anyhow = { version = "1.0.66", optional = true }
anyhow = { workspace = true, optional = true }
# used in the benches
futures-buffered ={ version = "0.2.9", optional = true }

[dev-dependencies]
tracing-subscriber = { version = "0.3.19", features = ["fmt"] }
tracing-subscriber = { workspace = true, features = ["fmt"] }
# used in the derive example. This must not be a main crate dep or else it will be circular!
irpc-derive = { version = "0.1.0", path = "./irpc-derive" }
# just convenient for the enum definitions
# just convenient for the enum definitions, in the manual example
derive_more = { version = "2", features = ["from"] }
# we need full for example main etc.
tokio = { version = "1", features = ["full"] }
tokio = { workspace = true, features = ["full"] }
# formatting
thousands = "0.2.0"
# for AbortOnDropHandle
n0-future = { version = "0.1.2" }
n0-future = { workspace = true }
# macro tests
trybuild = "1.0.104"

[features]
Expand All @@ -71,3 +72,13 @@ rustdoc-args = ["--cfg", "quicrpc_docsrs"]

[lints.rust]
unexpected_cfgs = { level = "warn", check-cfg = ["cfg(quicrpc_docsrs)"] }

[workspace.dependencies]
anyhow = { version = "1.0.66" }
tokio = { version = "1.44", default-features = false }
postcard = { version = "1.1.1", default-features = false }
serde = { version = "1", default-features = false }
tracing = { version = "0.1.41", default-features = false }
n0-future = { version = "0.1.2", default-features = false }
tracing-subscriber = { version = "0.3.19", default-features = false }
iroh = { version = "0.34" }
2 changes: 1 addition & 1 deletion examples/compute.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ enum ComputeRequest {
}

// Define the protocol and message enums using the macro
#[rpc_requests(ComputeService, ComputeMessage)]
#[rpc_requests(ComputeService, message = ComputeMessage)]
#[derive(Serialize, Deserialize)]
enum ComputeProtocol {
#[rpc(tx=oneshot::Sender<u128>)]
Expand Down
2 changes: 1 addition & 1 deletion examples/derive.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ struct Set {

// Use the macro to generate both the StorageProtocol and StorageMessage enums
// plus implement Channels for each type
#[rpc_requests(StorageService, StorageMessage)]
#[rpc_requests(StorageService, message = StorageMessage)]
#[derive(Serialize, Deserialize)]
enum StorageProtocol {
#[rpc(tx=oneshot::Sender<Option<String>>)]
Expand Down
Loading
Loading