From 1769a54d5319fb13c230ebaaa1a93c19e105c0b4 Mon Sep 17 00:00:00 2001 From: trivernis Date: Sat, 16 Oct 2021 12:39:00 +0200 Subject: [PATCH] Update rmp-ipc Signed-off-by: trivernis --- mediarepo-daemon/Cargo.lock | 4 ++-- mediarepo-daemon/mediarepo-core/Cargo.lock | 4 ++-- mediarepo-daemon/mediarepo-core/Cargo.toml | 2 +- mediarepo-daemon/mediarepo-database/Cargo.lock | 4 ++-- mediarepo-daemon/mediarepo-model/Cargo.lock | 4 ++-- mediarepo-daemon/mediarepo-socket/Cargo.lock | 4 ++-- .../mediarepo-socket/src/namespaces/files.rs | 16 +++++++++------- 7 files changed, 20 insertions(+), 18 deletions(-) diff --git a/mediarepo-daemon/Cargo.lock b/mediarepo-daemon/Cargo.lock index c3b3c35..6e12601 100644 --- a/mediarepo-daemon/Cargo.lock +++ b/mediarepo-daemon/Cargo.lock @@ -1411,9 +1411,9 @@ dependencies = [ [[package]] name = "rmp-ipc" -version = "0.5.0" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20fd9347d94995cc197ef2267a8c6b82f4519d3cb5c333caf57edb1376077dd1" +checksum = "fbd5082cefa9a4407327087d75dfadb5bf2d6f07168d0b609a2509f54fa3b243" dependencies = [ "lazy_static", "log", diff --git a/mediarepo-daemon/mediarepo-core/Cargo.lock b/mediarepo-daemon/mediarepo-core/Cargo.lock index d3fa356..1a4295e 100644 --- a/mediarepo-daemon/mediarepo-core/Cargo.lock +++ b/mediarepo-daemon/mediarepo-core/Cargo.lock @@ -1034,9 +1034,9 @@ dependencies = [ [[package]] name = "rmp-ipc" -version = "0.5.0" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20fd9347d94995cc197ef2267a8c6b82f4519d3cb5c333caf57edb1376077dd1" +checksum = "fbd5082cefa9a4407327087d75dfadb5bf2d6f07168d0b609a2509f54fa3b243" dependencies = [ "lazy_static", "log", diff --git a/mediarepo-daemon/mediarepo-core/Cargo.toml b/mediarepo-daemon/mediarepo-core/Cargo.toml index f727394..476781e 100644 --- a/mediarepo-daemon/mediarepo-core/Cargo.toml +++ b/mediarepo-daemon/mediarepo-core/Cargo.toml @@ -12,7 +12,7 @@ multibase = "0.9.1" base64 = "0.13.0" toml = "0.5.8" serde = "1.0.130" -rmp-ipc = "0.5.0" +rmp-ipc = "0.6.0" typemap_rev = "0.1.5" image = "0.23.14" futures = "0.3.17" diff --git a/mediarepo-daemon/mediarepo-database/Cargo.lock b/mediarepo-daemon/mediarepo-database/Cargo.lock index 55d66fe..f4b1f9f 100644 --- a/mediarepo-daemon/mediarepo-database/Cargo.lock +++ b/mediarepo-daemon/mediarepo-database/Cargo.lock @@ -1267,9 +1267,9 @@ dependencies = [ [[package]] name = "rmp-ipc" -version = "0.5.0" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20fd9347d94995cc197ef2267a8c6b82f4519d3cb5c333caf57edb1376077dd1" +checksum = "fbd5082cefa9a4407327087d75dfadb5bf2d6f07168d0b609a2509f54fa3b243" dependencies = [ "lazy_static", "log", diff --git a/mediarepo-daemon/mediarepo-model/Cargo.lock b/mediarepo-daemon/mediarepo-model/Cargo.lock index 280c6fe..8d8585e 100644 --- a/mediarepo-daemon/mediarepo-model/Cargo.lock +++ b/mediarepo-daemon/mediarepo-model/Cargo.lock @@ -1298,9 +1298,9 @@ dependencies = [ [[package]] name = "rmp-ipc" -version = "0.5.0" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20fd9347d94995cc197ef2267a8c6b82f4519d3cb5c333caf57edb1376077dd1" +checksum = "fbd5082cefa9a4407327087d75dfadb5bf2d6f07168d0b609a2509f54fa3b243" dependencies = [ "lazy_static", "log", diff --git a/mediarepo-daemon/mediarepo-socket/Cargo.lock b/mediarepo-daemon/mediarepo-socket/Cargo.lock index 9686736..ab93ab1 100644 --- a/mediarepo-daemon/mediarepo-socket/Cargo.lock +++ b/mediarepo-daemon/mediarepo-socket/Cargo.lock @@ -1310,9 +1310,9 @@ dependencies = [ [[package]] name = "rmp-ipc" -version = "0.5.0" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "20fd9347d94995cc197ef2267a8c6b82f4519d3cb5c333caf57edb1376077dd1" +checksum = "fbd5082cefa9a4407327087d75dfadb5bf2d6f07168d0b609a2509f54fa3b243" dependencies = [ "lazy_static", "log", diff --git a/mediarepo-daemon/mediarepo-socket/src/namespaces/files.rs b/mediarepo-daemon/mediarepo-socket/src/namespaces/files.rs index 186e0ed..e5db3eb 100644 --- a/mediarepo-daemon/mediarepo-socket/src/namespaces/files.rs +++ b/mediarepo-daemon/mediarepo-socket/src/namespaces/files.rs @@ -13,16 +13,18 @@ use tokio::io::AsyncReadExt; pub struct FilesNamespace; impl NamespaceProvider for FilesNamespace { - fn name() -> String { - String::from("files") + fn name() -> &'static str { + "files" } fn register(handler: &mut EventHandler) { - handler.on("all_files", callback!(Self::all_files)); - handler.on("add_file", callback!(Self::add_file)); - handler.on("read_file", callback!(Self::read_file)); - handler.on("get_thumbnails", callback!(Self::thumbnails)); - handler.on("read_thumbnail", callback!(Self::read_thumbnail)); + events!(handler, + "all_files" => Self::all_files, + "add_file" => Self::add_file, + "read_file" => Self::read_file, + "get_thumbnails" => Self::thumbnails, + "read_thumbnail" => Self::read_thumbnail + ); } }