mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
383482a36e
- locally we open a stream, our local Drain is sending OpenStream - remote Sink will know this and notify remote Drain - remote side sends a message - local sink does not know about the Stream. as there is (and CANT) be a wat to notify local Sink from local Drain (it could introduce race conditions). One of the possible solutions was, that the remote drain will copy the OpenStream Msg ON the Quic::stream before first data is send. This would work but is complicated. Instead we now just mark such streams as "potentially open" and we listen for the first DataHeader to get it's SID. add support for unreliable messages in quic protocol, benchmarks
71 lines
2.1 KiB
TOML
71 lines
2.1 KiB
TOML
[package]
|
|
name = "veloren-network"
|
|
version = "0.3.0"
|
|
authors = ["Marcel Märtens <marcel.cochem@googlemail.com>"]
|
|
edition = "2018"
|
|
|
|
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
|
|
|
[features]
|
|
metrics = ["prometheus", "network-protocol/metrics"]
|
|
compression = ["lz-fear"]
|
|
quic = ["quinn"]
|
|
|
|
default = ["metrics","compression","quinn"]
|
|
|
|
[dependencies]
|
|
|
|
network-protocol = { package = "veloren-network-protocol", path = "protocol" }
|
|
|
|
#serialisation
|
|
bincode = "1.3.1"
|
|
serde = { version = "1.0" }
|
|
#sending
|
|
crossbeam-channel = "0.5"
|
|
tokio = { version = "1.2", default-features = false, features = ["io-util", "macros", "rt", "net", "time"] }
|
|
tokio-stream = { version = "0.1.2", default-features = false }
|
|
#tracing and metrics
|
|
tracing = { version = "0.1", default-features = false, features = ["attributes"]}
|
|
prometheus = { version = "0.12", default-features = false, optional = true }
|
|
#async
|
|
futures-core = { version = "0.3", default-features = false }
|
|
futures-util = { version = "0.3.7", default-features = false, features = ["std"] }
|
|
async-channel = "1.5.1" #use for .close() channels
|
|
#mpsc channel registry
|
|
lazy_static = { version = "1.4", default-features = false }
|
|
rand = { version = "0.8" }
|
|
#quic support
|
|
quinn = { version = "0.7.2", optional = true }
|
|
#stream flags
|
|
bitflags = "1.2.1"
|
|
lz-fear = { version = "0.1.1", optional = true }
|
|
# async traits
|
|
async-trait = "0.1.42"
|
|
bytes = "^1"
|
|
|
|
[dev-dependencies]
|
|
tracing-subscriber = { version = "0.2.3", default-features = false, features = ["env-filter", "fmt", "chrono", "ansi", "smallvec"] }
|
|
tokio = { version = "1.2", default-features = false, features = ["io-std", "fs", "rt-multi-thread"] }
|
|
futures-util = { version = "0.3.7", default-features = false, features = ["sink", "std"] }
|
|
clap = { version = "2.33", default-features = false }
|
|
shellexpand = "2.0.0"
|
|
serde = { version = "1.0", features = ["derive"] }
|
|
prometheus-hyper = "0.1.2"
|
|
criterion = { version = "0.3.4", features = ["default", "async_tokio"] }
|
|
|
|
[[bench]]
|
|
name = "speed"
|
|
harness = false
|
|
|
|
[[example]]
|
|
name = "fileshare"
|
|
|
|
[[example]]
|
|
name = "network-speed"
|
|
|
|
[[example]]
|
|
name = "chat"
|
|
|
|
[[example]]
|
|
name = "tcp_loadtest"
|