From 1019ea1ed341e3a7769c046aa0be5764789360b6 Mon Sep 17 00:00:00 2001 From: Joris Date: Sun, 2 Jun 2024 14:38:13 +0200 Subject: Migrate to Rust and Hyper With sanic, downloading a file locally is around ten times slower than with Rust and hyper. Maybe `pypy` could have helped, but I didn’t succeed to set it up quickly with the dependencies. --- Cargo.toml | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 Cargo.toml (limited to 'Cargo.toml') diff --git a/Cargo.toml b/Cargo.toml new file mode 100644 index 0000000..0c69f2c --- /dev/null +++ b/Cargo.toml @@ -0,0 +1,23 @@ +[package] +name = "files" +version = "0.1.0" +authors = ["Joris "] +edition = "2021" + +[dependencies] +base64 = "0.22" +chrono = "0.4" +const_format = "0.2" +env_logger = "0.11" +futures-util = "0.3" +html-escape = "0.2" +http-body-util = "0.1" +hyper = { version = "1", features = ["full"] } +hyper-util = { version = "0.1", features = ["full"] } +log = "0.4" +rand = { version = "0.8", features = ["getrandom"] } +rand_core = "0.6.0" +tempfile = "3.10" +tokio = { version = "1", features = ["full"] } +tokio-rusqlite = "0.5.1" +tokio-util = "0.7" -- cgit v1.2.3