From b53876db2543336f0d778d82d90bda463dfa0919 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Thu, 29 Feb 2024 22:48:51 +0100 Subject: [PATCH] Typo --- magic-nix-cache/src/binary_cache.rs | 6 +++--- magic-nix-cache/src/main.rs | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/magic-nix-cache/src/binary_cache.rs b/magic-nix-cache/src/binary_cache.rs index f8ea5c4..385d8be 100644 --- a/magic-nix-cache/src/binary_cache.rs +++ b/magic-nix-cache/src/binary_cache.rs @@ -51,7 +51,7 @@ async fn get_narinfo( let key = format!("{}.narinfo", store_path_hash); if state - .narinfo_nagative_cache + .narinfo_negative_cache .read() .await .contains(&store_path_hash) @@ -68,7 +68,7 @@ async fn get_narinfo( } } - let mut negative_cache = state.narinfo_nagative_cache.write().await; + let mut negative_cache = state.narinfo_negative_cache.write().await; negative_cache.insert(store_path_hash); state.metrics.narinfos_sent_upstream.incr(); @@ -103,7 +103,7 @@ async fn put_narinfo( state.metrics.narinfos_uploaded.incr(); state - .narinfo_nagative_cache + .narinfo_negative_cache .write() .await .remove(&store_path_hash); diff --git a/magic-nix-cache/src/main.rs b/magic-nix-cache/src/main.rs index 8fe3f39..3b8ea68 100644 --- a/magic-nix-cache/src/main.rs +++ b/magic-nix-cache/src/main.rs @@ -123,7 +123,7 @@ struct StateInner { shutdown_sender: Mutex>>, /// Set of store path hashes that are not present in GHAC. - narinfo_nagative_cache: RwLock>, + narinfo_negative_cache: RwLock>, /// Metrics for sending to perf at shutdown metrics: Arc, @@ -301,7 +301,7 @@ async fn main_cli() -> Result<()> { gha_cache, upstream: args.upstream.clone(), shutdown_sender: Mutex::new(Some(shutdown_sender)), - narinfo_nagative_cache: RwLock::new(HashSet::new()), + narinfo_negative_cache: RwLock::new(HashSet::new()), metrics, store, flakehub_state: RwLock::new(flakehub_state),