The numbering from before G goes (design 47 H §756, G §372): the builder keeps no state versions, marks no numbered entry on a registry seat's word and arms no numbered version's publish bound; the publishes' findings and the reservations still hear the same events (DQ-11), and a reserved version's bound is the reservation's (DQ-10). builder_versions keeps answering, from the reservations alone (DMC-5): what the seat mesh-builds' reserved answers for a name and, with a version and a digest, whether that version is reserved or released with that digest. Builds: design 47 H §756, G §372, G §381, H2 H-A-532 (DMC-5, DQ-10, DQ-11), spec 29, 41, 48
23 lines
930 B
Go
23 lines
930 B
Go
package main
|
|
|
|
import (
|
|
"git.novox.be/novox/mesh-delivery/modules/mesh-delivery-builder/buildrun"
|
|
"git.novox.be/novox/mesh-delivery/modules/mesh-delivery-builder/builds"
|
|
"mesh-delivery-builder/internal/versions"
|
|
)
|
|
|
|
// ownBuckets are the buckets of the builder's own states, each `<module>_<state>` of the module its credential names, never
|
|
// a constant (design 47 G A-296, §428).
|
|
type ownBuckets struct {
|
|
bounds, reserved, queue, acted, toolchainsHeard, instances string
|
|
}
|
|
|
|
func ownBucketsOf(module string) ownBuckets {
|
|
return ownBuckets{
|
|
bounds: builds.StateBucket(module, versions.BoundsState),
|
|
reserved: builds.StateBucket(module, versions.ReservedState), queue: builds.StateBucket(module, versions.PublishQueueState),
|
|
acted: builds.StateBucket(module, versions.ActedState), toolchainsHeard: builds.StateBucket(module, buildrun.ToolchainsHeardState),
|
|
instances: builds.StateBucket(module, instancesState),
|
|
}
|
|
}
|