pub async fn head_root_nodes(
__arg0: Path<String>,
__arg1: State<AppState>,
) -> Result<impl IntoResponse, StatusCode>
Expand description
Handler to respond to GET/HEAD requests for recently uploaded NAR files. Nix probes at {filehash}.nar[.compression_suffix] to determine whether a NAR has already been uploaded, by responding to (some of) these requests we avoid it unnecessarily uploading. We don’t keep a full K/V from NAR hash to root note around, only the in-memory cache used to connect to the castore node when processing a PUT for the NARInfo.