diff --git a/overlay/attic/prefetch-8-chunks.patch b/overlay/attic/prefetch-8-chunks.patch index 3786541..eafc514 100644 --- a/overlay/attic/prefetch-8-chunks.patch +++ b/overlay/attic/prefetch-8-chunks.patch @@ -1,7 +1,16 @@ diff --git a/server/src/api/binary_cache.rs b/server/src/api/binary_cache.rs -index 02e4857..71eeee8 100644 +index 02e4857..b522154 100644 --- a/server/src/api/binary_cache.rs +++ b/server/src/api/binary_cache.rs +@@ -215,7 +215,7 @@ async fn get_nar( + let chunk = chunks[0].as_ref().unwrap(); + let remote_file = &chunk.remote_file.0; + let storage = state.storage().await?; +- match storage.download_file_db(remote_file, false).await? { ++ match storage.download_file_db(remote_file, true).await? { + Download::Url(url) => Ok(Redirect::temporary(&url).into_response()), + Download::AsyncRead(stream) => { + let stream = ReaderStream::new(stream).map_err(|e| { @@ -262,7 +262,7 @@ async fn get_nar( // TODO: Make num_prefetch configurable @@ -11,3 +20,4 @@ index 02e4857..71eeee8 100644 tracing::error!(%e, "Stream error"); e }); +