From 063be773e06f633535391477cceb806840f93244 Mon Sep 17 00:00:00 2001 From: Nova Date: Wed, 25 Jan 2023 09:17:52 -0500 Subject: [PATCH] feat: make event loop multithreaded --- Cargo.toml | 2 +- src/main.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 29376f8..ec47c8d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -22,7 +22,7 @@ once_cell = "1.17.0" parking_lot = "0.12.1" portable-atomic = {version = "1.0.1", features = ["float", "std"]} rustc-hash = "1.1.0" -tokio = { version = "1", features = ["rt", "signal"] } +tokio = { version = "1", features = ["rt-multi-thread", "signal"] } send_wrapper = "0.6.0" prisma = "0.1.1" slog = "2.7.0" diff --git a/src/main.rs b/src/main.rs index 1f21304..b8b4f5d 100644 --- a/src/main.rs +++ b/src/main.rs @@ -217,7 +217,7 @@ fn main() -> Result<()> { } // #[tokio::main] -#[tokio::main(flavor = "current_thread")] +#[tokio::main] async fn event_loop( info_sender: oneshot::Sender, stop_rx: oneshot::Receiver<()>,