Switch to Redis from MongoDB for event broker.

Closes #1.
This commit is contained in:
Paul
2021-09-19 22:13:25 +01:00
parent e5e0031cad
commit 2ef6b28029
9 changed files with 176 additions and 15 deletions

View File

@@ -17,6 +17,7 @@ extern crate ctrlc;
pub mod database;
pub mod notifications;
pub mod routes;
pub mod redis;
pub mod util;
pub mod version;
@@ -47,6 +48,7 @@ async fn main() {
util::variables::preflight_checks();
database::connect().await;
redis::connect().await;
notifications::hive::init_hive().await;
ctrlc::set_handler(move || {
@@ -56,7 +58,7 @@ async fn main() {
.expect("Error setting Ctrl-C handler");
let web_task = task::spawn(launch_web());
let hive_task = task::spawn(notifications::hive::listen());
let hive_task = task::spawn_local(notifications::hive::listen());
join!(
web_task,