Skip to content

Commit 2765ca2

Browse files
authored
Update salvo to 0.67 (#8846)
* Update salvo to 0.67 * remove useless import
1 parent 59ee5aa commit 2765ca2

10 files changed

+13
-13
lines changed

frameworks/Rust/salvo/Cargo.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,16 +40,16 @@ anyhow = "1"
4040
async-trait = "0.1"
4141
bytes = "1"
4242
diesel = { version = "2", features = ["postgres", "r2d2"] }
43-
deadpool = { version = "0.10", features = ["rt_tokio_1", "serde", "async-trait", "managed"] }
44-
deadpool-postgres = "0.11"
43+
deadpool = { version = "0.11", features = ["rt_tokio_1", "serde", "managed"] }
44+
deadpool-postgres = "0.13"
4545
futures-util = "0.3"
4646
lru = "0.12.0"
4747
markup = "0.15"
4848
# mimalloc = { version = "0.1", default-features = false }
4949
mongodb = { version = "2.4.0", features = ["zstd-compression", "snappy-compression", "zlib-compression"] }
5050
once_cell = "1"
5151
rand = { version = "0.8", features = ["min_const_gen", "small_rng"] }
52-
salvo = { version = "0.63", default-features = false, features = ["anyhow", "server", "http1", "affix"] }
52+
salvo = { version = "0.67", default-features = false, features = ["anyhow", "server", "http1", "affix"] }
5353
serde = { version = "1", features = ["derive"] }
5454
serde_json = "1"
5555
# smallvec = "1"

frameworks/Rust/salvo/salvo-diesel.dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM rust:1.74
1+
FROM rust:1.77
22

33
ENV TECHEMPOWER_POSTGRES_URL=postgres://benchmarkdbuser:benchmarkdbpass@tfb-database/hello_world
44
ENV TECHEMPOWER_MAX_POOL_SIZE=28

frameworks/Rust/salvo/salvo-lru.dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM rust:1.74
1+
FROM rust:1.77
22

33
ENV TECHEMPOWER_POSTGRES_URL=postgres://benchmarkdbuser:benchmarkdbpass@tfb-database/hello_world
44

frameworks/Rust/salvo/salvo-mongo-raw.dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM rust:1.74
1+
FROM rust:1.77
22

33
ENV TECHEMPOWER_MONGODB_URL=mongodb://tfb-database:27017
44
ENV TECHEMPOWER_MAX_POOL_SIZE=28

frameworks/Rust/salvo/salvo-mongo.dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM rust:1.74
1+
FROM rust:1.77
22

33
ENV TECHEMPOWER_MONGODB_URL=mongodb://tfb-database:27017
44
ENV TECHEMPOWER_MAX_POOL_SIZE=28

frameworks/Rust/salvo/salvo-pg-pool.dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM rust:1.74
1+
FROM rust:1.77
22

33
ENV TECHEMPOWER_POSTGRES_URL=postgres://benchmarkdbuser:benchmarkdbpass@tfb-database/hello_world
44
ENV TECHEMPOWER_MAX_POOL_SIZE=28

frameworks/Rust/salvo/salvo-pg.dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM rust:1.74
1+
FROM rust:1.77
22

33
ENV TECHEMPOWER_POSTGRES_URL=postgres://benchmarkdbuser:benchmarkdbpass@tfb-database/hello_world
44

frameworks/Rust/salvo/salvo-sqlx.dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM rust:1.74
1+
FROM rust:1.77
22

33
ENV TECHEMPOWER_POSTGRES_URL=postgres://benchmarkdbuser:benchmarkdbpass@tfb-database/hello_world
44
ENV TECHEMPOWER_MAX_POOL_SIZE=56

frameworks/Rust/salvo/salvo.dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM rust:1.74
1+
FROM rust:1.77
22

33
ADD ./ /salvo
44
WORKDIR /salvo

frameworks/Rust/salvo/src/main.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
use std::sync::Arc;
55

66
use bytes::Bytes;
7-
use salvo::conn::tcp::TcpAcceptor;
87
use salvo::http::body::ResBody;
98
use salvo::http::header::{self, HeaderValue};
109
use salvo::prelude::*;
@@ -50,7 +49,8 @@ fn main() {
5049
}
5150

5251
async fn serve(router: Arc<Router>) {
53-
let acceptor: TcpAcceptor = utils::reuse_listener().unwrap().try_into().unwrap();
52+
// let acceptor: TcpAcceptor = utils::reuse_listener().unwrap().try_into().unwrap();
53+
let acceptor = TcpListener::new("0.0.0.0:8080").bind().await;
5454
let mut server = Server::new(acceptor);
5555
let http1 = server.http1_mut();
5656
http1.pipeline_flush(true);

0 commit comments

Comments
 (0)