mirror of
https://github.com/google/comprehensive-rust.git
synced 2025-03-05 08:25:26 +02:00
Update all dependencies (#1610)
This resolves a few Dependabot alerts on `zerocopy` and refreshes the other direct dependencies.
This commit is contained in:
parent
6c84b0aaf4
commit
a99a86dc50
594
Cargo.lock
generated
594
Cargo.lock
generated
File diff suppressed because it is too large
Load Diff
@ -5,4 +5,4 @@ edition = "2021"
|
||||
publish = false
|
||||
|
||||
[dependencies]
|
||||
zerocopy = "0.6.1"
|
||||
zerocopy = { version = "0.7.31", features = ["derive"] }
|
||||
|
@ -25,9 +25,9 @@ You are going to need the following functions from `tokio` and
|
||||
[`tokio_websockets`][2]. Spend a few minutes to familiarize yourself with the
|
||||
API.
|
||||
|
||||
- [StreamExt::next()][3] implemented by `WebsocketStream`: for asynchronously
|
||||
- [StreamExt::next()][3] implemented by `WebSocketStream`: for asynchronously
|
||||
reading messages from a Websocket Stream.
|
||||
- [SinkExt::send()][4] implemented by `WebsocketStream`: for asynchronously
|
||||
- [SinkExt::send()][4] implemented by `WebSocketStream`: for asynchronously
|
||||
sending messages on a Websocket Stream.
|
||||
- [Lines::next_line()][5]: for asynchronously reading user messages
|
||||
from the standard input.
|
||||
@ -101,7 +101,7 @@ cargo run --bin client
|
||||
clients, but the sender of the message.
|
||||
|
||||
[1]: https://docs.rs/tokio/latest/tokio/sync/broadcast/fn.channel.html
|
||||
[2]: https://docs.rs/tokio-websockets/0.4.0/tokio_websockets/
|
||||
[2]: https://docs.rs/tokio-websockets/
|
||||
[3]: https://docs.rs/futures-util/0.3.28/futures_util/stream/trait.StreamExt.html#method.next
|
||||
[4]: https://docs.rs/futures-util/0.3.28/futures_util/sink/trait.SinkExt.html#method.send
|
||||
[5]: https://docs.rs/tokio/latest/tokio/io/struct.Lines.html#method.next_line
|
||||
|
@ -5,6 +5,6 @@ edition = "2021"
|
||||
|
||||
[dependencies]
|
||||
futures-util = { version = "0.3.28", features = ["sink"] }
|
||||
http = "0.2.9"
|
||||
http = "1.0.0"
|
||||
tokio = { version = "1.28.1", features = ["full"] }
|
||||
tokio-websockets = { version = "0.4.0", features = ["client", "fastrand", "server", "sha1_smol"] }
|
||||
tokio-websockets = { version = "0.5.0", features = ["client", "fastrand", "server", "sha1_smol"] }
|
||||
|
@ -20,13 +20,13 @@ use std::error::Error;
|
||||
use std::net::SocketAddr;
|
||||
use tokio::net::{TcpListener, TcpStream};
|
||||
use tokio::sync::broadcast::{channel, Sender};
|
||||
use tokio_websockets::{Message, ServerBuilder, WebsocketStream};
|
||||
use tokio_websockets::{Message, ServerBuilder, WebSocketStream};
|
||||
// ANCHOR_END: setup
|
||||
|
||||
// ANCHOR: handle_connection
|
||||
async fn handle_connection(
|
||||
addr: SocketAddr,
|
||||
mut ws_stream: WebsocketStream<TcpStream>,
|
||||
mut ws_stream: WebSocketStream<TcpStream>,
|
||||
bcast_tx: Sender<String>,
|
||||
) -> Result<(), Box<dyn Error + Send + Sync>> {
|
||||
// ANCHOR_END: handle_connection
|
||||
|
@ -22,4 +22,4 @@ path = "exercise.rs"
|
||||
|
||||
[dependencies]
|
||||
googletest = "0.10.0"
|
||||
mockall = "0.11.4"
|
||||
mockall = "0.12.0"
|
||||
|
Loading…
x
Reference in New Issue
Block a user