From f6f44784fff5488bb59d563ee7ff7b94c08a48c1 Mon Sep 17 00:00:00 2001 From: hozan23 Date: Sun, 19 May 2024 23:41:31 +0200 Subject: use cargo features to enable/disable protocols for net crate --- jsonrpc/Cargo.toml | 8 ++++++-- jsonrpc/examples/tokio_server/Cargo.lock | 16 ---------------- 2 files changed, 6 insertions(+), 18 deletions(-) (limited to 'jsonrpc') diff --git a/jsonrpc/Cargo.toml b/jsonrpc/Cargo.toml index cf49d6e..719543e 100644 --- a/jsonrpc/Cargo.toml +++ b/jsonrpc/Cargo.toml @@ -22,7 +22,12 @@ tokio = [ [dependencies] karyon_core = { workspace = true, default-features = false } -karyon_net = { workspace = true, default-features = false } +karyon_net = { workspace = true, default-features = false, features = [ + "tcp", + "unix", + "tls", + "ws", +] } karyon_jsonrpc_macro = { path = "jsonrpc_macro", default-features = false } @@ -32,7 +37,6 @@ async-tungstenite = { version = "0.25.0", default-features = false } serde = { version = "1.0.197", features = ["derive"] } serde_json = "1.0.114" thiserror = "1.0.58" -memchr = "2.7.1" async-trait = "0.1.77" futures-rustls = { version = "0.25.1", optional = true } diff --git a/jsonrpc/examples/tokio_server/Cargo.lock b/jsonrpc/examples/tokio_server/Cargo.lock index 0fe9893..c42c2bf 100644 --- a/jsonrpc/examples/tokio_server/Cargo.lock +++ b/jsonrpc/examples/tokio_server/Cargo.lock @@ -127,19 +127,6 @@ dependencies = [ "tungstenite", ] -[[package]] -name = "asynchronous-codec" -version = "0.7.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a860072022177f903e59730004fb5dc13db9275b79bb2aef7ba8ce831956c233" -dependencies = [ - "bytes", - "futures-sink", - "futures-util", - "memchr", - "pin-project-lite", -] - [[package]] name = "autocfg" version = "1.3.0" @@ -535,11 +522,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3d6401deb83407ab3da39eba7e33987a73c3df0c82b4bb5813ee871c19c41d48" dependencies = [ "futures-core", - "futures-io", "futures-macro", "futures-sink", "futures-task", - "memchr", "pin-project-lite", "pin-utils", "slab", @@ -739,7 +724,6 @@ dependencies = [ "async-channel", "async-trait", "async-tungstenite", - "asynchronous-codec", "bincode", "futures-util", "karyon_core", -- cgit v1.2.3