From acef742a6e471e214dfe6e88e8e94a77b6fcd2db Mon Sep 17 00:00:00 2001 From: Em Sharnoff Date: Tue, 7 Nov 2023 09:41:20 -0800 Subject: [PATCH] vm-monitor: Remove dependency on workspace_hack (#5752) neondatabase/autoscaling builds libs/vm-monitor during CI because it's a necessary component of autoscaling. workspace_hack includes a lot of crates that are not necessary for vm-monitor, which artificially inflates the build time on the autoscaling side, so hopefully removing the dependency should speed things up. Co-authored-by: Joonas Koivunen --- .config/hakari.toml | 6 ++++++ Cargo.lock | 1 - libs/vm_monitor/Cargo.toml | 3 +-- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/.config/hakari.toml b/.config/hakari.toml index 15b939e86f3e..9913ecc9c05a 100644 --- a/.config/hakari.toml +++ b/.config/hakari.toml @@ -22,5 +22,11 @@ platforms = [ # "x86_64-pc-windows-msvc", ] +[final-excludes] +# vm_monitor benefits from the same Cargo.lock as the rest of our artifacts, but +# it is built primarly in separate repo neondatabase/autoscaling and thus is excluded +# from depending on workspace-hack because most of the dependencies are not used. +workspace-members = ["vm_monitor"] + # Write out exact versions rather than a semver range. (Defaults to false.) # exact-versions = true diff --git a/Cargo.lock b/Cargo.lock index 10f13e21fdc6..5e7fce3e8df6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -6055,7 +6055,6 @@ dependencies = [ "tokio-util", "tracing", "tracing-subscriber", - "workspace_hack", ] [[package]] diff --git a/libs/vm_monitor/Cargo.toml b/libs/vm_monitor/Cargo.toml index 26b976830a7a..46e9f880a14b 100644 --- a/libs/vm_monitor/Cargo.toml +++ b/libs/vm_monitor/Cargo.toml @@ -19,13 +19,12 @@ inotify.workspace = true serde.workspace = true serde_json.workspace = true sysinfo.workspace = true -tokio.workspace = true +tokio = { workspace = true, features = ["rt-multi-thread"] } tokio-postgres.workspace = true tokio-stream.workspace = true tokio-util.workspace = true tracing.workspace = true tracing-subscriber.workspace = true -workspace_hack = { version = "0.1", path = "../../workspace_hack" } [target.'cfg(target_os = "linux")'.dependencies] cgroups-rs = "0.3.3"