Compare commits
2 Commits
84f7009ad2
...
8b0f01e606
Author | SHA1 | Date | |
---|---|---|---|
8b0f01e606 | |||
beda8c151d |
18
Cargo.toml
18
Cargo.toml
@ -10,26 +10,24 @@ resolver = "2"
|
||||
|
||||
[features]
|
||||
default = ["tcp", "log"]
|
||||
tcp = ["tokio/net"]
|
||||
unix = ["tokio/net"]
|
||||
log = ["dep:log", "dep:env_logger"]
|
||||
tcp = []
|
||||
unix = []
|
||||
log = []
|
||||
|
||||
[dependencies]
|
||||
proc-macro2 = "1.0.85"
|
||||
quote = "1.0.36"
|
||||
ron = "0.8.1"
|
||||
serde = { version = "1.0.203", features = ["serde_derive"] }
|
||||
syn = "2.0.66"
|
||||
tokio = { version = "1.38.0", features = ["sync", "io-util"] }
|
||||
env_logger = { version = "0.11.3", optional = true }
|
||||
log = { version = "0.4.21", optional = true }
|
||||
|
||||
[dev-dependencies]
|
||||
# tokio = { version = "1.38.0", features = ["sync", "io-util"] }
|
||||
ron = "0.8.1"
|
||||
serde = { version = "1.0.203", features = ["serde_derive"] }
|
||||
rand = "0.8.5"
|
||||
tokio = { version = "1.38.0", features = ["sync", "rt-multi-thread", "macros", "time", "io-util", "net"] }
|
||||
env_logger = "0.11.3"
|
||||
log = "0.4.21"
|
||||
tokio-test = "0.4.4"
|
||||
env_logger = { version = "0.11.3" }
|
||||
log = { version = "0.4.21" }
|
||||
|
||||
[lib]
|
||||
proc-macro = true
|
||||
|
@ -9,6 +9,8 @@ Eagle is still in early development. Performance is not ideal, the interface is
|
||||
Eagle is a library which allows you to easily build an [RPC](https://en.wikipedia.org/wiki/Remote_procedure_call) protocol.
|
||||
It uses a macro to generate the required communication code and makes adding new functions easy and quick. Eagle is designed to work specifically with [`tokio`](https://crates.io/crates/tokio) and uses [`serde`](https://crates.io/crates/serde) for formatting data.
|
||||
|
||||
Please note that since `eagle` is a pure proc-macro library, you must manually add compatible versions of `tokio`, `serde`, `ron` and optionally `log` to your dependencies.
|
||||
|
||||
## Using Eagle
|
||||
|
||||
The way that `eagle` is designed to be used is inside a shared dependency between your "server" and your "client". Both of these should be in a workspace. Create a `shared` crate which both components should depend on, this crate should have `eagle` as a dependency. By default `eagle` uses TCP for communication, but you may disable default features and enable the `unix` feature on `eagle` to use unix sockets instead.
|
||||
|
Loading…
Reference in New Issue
Block a user