H-A-150: forget only on the store's own answer, and on the apply's fetch too

A fetch nothing answered for (a bus or store that did not answer, a gateway
saying the store is away) proves nothing about the digest, so it is tried
again as before and the module is not held for it; only an answer of the
store's (a 404, bytes not of the digest) forgets the resolution. The apply's
fetch of a bundle meets the same wrong digest as the take-in's, so it tells
the composer too (apply.WithFetchFailed, set in the node agent's apply).

Builds: design 47 H H-A-150, H-A-146, G A-430a
This commit is contained in:
2026-11-20 16:35:42 +01:00
parent dc95fb5673
commit 132b767043
8 changed files with 91 additions and 9 deletions
+6
View File
@@ -555,6 +555,12 @@ func nodeAgent(ctx context.Context, opts options, signer ed25519.PublicKey, trus
if kf := keptFetch.Load(); kf != nil {
actx = apply.WithKept(actx, *kf)
}
// A bundle's fetch the store answered and that failed forgets the resolution of its digest (H-A-150).
actx = apply.WithFetchFailed(actx, func(digest, why string) {
if c := composerNow.Load(); c != nil {
c.ForgetFetched(digest, why)
}
})
// While the grants part's list is followed, the controller's list in the bus module's composition is not
// written: the apply keeps the list on the machine (ADR 0547 clause 8, never both).
held, herr := users.Hold(c)