server/lib/src/pull_through_off.rs
//! **The queued pull-through, switched off** (built without `admission`): a
//! proxy always walks its upstreams inline, and nothing is charged.
use traits::ArtifactId;
/// No queue is ever installed.
pub(crate) fn armed() -> bool {
false
}
/// Never intercepts: the walk runs inline.
pub(crate) fn intercept(_repo: &str, _id: &ArtifactId) -> Option<anyhow::Result<()>> {
None
}
/// Nothing is charged.
pub fn note_upstream_fetch(_bytes: u64) {}
/// Nothing is charged: `f` runs as it is (a job's walk, H2 #3: `jobs` without `admission`).
pub fn charged_to<R>(_consumer: &str, f: impl FnOnce() -> R) -> R {
f()
}