grants: say each pass's decision on the user list; stop creating buckets for the pass once the bus refuses one
The user list in force on novox stayed at 14:53 UTC while the shadow list changed, and the pass said nothing of why; each refused create of a state's object store waited out its bound, one after another. Recovery mode (lead-47).
This commit is contained in:
@@ -570,13 +570,14 @@ func (p *Part) Compose() Result {
|
||||
res.NotAsserted = append(res.NotAsserted, "kept event "+why)
|
||||
}
|
||||
}
|
||||
createRefused := false
|
||||
for _, module := range sortedKeys(in.Manifests) {
|
||||
if !assigned(in, module) {
|
||||
continue
|
||||
}
|
||||
a := Assert(module, in.Digests[module], in.Manifests[module], in.Nodes, held, heldErr)
|
||||
// Created only where the bus was read and lacks it, never changed where it holds it (issue 1790).
|
||||
if p.Create != nil && heldErr == nil {
|
||||
if p.Create != nil && heldErr == nil && !createRefused {
|
||||
if made, raises := createMissing(p.Create, &p.made, &a, in.Manifests[module], in.Nodes, forced == module); len(made) > 0 {
|
||||
res.Asserted = append(res.Asserted, fmt.Sprintf("%s at %s: created %s", module, a.Manifest, strings.Join(made, ", ")))
|
||||
if p.Logf != nil {
|
||||
@@ -586,6 +587,14 @@ func (p *Part) Compose() Result {
|
||||
}
|
||||
for _, why := range notCreated(a) {
|
||||
res.NotAsserted = append(res.NotAsserted, module+" "+why)
|
||||
// A create the bus refuses or leaves unanswered is not tried for the rest of this pass: each waits out its
|
||||
// bound, and the grant that admits it comes with the list this pass wrote (lead-47, 2026-11-15).
|
||||
if strings.Contains(why, "deadline exceeded") || strings.Contains(why, "ermission") {
|
||||
createRefused = true
|
||||
}
|
||||
}
|
||||
if createRefused && p.Logf != nil {
|
||||
p.Logf("a create was refused at %s: no more buckets are created this pass", module)
|
||||
}
|
||||
}
|
||||
res.Assertions++
|
||||
|
||||
@@ -126,6 +126,9 @@ func (p *Part) writeSealed(res *Result, list []byte, users int, leftOut, dropped
|
||||
next.Digest, next.Object, next.SealedTo, next.Node = digest, grantsstate.UserListObjectName(digest), grantsstate.SealingKeyID(key), in.BusNode
|
||||
}
|
||||
p.sayHeld(held)
|
||||
if p.Logf != nil {
|
||||
p.Logf("the user list: composed %s, in force %s, sealed to key %q, bus node %q, held %q, why %q", short(digest), short(cur.Digest), short(key), in.BusNode, held, why)
|
||||
}
|
||||
if next.Digest == digest {
|
||||
next.Users, next.LeftOut = users, leftOut
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user