Expand description
The receive path’s half of space admission (gunnar_ssh::space): the
reader a pushed (or mirrored) pack is read through, which asks the data
set’s ledger before every chunk it hands on, and the sweep of spool files a
crash left behind.
§Where the three copies are told to the ledger
The hold promises gunnar_ssh::PUSH_COPIES bytes of /data per wire byte
BEFORE the byte is read, and each copy is given back the moment it is on
the disk, where statvfs counts it:
- the spool — at [
Gated]’sconsume, once the ingest has written what it consumed ([crate::storage::spooled_on_disk] is the rule, kept beside the code it describes); - the transaction log’s frame — after
PackFrame::appendreturns (transport::PushIngest); - the store — when the ingest returns, by dropping the hold; the spool is deleted by then too.
§What the client is told
A chunk the ledger will not grant cuts the stream with [NoRoom]; the
ingest fails on it, its spool drops, and PushIngest hands the wire
gunnar_wire::Error::Refused with the ledger’s line, verbatim — which
git push prints as remote unpack failed: the data set is full right now: …. Never the repository is unavailable; try again.
Functions§
- sweep_
lfs_ spool - Delete the
*.partfiles an LFS upload’s spool left inspool_dir(<txlog>/spool/,txlog_lfs): removed byDropwhen the upload lands or fails, left behind only by a process that died mid-upload. Run at start. - sweep_
spool_ leftovers - Delete every spool file a crash left under
repos_root: in each*.gitdirectory, and in itsgunnar-git.znippy/beside the archive (the two places the two engines spool). Run once at start, before any door is open, so no live push owns one. Returns(files, bytes)removed.