carlos / platform Public

config before wake: a lock timeout starts no retry window (census review P3s)

A wake that gave up waiting for the config lock recorded the 30 s retry
memo anyway, so the wake that follows seconds later did not ask and the
first generation could still start unconfigured. The memo is now recorded
only when an attempt ran: at a store that will not open, or with the lock
in hand. Comments say the hook can hold a wake about 10 s where acks are
written in line, and that an instance-overlay row's directory is made for
an empty file. Census overlay regenerated over main's
console-addr-from-install.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Paul Campbell pushed by paul@keymail.dev dcf785e36f4cd6d594afe88cad34770ea6de71f7 parent 6e60a51
6 files changed, +91 −17
  • docs/superpowers/notes/census-proposal-instance-ready-before-wake.md +3 −3
  • internal/appconfig/syncexec.go +7 −4
  • internal/host/configbeforewake.go +45 −4
  • internal/host/configbeforewake_test.go +30 −0
  • internal/provision/testdata/plan14-root-reads-chain.tsv +1 −1
  • internal/provision/testdata/plan14-root-reads-instance-ready-before-wake.tsv +5 −5

CI passed — run details

CI log
=== gate ===
go: downloading go1.26.10 (linux/arm64)
go version go1.26.10 linux/arm64
opentofu: arm64, tofu 1.13.9, aws 6.73.0, archive 2.8.1
  tofu: downloading https://carlos-ci-mirror-640012953448.s3.eu-west-1.amazonaws.com/opentofu/tofu_1.13.9_linux_arm64.tar.gz
  tofu: downloaded, digest verified
  aws: downloading https://carlos-ci-mirror-640012953448.s3.eu-west-1.amazonaws.com/opentofu/terraform-provider-aws_6.73.0_linux_arm64.zip
  aws: downloaded, digest verified
  archive: downloading https://carlos-ci-mirror-640012953448.s3.eu-west-1.amazonaws.com/opentofu/terraform-provider-archive_2.8.1_linux_arm64.zip
  archive: downloaded, digest verified
  installed in /tmp/carlos-opentofu-5GzNrr
.amadan/test-gate.sh
go: downloading github.com/aws/aws-sdk-go-v2 v1.44.0
go: downloading github.com/aws/aws-sdk-go-v2/service/cloudwatch v1.68.0
go: downloading github.com/aws/aws-sdk-go-v2/service/costexplorer v1.67.5
go: downloading github.com/aws/aws-sdk-go-v2/service/s3 v1.105.0
go: downloading github.com/benbjohnson/litestream v0.5.14
go: downloading github.com/superfly/ltx v0.5.1
go: downloading golang.org/x/net v0.62.0
go: downloading modernc.org/sqlite v1.55.0
go: downloading github.com/aws/aws-sdk-go-v2/service/sns v1.43.0
go: downloading github.com/aws/aws-sdk-go-v2/service/acm v1.45.0
go: downloading github.com/aws/aws-sdk-go-v2/service/ec2 v1.324.0
go: downloading github.com/aws/aws-sdk-go-v2/service/iam v1.58.2
go: downloading github.com/aws/aws-sdk-go-v2/service/resourcegroupstaggingapi v1.37.0
go: downloading github.com/aws/aws-sdk-go-v2/service/route53 v1.64.1
go: downloading golang.org/x/sys v0.49.0
go: downloading github.com/aws/aws-sdk-go-v2/service/sts v1.45.6
go: downloading golang.org/x/crypto v0.58.0
go: downloading github.com/aws/aws-sdk-go-v2/service/sesv2 v1.66.6
go: downloading github.com/pion/stun/v3 v3.1.5
go: downloading github.com/pion/turn/v4 v4.1.4
go: downloading github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.40
go: downloading github.com/pierrec/lz4/v4 v4.1.22
go: downloading github.com/aws/aws-sdk-go-v2/service/signin v1.0.4
go: downloading github.com/klauspost/compress v1.20.2
go: downloading github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.40
go: downloading golang.org/x/text v0.43.0
go: downloading github.com/aws/aws-sdk-go-v2/internal/v4a v1.4.38
go: downloading github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.40
go: downloading github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.19.31
go: downloading github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.7.14
go: downloading github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.9.23
go: downloading github.com/pion/dtls/v3 v3.1.4
go: downloading github.com/wlynxg/anet v0.0.5
go: downloading golang.org/x/sync v0.24.0
go: downloading github.com/prometheus/client_golang v1.17.0
go: downloading github.com/aws/aws-sdk-go-v2/feature/s3/manager v1.20.18
go: downloading github.com/prometheus/client_model v0.5.0
go: downloading github.com/prometheus/common v0.45.0
go: downloading github.com/cespare/xxhash/v2 v2.3.0
go: downloading github.com/prometheus/procfs v0.12.0
go: downloading google.golang.org/protobuf v1.36.10
go: downloading github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0
go: downloading github.com/klauspost/compress v1.20.2
go: downloading modernc.org/sqlite v1.55.0
go: downloading github.com/aws/aws-sdk-go-v2/service/ecs v1.91.0
go: downloading golang.org/x/crypto/x509roots/fallback v0.0.0-20260209214922-2f26647a795e
go: downloading github.com/pierrec/lz4/v4 v4.1.22
go: downloading modernc.org/libc v1.74.1
go: downloading modernc.org/libc v1.74.1
go: downloading github.com/dustin/go-humanize v1.0.1
go: downloading modernc.org/memory v1.11.0
go: downloading github.com/google/uuid v1.6.0
go: downloading modernc.org/mathutil v1.7.1
go: downloading modernc.org/mathutil v1.7.1
go: downloading github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec
=== launchctx (4 s, from +0 s)
ok  	amadan.net/carlos/platform.git/launchctx	0.015s
?   	amadan.net/carlos/platform.git/launchctx/controlname	[no test files]
?   	amadan.net/carlos/platform.git/launchctx/wireid	[no test files]
=== vet (174 s, from +0 s)
go: downloading modernc.org/sqlite v1.55.0
go: downloading golang.org/x/crypto/x509roots/fallback v0.0.0-20260209214922-2f26647a795e
go: downloading github.com/aws/aws-sdk-go-v2/service/ecs v1.91.0
go: downloading github.com/klauspost/compress v1.20.2
go: downloading github.com/pierrec/lz4/v4 v4.1.22
go: downloading github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0
go: downloading modernc.org/libc v1.74.1
go: downloading modernc.org/mathutil v1.7.1
=== vet-tags (187 s, from +0 s)
go: downloading modernc.org/sqlite v1.55.0
go: downloading github.com/klauspost/compress v1.20.2
go: downloading golang.org/x/crypto/x509roots/fallback v0.0.0-20260209214922-2f26647a795e
go: downloading github.com/aws/aws-sdk-go-v2/service/ecs v1.91.0
go: downloading github.com/pierrec/lz4/v4 v4.1.22
go: downloading modernc.org/libc v1.74.1
=== gofmt (1 s, from +0 s)
gofmt -l .: clean
=== rest (383 s, from +16 s)
ok  	github.com/carlosframework/platform/cmd/carlos-media	119.468s
?   	github.com/carlosframework/platform/cmd/changelog	[no test files]
ok  	github.com/carlosframework/platform/cmd/console	212.138s
ok  	github.com/carlosframework/platform/cmd/mediaimage	44.715s
ok  	github.com/carlosframework/platform/cmd/moveprobe	15.117s
ok  	github.com/carlosframework/platform/cmd/pricebook-export	0.075s
ok  	github.com/carlosframework/platform/cmd/rootfswitness	0.143s
ok  	github.com/carlosframework/platform/cmd/runsc-assets	0.126s
ok  	github.com/carlosframework/platform/cmd/zddprobe	1.013s
ok  	github.com/carlosframework/platform/internal/agentsock	0.069s
ok  	github.com/carlosframework/platform/internal/alerting	0.025s
ok  	github.com/carlosframework/platform/internal/analytics	0.266s
ok  	github.com/carlosframework/platform/internal/appconfig	44.290s
ok  	github.com/carlosframework/platform/internal/apperr	0.427s
ok  	github.com/carlosframework/platform/internal/applog	0.541s
ok  	github.com/carlosframework/platform/internal/apppolicy	2.689s
ok  	github.com/carlosframework/platform/internal/assetcache	0.543s
ok  	github.com/carlosframework/platform/internal/awsinv	0.015s
ok  	github.com/carlosframework/platform/internal/awsmanaged	0.402s
ok  	github.com/carlosframework/platform/internal/awsregiongroup	0.139s
ok  	github.com/carlosframework/platform/internal/awsterminations	0.028s
ok  	github.com/carlosframework/platform/internal/backupswords	0.013s
ok  	github.com/carlosframework/platform/internal/billing	0.132s
ok  	github.com/carlosframework/platform/internal/billing/billingtest	0.122s
ok  	github.com/carlosframework/platform/internal/billingstripe	1.858s
ok  	github.com/carlosframework/platform/internal/boxchoice	0.023s
ok  	github.com/carlosframework/platform/internal/boxid	2.947s
?   	github.com/carlosframework/platform/internal/boxid/boxidtest	[no test files]
?   	github.com/carlosframework/platform/internal/boxid/internal/signtest	[no test files]
ok  	github.com/carlosframework/platform/internal/boxroles	0.016s
ok  	github.com/carlosframework/platform/internal/boxself	0.118s
ok  	github.com/carlosframework/platform/internal/boxvolumes	0.044s
ok  	github.com/carlosframework/platform/internal/caps	4.731s
ok  	github.com/carlosframework/platform/internal/certwarm	0.017s
ok  	github.com/carlosframework/platform/internal/cgroup	1.471s
ok  	github.com/carlosframework/platform/internal/changelog	4.165s
ok  	github.com/carlosframework/platform/internal/clamd	0.085s
?   	github.com/carlosframework/platform/internal/cliflag	[no test files]
ok  	github.com/carlosframework/platform/internal/clireg	0.015s
ok  	github.com/carlosframework/platform/internal/codehealth	19.031s
ok  	github.com/carlosframework/platform/internal/compute	0.013s
ok  	github.com/carlosframework/platform/internal/consolefleet	0.011s
?   	github.com/carlosframework/platform/internal/controlname	[no test files]
?   	github.com/carlosframework/platform/internal/controlsock	[no test files]
ok  	github.com/carlosframework/platform/internal/dbdoor	10.862s
ok  	github.com/carlosframework/platform/internal/dbdoor/dbdoortest	0.045s
ok  	github.com/carlosframework/platform/internal/dbquery	0.024s
ok  	github.com/carlosframework/platform/internal/dbreads	2.937s
?   	github.com/carlosframework/platform/internal/dbreads/dbreadstest	[no test files]
ok  	github.com/carlosframework/platform/internal/dbverify	0.021s
ok  	github.com/carlosframework/platform/internal/demo	0.007s
ok  	github.com/carlosframework/platform/internal/demobuild	3.779s
ok  	github.com/carlosframework/platform/internal/democlaim	0.384s
ok  	github.com/carlosframework/platform/internal/devbox	18.156s
ok  	github.com/carlosframework/platform/internal/dnsrec	0.020s
ok  	github.com/carlosframework/platform/internal/docsite	0.084s
ok  	github.com/carlosframework/platform/internal/domainreg	0.013s
ok  	github.com/carlosframework/platform/internal/domains	69.260s
ok  	github.com/carlosframework/platform/internal/doorkey	0.033s
ok  	github.com/carlosframework/platform/internal/economics	0.016s
ok  	github.com/carlosframework/platform/internal/edgefence	0.094s
ok  	github.com/carlosframework/platform/internal/edgeguard	0.437s
?   	github.com/carlosframework/platform/internal/edgeproof	[no test files]
ok  	github.com/carlosframework/platform/internal/edgesfile	0.121s
ok  	github.com/carlosframework/platform/internal/egressaddr	0.009s
ok  	github.com/carlosframework/platform/internal/execsandbox	105.135s
ok  	github.com/carlosframework/platform/internal/fileacl	0.012s
ok  	github.com/carlosframework/platform/internal/fleetapi	2.683s
ok  	github.com/carlosframework/platform/internal/fleetstore	0.013s
ok  	github.com/carlosframework/platform/internal/fxrate	0.033s
ok  	github.com/carlosframework/platform/internal/gate	3.964s
ok  	github.com/carlosframework/platform/internal/genselect	0.064s
ok  	github.com/carlosframework/platform/internal/geo	0.070s
ok  	github.com/carlosframework/platform/internal/geoip	0.107s
ok  	github.com/carlosframework/platform/internal/groupadmission	0.011s
ok  	github.com/carlosframework/platform/internal/grouprollaws	16.616s
ok  	github.com/carlosframework/platform/internal/hadeparture	0.019s
ok  	github.com/carlosframework/platform/internal/hafresh	0.007s
ok  	github.com/carlosframework/platform/internal/hairpin	0.247s
ok  	github.com/carlosframework/platform/internal/historyreadback	0.921s
ok  	github.com/carlosframework/platform/internal/hostactors	23.329s
ok  	github.com/carlosframework/platform/internal/hostbox	22.732s
ok  	github.com/carlosframework/platform/internal/hostclaim	2.647s
ok  	github.com/carlosframework/platform/internal/hostenv	0.037s
ok  	github.com/carlosframework/platform/internal/hostevidence	0.016s
ok  	github.com/carlosframework/platform/internal/hostexec	26.545s
ok  	github.com/carlosframework/platform/internal/hostfence	0.174s
ok  	github.com/carlosframework/platform/internal/hostfiles	29.823s
ok  	github.com/carlosframework/platform/internal/hostfloor	0.063s
ok  	github.com/carlosframework/platform/internal/hostguard	1.586s
ok  	github.com/carlosframework/platform/internal/hostops	7.809s
?   	github.com/carlosframework/platform/internal/hostops/fencerelease	[no test files]
ok  	github.com/carlosframework/platform/internal/hostops/internal/fencerelease	0.010s
ok  	github.com/carlosframework/platform/internal/hostquarantine	0.029s
ok  	github.com/carlosframework/platform/internal/hostrelocate	2.682s
ok  	github.com/carlosframework/platform/internal/hostresolve	0.632s
ok  	github.com/carlosframework/platform/internal/hostwrite	0.005s
ok  	github.com/carlosframework/platform/internal/infraview	0.005s
ok  	github.com/carlosframework/platform/internal/ingresshealth	0.008s
ok  	github.com/carlosframework/platform/internal/ingresshealth/awstg	0.011s
ok  	github.com/carlosframework/platform/internal/instancectl	55.841s
ok  	github.com/carlosframework/platform/internal/instanceexec	9.277s
ok  	github.com/carlosframework/platform/internal/instancefs	0.026s
ok  	github.com/carlosframework/platform/internal/instancekey	0.015s
ok  	github.com/carlosframework/platform/internal/instanceupdates	0.022s
ok  	github.com/carlosframework/platform/internal/interactive	0.729s
ok  	github.com/carlosframework/platform/internal/launchd	0.017s
ok  	github.com/carlosframework/platform/internal/layout	24.565s
ok  	github.com/carlosframework/platform/internal/layout/pubclass	103.225s
ok  	github.com/carlosframework/platform/internal/lbhealth	0.013s
ok  	github.com/carlosframework/platform/internal/lease	147.515s
ok  	github.com/carlosframework/platform/internal/lease/leasetest	1.297s
ok  	github.com/carlosframework/platform/internal/lease/locktest	0.021s
ok  	github.com/carlosframework/platform/internal/ledger	0.063s
ok  	github.com/carlosframework/platform/internal/mail	1.397s
ok  	github.com/carlosframework/platform/internal/mailer	0.857s
ok  	github.com/carlosframework/platform/internal/mailsubmit	1.647s
ok  	github.com/carlosframework/platform/internal/mailwire	0.020s
ok  	github.com/carlosframework/platform/internal/maintenance	0.251s
ok  	github.com/carlosframework/platform/internal/maintenanceexec	8.717s
ok  	github.com/carlosframework/platform/internal/maintenanceguard	0.511s
ok  	github.com/carlosframework/platform/internal/media	2.271s
ok  	github.com/carlosframework/platform/internal/media/mediatest	0.010s
ok  	github.com/carlosframework/platform/internal/mediaaws	64.043s
ok  	github.com/carlosframework/platform/internal/mediahandler	44.860s
ok  	github.com/carlosframework/platform/internal/mediajobs	1.052s
ok  	github.com/carlosframework/platform/internal/medialocal	9.729s
ok  	github.com/carlosframework/platform/internal/metrics	0.128s
ok  	github.com/carlosframework/platform/internal/minorunits	0.009s
ok  	github.com/carlosframework/platform/internal/moves	54.469s
ok  	github.com/carlosframework/platform/internal/moves/archive	3.034s
ok  	github.com/carlosframework/platform/internal/moves/offlinerun	0.075s
ok  	github.com/carlosframework/platform/internal/namedunits	0.021s
ok  	github.com/carlosframework/platform/internal/objstore	1.535s
ok  	github.com/carlosframework/platform/internal/ops	18.280s
ok  	github.com/carlosframework/platform/internal/pageindex	3.887s
ok  	github.com/carlosframework/platform/internal/parity	0.109s
?   	github.com/carlosframework/platform/internal/parity/cmd/parity-doc	[no test files]
ok  	github.com/carlosframework/platform/internal/park	0.952s
ok  	github.com/carlosframework/platform/internal/perf	0.215s
ok  	github.com/carlosframework/platform/internal/plans	0.182s
ok  	github.com/carlosframework/platform/internal/privatefile	0.019s
ok  	github.com/carlosframework/platform/internal/provision	241.539s
ok  	github.com/carlosframework/platform/internal/proxyproto	0.958s
ok  	github.com/carlosframework/platform/internal/publicrelease	0.051s
ok  	github.com/carlosframework/platform/internal/ratelimit	0.256s
ok  	github.com/carlosframework/platform/internal/regionlabel	0.064s
ok  	github.com/carlosframework/platform/internal/regionname	0.051s
ok  	github.com/carlosframework/platform/internal/registrar	0.009s
ok  	github.com/carlosframework/platform/internal/registrar/openprovider	0.783s
?   	github.com/carlosframework/platform/internal/registrar/registrartest	[no test files]
ok  	github.com/carlosframework/platform/internal/registry	83.982s
ok  	github.com/carlosframework/platform/internal/relay	7.942s
ok  	github.com/carlosframework/platform/internal/release	85.140s
ok  	github.com/carlosframework/platform/internal/replicagen	0.026s
ok  	github.com/carlosframework/platform/internal/replicas	0.208s
ok  	github.com/carlosframework/platform/internal/reqrec	6.803s
ok  	github.com/carlosframework/platform/internal/rollout	13.592s
ok  	github.com/carlosframework/platform/internal/rolloutwords	0.020s
ok  	github.com/carlosframework/platform/internal/rootaws	106.563s
ok  	github.com/carlosframework/platform/internal/rootfsimage	0.855s
ok  	github.com/carlosframework/platform/internal/rootparticipation	0.078s
ok  	github.com/carlosframework/platform/internal/rootstate	0.047s
ok  	github.com/carlosframework/platform/internal/runs	0.713s
ok  	github.com/carlosframework/platform/internal/s3compat	0.028s
ok  	github.com/carlosframework/platform/internal/s3fake	0.885s
ok  	github.com/carlosframework/platform/internal/safefile	0.016s
ok  	github.com/carlosframework/platform/internal/schedule	27.025s
ok  	github.com/carlosframework/platform/internal/seeds	0.067s
ok  	github.com/carlosframework/platform/internal/sim/litestreamfacts	5.046s
ok  	github.com/carlosframework/platform/internal/sim/mediajobs	48.182s
ok  	github.com/carlosframework/platform/internal/sim/regionha	25.387s
ok  	github.com/carlosframework/platform/internal/status	0.623s
ok  	github.com/carlosframework/platform/internal/steering	0.362s
ok  	github.com/carlosframework/platform/internal/stopevidence	0.458s
ok  	github.com/carlosframework/platform/internal/storecfg	0.688s
ok  	github.com/carlosframework/platform/internal/svcrole	0.025s
ok  	github.com/carlosframework/platform/internal/systemd	7.466s
?   	github.com/carlosframework/platform/internal/systemdshow	[no test files]
ok  	github.com/carlosframework/platform/internal/team	5.019s
ok  	github.com/carlosframework/platform/internal/teamcontract	0.340s
ok  	github.com/carlosframework/platform/internal/telemetry	0.066s
ok  	github.com/carlosframework/platform/internal/termfence	3.974s
ok  	github.com/carlosframework/platform/internal/timerspec	0.032s
ok  	github.com/carlosframework/platform/internal/tsidentity	4.220s
ok  	github.com/carlosframework/platform/internal/tunnelclient	0.445s
ok  	github.com/carlosframework/platform/internal/unixdial	0.023s
ok  	github.com/carlosframework/platform/internal/updatewords	0.064s
ok  	github.com/carlosframework/platform/internal/upstreamguard	0.034s
?   	github.com/carlosframework/platform/internal/upstreamguard/guardtest	[no test files]
ok  	github.com/carlosframework/platform/internal/usage	0.066s
ok  	github.com/carlosframework/platform/internal/version	0.014s
ok  	github.com/carlosframework/platform/internal/vet	3.657s
ok  	github.com/carlosframework/platform/internal/zonehost	0.059s
ok  	github.com/carlosframework/platform/internal/zonehost/route53zones	0.122s
?   	github.com/carlosframework/platform/internal/zonehost/zonehosttest	[no test files]
?   	github.com/carlosframework/platform/scripts/gitleaks-gate	[no test files]
ok  	github.com/carlosframework/platform/scripts/govulncheck-gate	0.035s
ok  	github.com/carlosframework/platform/scripts/pathmapcheck	0.114s
ok  	github.com/carlosframework/platform/scripts/region-ha-g2/fixture	5.219s
ok  	github.com/carlosframework/platform/scripts/stateless-replicas-drill	1.212s
ok  	github.com/carlosframework/platform/scripts/witness-pointer	0.044s
=== cutover-witness (164 s, from +16 s)
ok  	github.com/carlosframework/platform	2.532s
=== internal_grouproll@0 (283 s, from +74 s)
ok  	github.com/carlosframework/platform/internal/grouproll	282.141s
=== internal_grouproll@1 (283 s, from +74 s)
ok  	github.com/carlosframework/platform/internal/grouproll	282.541s
=== internal_activator@0 (157 s, from +149 s)
ok  	github.com/carlosframework/platform/internal/activator	153.257s
=== internal_activator@1 (138 s, from +149 s)
ok  	github.com/carlosframework/platform/internal/activator	131.051s
=== internal_activator@2 (136 s, from +149 s)
ok  	github.com/carlosframework/platform/internal/activator	130.619s
=== internal_activator@3 (170 s, from +149 s)
ok  	github.com/carlosframework/platform/internal/activator	165.170s
=== internal_edge@0 (191 s, from +178 s)
ok  	github.com/carlosframework/platform/internal/edge	183.095s
=== internal_edge@1 (142 s, from +178 s)
ok  	github.com/carlosframework/platform/internal/edge	132.447s
=== internal_edge@2 (169 s, from +178 s)
ok  	github.com/carlosframework/platform/internal/edge	160.410s
=== internal_edge@3 (208 s, from +178 s)
ok  	github.com/carlosframework/platform/internal/edge	198.803s
=== root@0 (110 s, from +180 s)
ok  	github.com/carlosframework/platform	102.401s
=== root@1 (109 s, from +180 s)
ok  	github.com/carlosframework/platform	98.881s
=== root@2 (123 s, from +180 s)
ok  	github.com/carlosframework/platform	113.591s
=== root@3 (108 s, from +180 s)
ok  	github.com/carlosframework/platform	99.887s
=== root@4 (100 s, from +180 s)
ok  	github.com/carlosframework/platform	90.851s
=== internal_host@0 (146 s, from +218 s)
ok  	github.com/carlosframework/platform/internal/host	141.538s
=== internal_host@1 (141 s, from +218 s)
ok  	github.com/carlosframework/platform/internal/host	136.758s
=== internal_host@2 (199 s, from +218 s)
ok  	github.com/carlosframework/platform/internal/host	194.079s
=== internal_host@3 (255 s, from +218 s)
ok  	github.com/carlosframework/platform/internal/host	249.906s
=== internal_host@4 (141 s, from +218 s)
ok  	github.com/carlosframework/platform/internal/host	136.667s
=== internal_host@5 (272 s, from +218 s)
ok  	github.com/carlosframework/platform/internal/host	267.829s
=== internal_console@0 (147 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	141.154s
=== internal_console@1 (171 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	165.041s
=== internal_console@2 (207 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	200.431s
=== internal_console@3 (240 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	233.952s
=== internal_console@4 (192 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	185.140s
=== internal_console@5 (207 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	200.854s
=== internal_console@6 (207 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	201.063s
=== internal_console@7 (206 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	200.525s
=== internal_console@8 (207 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	200.449s
=== internal_console@9 (208 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	200.993s
=== internal_console@10 (222 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	215.072s
=== internal_console@11 (238 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	232.159s
=== internal_console@12 (281 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	274.117s
=== internal_console@13 (257 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	251.308s
=== internal_console@14 (231 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	224.225s
=== internal_console@15 (214 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	207.179s
=== internal_console@16 (233 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	226.984s
=== internal_console@17 (202 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	195.599s
=== internal_console@18 (209 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	202.149s
=== internal_console@19 (201 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	195.358s
=== internal_console@20 (212 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	205.063s
=== internal_console@21 (219 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	212.784s
=== internal_console@22 (211 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	204.180s
=== internal_console@23 (243 s, from +226 s)
ok  	github.com/carlosframework/platform/internal/console	236.273s
=== lists: internal_console 225 s, internal_edge 177 s, internal_activator 148 s, internal_host 217 s, root 179 s, internal_grouproll 73 s
=== cpu: the gate used 12746 cpu-seconds in 507 s, about 25.1 of 32 cores; the machine as a whole was 84% busy
=== opentofu ===
opentofu: 36 test files in 11 suites, OpenTofu v1.13.9
  initialised in 14 s
  ok      17 s  infra/modules/box-fence-writer/tests/writer.tftest.hcl  Success! 1 passed, 0 failed.
  ok      27 s  infra/modules/deployment-buckets/tests/data_lifecycle.tftest.hcl  Success! 3 passed, 0 failed.
  ok      15 s  infra/modules/deployment-buckets/tests/db_reads.tftest.hcl  Success! 1 passed, 0 failed.
  ok      16 s  infra/modules/deployment-buckets/tests/evidence.tftest.hcl  Success! 1 passed, 0 failed.
  ok      27 s  infra/modules/deployment-buckets/tests/fence_writers.tftest.hcl  Success! 3 passed, 0 failed.
  ok      83 s  infra/modules/media-engine/tests/media_engine.tftest.hcl  Success! 24 passed, 0 failed.
  ok      33 s  infra/modules/pdf-host/tests/computed.tftest.hcl  Success! 2 passed, 0 failed.
  ok      69 s  infra/modules/pdf-host/tests/pdf_host.tftest.hcl  Success! 24 passed, 0 failed.
  ok      45 s  infra/modules/region-group-operator-document/tests/document.tftest.hcl  Success! 12 passed, 0 failed.
  ok      23 s  infra/modules/region-host/ingress/tests/fixed-targets/tests/targets.tftest.hcl  Success! 2 passed, 0 failed.
  ok      66 s  infra/modules/region-host/ingress/tests/group_ingress.tftest.hcl  Success! 30 passed, 0 failed.
  ok      45 s  infra/modules/region-host/tests/alert_publish.tftest.hcl  Success! 18 passed, 0 failed.
  ok      43 s  infra/modules/region-host/tests/alerts_topic.tftest.hcl  Success! 16 passed, 0 failed.
  ok      15 s  infra/modules/region-host/tests/analytics_prune.tftest.hcl  Success! 2 passed, 0 failed.
  ok      17 s  infra/modules/region-host/tests/console_mail.tftest.hcl  Success! 4 passed, 0 failed.
  ok       9 s  infra/modules/region-host/tests/fixed_state_unchanged.tftest.hcl  Success! 1 passed, 0 failed.
  ok      69 s  infra/modules/region-host/tests/group.tftest.hcl  Success! 32 passed, 0 failed.
  ok       8 s  infra/modules/region-host/tests/group_alarms.tftest.hcl  Success! 4 passed, 0 failed.
  ok       9 s  infra/modules/region-host/tests/group_iam.tftest.hcl  Success! 4 passed, 0 failed.
  ok       6 s  infra/modules/region-host/tests/group_isolation.tftest.hcl  Success! 1 passed, 0 failed.
  ok      35 s  infra/modules/region-host/tests/group_operator.tftest.hcl  Success! 13 passed, 0 failed.
  ok       7 s  infra/modules/region-host/tests/group_user_data.tftest.hcl  Success! 3 passed, 0 failed.
  ok      27 s  infra/modules/region-host/tests/health_alarms.tftest.hcl  Success! 10 passed, 0 failed.
  ok       9 s  infra/modules/region-host/tests/ingress_drain_read.tftest.hcl  Success! 4 passed, 0 failed.
  ok       4 s  infra/modules/region-host/tests/instance_metadata.tftest.hcl  Success! 1 passed, 0 failed.
  ok      22 s  infra/modules/region-host/tests/mailer.tftest.hcl  Success! 6 passed, 0 failed.
  ok      10 s  infra/modules/region-host/tests/mailer_group.tftest.hcl  Success! 2 passed, 0 failed.
  ok      14 s  infra/modules/region-host/tests/managed_fleets/group_refusal.tftest.hcl  Success! 2 passed, 0 failed.
  ok     110 s  infra/modules/region-host/tests/managed_fleets/managed_fleets.tftest.hcl  Success! 46 passed, 0 failed.
  ok      79 s  infra/modules/region-host/tests/store_conversion.tftest.hcl  Success! 27 passed, 0 failed.
  ok      21 s  infra/modules/region-host/tests/store_scanning.tftest.hcl  Success! 4 passed, 0 failed.
  ok      33 s  infra/modules/region-host/tests/store_versioning.tftest.hcl  Success! 11 passed, 0 failed.
  ok      17 s  infra/modules/region-host/tests/user_data_ignored.tftest.hcl  Success! 3 passed, 0 failed.
  ok      12 s  infra/modules/region-remote-host/tests/data_lifecycle.tftest.hcl  Success! 3 passed, 0 failed.
  ok      13 s  infra/modules/region-remote-host/tests/no_deployment_bucket.tftest.hcl  Success! 5 passed, 0 failed.
  ok      27 s  infra/modules/scanner-host/tests/scanner_host.tftest.hcl  Success! 14 passed, 0 failed.
opentofu: 36 files in 207 s
opentofu: PASS
=== cross ===
--- shard 0 of 5 ---
go version go1.26.10 linux/arm64
cross-compiling darwin/arm64
--- shard 1 of 5 ---
go version go1.26.10 linux/arm64
cross-compiling darwin/amd64
--- shard 2 of 5 ---
go version go1.26.10 linux/arm64
cross-compiling linux/arm64
linux/arm64 carlos binary: 65994914 bytes (ceiling 70000000)
--- shard 3 of 5 ---
go version go1.26.10 linux/arm64
cross-compiling windows/amd64
--- shard 4 of 5 ---
go version go1.26.10 linux/arm64
cross-compiling windows/arm64
=== minio-contract ===
go version go1.26.10 linux/arm64
minio contract: arm64, minio RELEASE.2025-09-07T16-13-09Z, mc RELEASE.2025-08-13T08-35-41Z
  minio: downloading https://carlos-ci-mirror-640012953448.s3.eu-west-1.amazonaws.com/minio/minio.linux-arm64.RELEASE.2025-09-07T16-13-09Z
  minio: downloaded, digest verified
  mc: downloading https://carlos-ci-mirror-640012953448.s3.eu-west-1.amazonaws.com/minio/mc.linux-arm64.RELEASE.2025-08-13T08-35-41Z
  mc: downloaded, digest verified
  minio healthy on 127.0.0.1:36493
Added `local` successfully.
Bucket created successfully `local/contract-bucket`.
Bucket created successfully `local/denied-bucket`.
Created policy `contract-only` successfully.
Added user `scopeduser` successfully.
Attached Policies: [contract-only]
To User: scopeduser
  buckets and scoped user ready
=== RUN   TestDeliveredContractMinio
=== RUN   TestDeliveredContractMinio/put
=== RUN   TestDeliveredContractMinio/get_round-trips_the_body
=== RUN   TestDeliveredContractMinio/list_shows_the_key
=== RUN   TestDeliveredContractMinio/head_and_list_agree_on_the_version
=== RUN   TestDeliveredContractMinio/the_app_cannot_tag_its_own_object
=== RUN   TestDeliveredContractMinio/the_app_cannot_tag_its_own_object/not_by_PutObjectTagging
=== RUN   TestDeliveredContractMinio/the_app_cannot_tag_its_own_object/and_not_by_x-amz-tagging_on_upload
=== RUN   TestDeliveredContractMinio/the_app_cannot_tag_by_any_other_route
=== RUN   TestDeliveredContractMinio/the_app_cannot_tag_by_any_other_route/not_by_CreateMultipartUpload
=== RUN   TestDeliveredContractMinio/the_app_cannot_tag_by_any_other_route/not_by_CopyObject_with_a_REPLACE_tagging_directive
=== RUN   TestDeliveredContractMinio/the_app_cannot_tag_by_any_other_route/but_multipart_itself_is_allowed
=== RUN   TestDeliveredContractMinio/the_app_cannot_tag_by_any_other_route/and_copy_itself_is_allowed
=== RUN   TestDeliveredContractMinio/the_app_cannot_tag_by_any_other_route/a_POST-policy_forged_tag_with_a_matching_version_is_still_not_a_verdict
=== RUN   TestDeliveredContractMinio/the_app_cannot_tag_by_any_other_route/and_an_ordinary_tagged-with-something-else_upload_is_allowed
=== RUN   TestDeliveredContractMinio/delete_removes_it
=== RUN   TestDeliveredContractMinio/cross-bucket_denial
--- PASS: TestDeliveredContractMinio (0.03s)
    --- PASS: TestDeliveredContractMinio/put (0.00s)
    --- PASS: TestDeliveredContractMinio/get_round-trips_the_body (0.00s)
    --- PASS: TestDeliveredContractMinio/list_shows_the_key (0.00s)
    --- PASS: TestDeliveredContractMinio/head_and_list_agree_on_the_version (0.00s)
    --- PASS: TestDeliveredContractMinio/the_app_cannot_tag_its_own_object (0.00s)
        --- PASS: TestDeliveredContractMinio/the_app_cannot_tag_its_own_object/not_by_PutObjectTagging (0.00s)
        --- PASS: TestDeliveredContractMinio/the_app_cannot_tag_its_own_object/and_not_by_x-amz-tagging_on_upload (0.00s)
    --- PASS: TestDeliveredContractMinio/the_app_cannot_tag_by_any_other_route (0.02s)
        --- PASS: TestDeliveredContractMinio/the_app_cannot_tag_by_any_other_route/not_by_CreateMultipartUpload (0.00s)
        --- PASS: TestDeliveredContractMinio/the_app_cannot_tag_by_any_other_route/not_by_CopyObject_with_a_REPLACE_tagging_directive (0.00s)
        --- PASS: TestDeliveredContractMinio/the_app_cannot_tag_by_any_other_route/but_multipart_itself_is_allowed (0.00s)
        --- PASS: TestDeliveredContractMinio/the_app_cannot_tag_by_any_other_route/and_copy_itself_is_allowed (0.00s)
        --- PASS: TestDeliveredContractMinio/the_app_cannot_tag_by_any_other_route/a_POST-policy_forged_tag_with_a_matching_version_is_still_not_a_verdict (0.00s)
        --- PASS: TestDeliveredContractMinio/the_app_cannot_tag_by_any_other_route/and_an_ordinary_tagged-with-something-else_upload_is_allowed (0.00s)
    --- PASS: TestDeliveredContractMinio/delete_removes_it (0.00s)
    --- PASS: TestDeliveredContractMinio/cross-bucket_denial (0.00s)
PASS
ok  	github.com/carlosframework/platform/internal/objstore	0.039s
=== RUN   TestT4StorageProbeMinio
2026/11/24 21:12:53 moves: T4: STORE: list: operation error S3: ListObjectsV2, https response error StatusCode: 403, RequestID: 18EB178DA711B1CE, HostID: 5df68f5bd45d9ea9c857e6696a49c9ad469ced907e575af296835e503d6cc45c, api error SignatureDoesNotMatch: The request signature we calculated does not match the signature you provided. Check your key and signing method.
--- PASS: TestT4StorageProbeMinio (0.01s)
PASS
ok  	github.com/carlosframework/platform/internal/host	0.043s
=== RUN   TestS3StoreMinioContract
=== RUN   TestS3StoreMinioContract/conditional_get_and_etag_listing
=== RUN   TestS3StoreMinioContract/bump_through_every_mutation_path
--- PASS: TestS3StoreMinioContract (0.04s)
    --- PASS: TestS3StoreMinioContract/conditional_get_and_etag_listing (0.01s)
    --- PASS: TestS3StoreMinioContract/bump_through_every_mutation_path (0.02s)
PASS
ok  	github.com/carlosframework/platform/internal/release	0.043s
Bucket created successfully `local/analytics-versions`.
local/analytics-versions versioning is enabled
Created policy `analytics-versions` successfully.
Added user `analyticsversions` successfully.
Attached Policies: [analytics-versions]
To User: analyticsversions
=== RUN   TestS3StoreMinioVersions
--- PASS: TestS3StoreMinioVersions (0.04s)
PASS
ok  	github.com/carlosframework/platform/internal/release	0.047s
Bucket created successfully `local/store-versioned`.
local/store-versioned versioning is enabled
Created policy `store-versioned` successfully.
Added user `storeversioned` successfully.
Attached Policies: [store-versioned]
To User: storeversioned
=== RUN   TestVersionedContractMinio
--- PASS: TestVersionedContractMinio (0.01s)
PASS
ok  	github.com/carlosframework/platform/internal/objstore	0.020s
=== RUN   TestEndToEndMinio
=== RUN   TestEndToEndMinio/plan
=== RUN   TestEndToEndMinio/roll
=== RUN   TestEndToEndMinio/replace
=== RUN   TestEndToEndMinio/remove
--- PASS: TestEndToEndMinio (0.49s)
    --- PASS: TestEndToEndMinio/plan (0.01s)
    --- PASS: TestEndToEndMinio/roll (0.13s)
    --- PASS: TestEndToEndMinio/replace (0.16s)
    --- PASS: TestEndToEndMinio/remove (0.16s)
PASS
ok  	github.com/carlosframework/platform/internal/grouproll	0.503s
Bucket created successfully `local/dbf-deploy`.
Bucket created successfully `local/dbf-data-ie`.
Bucket created successfully `local/dbf-data-uk`.
local/dbf-deploy versioning is enabled
Created policy `dbf-console` successfully.
Created policy `dbf-ukbox` successfully.
Added user `dbfconsole` successfully.
Added user `dbfukbox` successfully.
Attached Policies: [dbf-console]
To User: dbfconsole
Attached Policies: [dbf-ukbox]
To User: dbfukbox
=== RUN   TestDBForwardMinio
2026/11/24 21:13:01 INFO replica sync system=store db=source.db replica=file txid.replica=0000000000000000 txid.db=0000000000000001
2026/11/24 21:13:01 INFO ltx file uploaded system=store db=source.db replica=file level=0 minTXID=0000000000000001 maxTXID=0000000000000001 size=720
2026/11/24 21:13:01 INFO replica sync system=store db=source.db replica=file txid.replica=0000000000000001 txid.db=0000000000000001
2026/11/24 21:13:01 INFO replica sync system=store db=source.db replica=file txid.replica=0000000000000001 txid.db=0000000000000002
2026/11/24 21:13:01 INFO ltx file uploaded system=store db=source.db replica=file level=0 minTXID=0000000000000002 maxTXID=0000000000000002 size=370
2026/11/24 21:13:01 INFO replica sync system=store db=source.db replica=file txid.replica=0000000000000002 txid.db=0000000000000002
2026/11/24 21:13:01 INFO replica sync system=store db=source.db replica=file txid.replica=0000000000000002 txid.db=0000000000000003
2026/11/24 21:13:01 INFO ltx file uploaded system=store db=source.db replica=file level=0 minTXID=0000000000000003 maxTXID=0000000000000003 size=454
2026/11/24 21:13:01 INFO replica sync system=store db=source.db replica=file txid.replica=0000000000000003 txid.db=0000000000000003
2026/11/24 21:13:01 INFO replica sync system=store db=source.db replica=file txid.replica=0000000000000000 txid.db=0000000000000001
2026/11/24 21:13:01 INFO ltx file uploaded system=store db=source.db replica=file level=0 minTXID=0000000000000001 maxTXID=0000000000000001 size=720
2026/11/24 21:13:01 INFO replica sync system=store db=source.db replica=file txid.replica=0000000000000001 txid.db=0000000000000001
2026/11/24 21:13:01 console: CARLOS_SECRETS_PUBKEY is unset, so no region outside the home can be chosen automatically
2026/11/24 21:13:01 console: could not notify member@example.com of a CLI token issue: keymail: lookup member@example.com: keymail: GET /api/federation/lookup?addr=member%40example.com&from=console%40127.0.0.1%3A44841: could not determine target mailbox
    agent.go:136: dbreads: dbr_nusku5ekykarqkaterzjiftomu: planned 3 files (1544 bytes) and restored to 3 in 14ms
    agent.go:136: dbreads: dbr_nusku5ekykarqkaterzjiftomu: output 5 bytes in 1 confirmed chunks in 2ms
2026/11/24 21:13:02 console: db read dbr_nusku5ekykarqkaterzjiftomu: relayed 1 chunks (102 bytes) in 1.005s, ended done
    agent.go:136: dbreads: dbr_czrcs7kkv5vereuclwrw4gnvvi: planned 1 files (720 bytes) and restored to 1 in 11ms
    agent.go:136: dbreads: dbr_czrcs7kkv5vereuclwrw4gnvvi: output 5 bytes in 1 confirmed chunks in 2ms
2026/11/24 21:13:03 console: db read dbr_czrcs7kkv5vereuclwrw4gnvvi: relayed 1 chunks (102 bytes) in 1.005s, ended done
    agent.go:136: dbreads: dbr_pcp55l45rmrcaztzdzemfivuze: planned 3 files (1544 bytes) and held through 3 in 12ms
    agent.go:136: dbreads: dbr_pcp55l45rmrcaztzdzemfivuze: output 1544 bytes in 1 confirmed chunks in 1ms
2026/11/24 21:13:04 console: db read dbr_pcp55l45rmrcaztzdzemfivuze: relayed 1 chunks (1641 bytes) in 1.006s, ended done
=== RUN   TestDBForwardMinio/by_disconnect
=== NAME  TestDBForwardMinio
    agent.go:136: dbreads: dbr_hvni7xcqwaiw7hd5mxqjxzqx7e: planned 3 files (1544 bytes) and restored to 3 in 13ms
2026/11/24 21:13:04 console: db read dbr_hvni7xcqwaiw7hd5mxqjxzqx7e: relayed 0 chunks (0 bytes) in 25ms, ended client gone
    agent.go:136: dbreads: dbr_hvni7xcqwaiw7hd5mxqjxzqx7e: output 5 bytes in 1 confirmed chunks in 105ms
=== RUN   TestDBForwardMinio/by_timeout
=== NAME  TestDBForwardMinio
    agent.go:136: dbreads: dbr_rtori37i2qjcypnwtibkpsdz4q: planned 3 files (1544 bytes) and restored to 3 in 13ms
2026/11/24 21:13:24 console: db read dbr_rtori37i2qjcypnwtibkpsdz4q: relayed 0 chunks (0 bytes) in 19.394s, ended no-result
    agent.go:136: dbreads: dbr_rtori37i2qjcypnwtibkpsdz4q: output 5 bytes in 1 confirmed chunks in 19.367s
--- PASS: TestDBForwardMinio (23.06s)
    --- PASS: TestDBForwardMinio/by_disconnect (0.24s)
    --- PASS: TestDBForwardMinio/by_timeout (19.50s)
PASS
ok  	github.com/carlosframework/platform/internal/console	23.107s
Bucket created successfully `local/media-transfers`.
Bucket created successfully `local/media-transfer-results`.
Created policy `media-transfers` successfully.
Added user `mediatransfers` successfully.
Attached Policies: [media-transfers]
To User: mediatransfers
=== RUN   TestMediaTransfersMinio
    upload.go:117: codec: the store already holds video.mp4
    upload.go:117: codec: the store already holds video.m3u8
    upload.go:117: codec: the store already holds poster.jpg
--- PASS: TestMediaTransfersMinio (0.06s)
PASS
ok  	github.com/carlosframework/platform/internal/mediaaws	0.064s
Bucket created successfully `local/media-local-store`.
Bucket created successfully `local/media-local-results`.
Created policy `media-local` successfully.
Added user `medialocal` successfully.
Attached Policies: [media-local]
To User: medialocal
=== RUN   TestLocalEndToEndMinio
--- PASS: TestLocalEndToEndMinio (0.58s)
PASS
ok  	github.com/carlosframework/platform/internal/medialocal	0.582s
=== RUN   TestHeldHandoverTwoBoxMinio
2026/11/24 21:13:29 edge: mesh key: minted
2026/11/24 21:13:29 provision: minted sidecar route bot0.shop.bac.sidecar.internal (app "shop" acct "bac" args ["work"])
2026/11/24 21:13:29 provision: minted sidecar route bot0.shop.bac.sidecar.internal (app "shop" acct "bac" args ["work"])
2026/11/24 21:13:29 tenant admission is open. accepting tenant work
2026/11/24 21:13:29 activator: HA placement host=shop-dd86cd04.example.test kind=Place ref=annie reason=roomiest generation=2026-11-24T21:13:29Z lock_generation=0
2026/11/24 21:13:29 lease: t8-dd86cd04/shop-dd86cd04.example.test: HA lease acquired in 4ms (first wake)
2026/11/24 21:13:29 activator: shop-dd86cd04.example.test: restored (no-marker): first wake, the prefix proven empty, booting fresh
2026/11/24 21:13:29 activator: shop-dd86cd04.example.test: started carlos-instance@shop\x2ddd86cd04.example.test.service memory.max=536870912 (build 0s, prepare (dirs 0s, admin token 0s, instance key 0s, env 6ms, control socket 0s, key gate 0s, logs 0s) 7ms, launch file 0s, gate 0s, root start 1ms)
2026/11/24 21:13:29 activator: shop-dd86cd04.example.test: carlos-instance@shop\x2ddd86cd04.example.test.service launched in 8ms, healthy 0s later
2026/11/24 21:13:29 activator: shop-dd86cd04.example.test: woke in 22ms: checks 0s, lease 5ms, restore 0s, identity 0s, protect 0s, spawn 8ms, replicate 8ms
2026/11/24 21:13:29 lease: t8-dd86cd04/plain-dd86cd04.example.test: acquired in 2ms (client 0s, lock read and write 2ms)
2026/11/24 21:13:29 activator: no replica for plain-dd86cd04.example.test in s3://contract-bucket/t8-dd86cd04/plain-dd86cd04.example.test — booting fresh
2026/11/24 21:13:29 activator: plain-dd86cd04.example.test: started carlos-instance@plain\x2ddd86cd04.example.test.service memory.max=536870912 (build 0s, prepare (dirs 0s, admin token 1ms, instance key 0s, env 4ms, control socket 0s, key gate 0s, logs 0s) 6ms, launch file 0s, gate 0s, root start 1ms)
2026/11/24 21:13:29 activator: plain-dd86cd04.example.test: carlos-instance@plain\x2ddd86cd04.example.test.service launched in 7ms, healthy 0s later
2026/11/24 21:13:29 activator: plain-dd86cd04.example.test: woke in 104ms: checks 0s, lease 2ms, restore 20ms, identity 0s, protect 0s, spawn 7ms, replicate 75ms
2026/11/24 21:13:29 lease: t8-dd86cd04/bot0.shop.bac.sidecar.internal: HA lease acquired in 4ms (first wake)
2026/11/24 21:13:29 activator: bot0.shop.bac.sidecar.internal: restored (no-marker): first wake, the prefix proven empty, booting fresh
2026/11/24 21:13:29 activator: bot0.shop.bac.sidecar.internal: woke in 19ms: checks 0s, lease 5ms, restore 0s, identity 0s, protect 0s, spawn 7ms, settle 0s, replicate 6ms
2026/11/24 21:13:29 activator: next-due probe plain-dd86cd04.example.test: decode /api/next-due: invalid character 'a' looking for beginning of value — recording none (it sleeps until a request)
2026/11/24 21:13:29 activator: plain-dd86cd04.example.test hibernated
2026/11/24 21:13:29 activator: next-due probe shop-dd86cd04.example.test: decode /api/next-due: invalid character 'a' looking for beginning of value — recording none (it sleeps until a request)
2026/11/24 21:13:29 activator: bot0.shop.bac.sidecar.internal: released with a marker (clean true, txid 1, files 3:87af6b0d33fec0636c6db211257998623046e7891806d403b90731a9ae0a19e9) in 6ms: files 1ms, sync 2ms, record 1ms, marker 2ms
2026/11/24 21:13:29 activator: bot0.shop.bac.sidecar.internal hibernated
2026/11/24 21:13:29 activator: shop-dd86cd04.example.test: released with a marker (clean true, txid 1, files 3:80f0889322eec9faff3e778f03f50f578a2fa30ae9ccb0ffded1461e454c6daf) in 6ms: files 1ms, sync 2ms, record 1ms, marker 2ms
2026/11/24 21:13:29 activator: shop-dd86cd04.example.test hibernated
2026/11/24 21:13:29 lease: t8-dd86cd04/shop-dd86cd04.example.test: HA lease acquired in 4ms (clean marker)
2026/11/24 21:13:29 activator: shop-dd86cd04.example.test: restored (other-box)
2026/11/24 21:13:29 activator: shop-dd86cd04.example.test: started carlos-instance@shop\x2ddd86cd04.example.test.service memory.max=536870912 (build 0s, prepare (dirs 0s, admin token 0s, instance key 0s, env 1ms, control socket 0s, key gate 0s, logs 0s) 1ms, launch file 0s, gate 0s, root start 1ms)
2026/11/24 21:13:29 activator: shop-dd86cd04.example.test: carlos-instance@shop\x2ddd86cd04.example.test.service launched in 2ms, healthy 0s later
2026/11/24 21:13:29 activator: shop-dd86cd04.example.test: woke in 39ms: checks 0s, lease 5ms, restore 25ms, identity 0s, protect 1ms, spawn 2ms, replicate 7ms
2026/11/24 21:13:29 edge: ha-take shop-dd86cd04.example.test from annie (txn t8-witness, marker generation 1): holder betty, generation 2
2026/11/24 21:13:29 edge: forward shop-dd86cd04.example.test: annie handed the request over to betty; sending it there (occurrence #1)
    hadrain_twobox_minio_linux_test.go:1238: drain report: {V:1 Transaction:t8-witness Incarnation:4086dc6fc1fa43f4cb7d4b4aadedd8ee Step:move Result:ok Reasons:[] Fence:t8-witness StartedAt:2026-11-24 21:13:29.598122839 +0000 UTC FinishedAt:2026-11-24 21:13:29.695959415 +0000 UTC Acked:[betty carol] Departed:[] Moved:[{Host:shop-dd86cd04.example.test Holder:betty Gen:2 Confirmed:take}] Released:[{Host:plain-dd86cd04.example.test Kind:other Marker:true Clean:true Reason:} {Host:bot0.shop.bac.sidecar.internal Kind:worker Marker:true Clean:true Reason:}] Unclean:[] Left:[] Holds:{LongestMS:72 Todays:0 RefusedAtOnce:1} Closed:0 Quiet:{DrainQuiet:{Waking:0 Stopping:0 Recovering:0 Owed:0} Held:[]}}
    hadrain_twobox_minio_linux_test.go:1239: driver calls: [begin shop-dd86cd04.example.test <nil> stop plain-dd86cd04.example.test marker=true clean=true <nil> releasing shop-dd86cd04.example.test <nil> stop bot0.shop.bac.sidecar.internal marker=true clean=true <nil> stop shop-dd86cd04.example.test marker=true clean=true <nil> taken shop-dd86cd04.example.test betty <nil> end-moves]
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: PUT /contract-bucket/t8-dd86cd04/bot0.shop.bac.sidecar.internal/0009/0000000000000001-0000000000000001.ltx
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/bot0.shop.bac.sidecar.internal/0001/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/bot0.shop.bac.sidecar.internal/0009/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/bot0.shop.bac.sidecar.internal/0000/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/bot0.shop.bac.sidecar.internal/0001/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/bot0.shop.bac.sidecar.internal/0002/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/bot0.shop.bac.sidecar.internal/0003/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: GET /contract-bucket/t8-dd86cd04/shop-dd86cd04.example.test/lock.json
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: DELETE /contract-bucket/t8-dd86cd04/plain-dd86cd04.example.test/lock.json
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: PUT /contract-bucket/t8-dd86cd04/bot0.shop.bac.sidecar.internal/0009/0000000000000001-0000000000000001.ltx
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: PUT /contract-bucket/t8-dd86cd04/bot0.shop.bac.sidecar.internal/lock.json
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: PUT /contract-bucket/t8-dd86cd04/shop-dd86cd04.example.test/0009/0000000000000001-0000000000000001.ltx
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: PUT /contract-bucket/t8-dd86cd04/shop-dd86cd04.example.test/lock.json
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: GET /contract-bucket/t8-dd86cd04/shop-dd86cd04.example.test/lock.json
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: PUT /contract-bucket/t8-dd86cd04/shop-dd86cd04.example.test/lock.json
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: GET /contract-bucket/t8-dd86cd04/shop-dd86cd04.example.test/head.json
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/generations/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0009/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0008/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0007/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0006/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0005/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0004/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0003/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0002/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0001/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0000/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0009/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0008/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0007/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0006/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0005/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0004/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0003/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0002/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0001/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0000/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: GET /contract-bucket/t8-dd86cd04/shop-dd86cd04.example.test/0009/0000000000000001-0000000000000001.ltx
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: GET /contract-bucket/t8-dd86cd04/shop-dd86cd04.example.test/files/0/manifest.json
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: GET /contract-bucket/t8-dd86cd04/shop-dd86cd04.example.test/files/0/objects/0000000000000001-fc5b0d7f2bcea45b2d97d2926c5a5397f5a4fb81450319dd1a891c9e48fb0912
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: GET /contract-bucket/t8-dd86cd04/shop-dd86cd04.example.test/files/0/objects/0000000000000003-a77cc18808ebdf1ce5a48d63807b9d0938101b5d7dc6e43b9c2b5acd09ba1628
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0000/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: GET /contract-bucket/t8-dd86cd04/shop-dd86cd04.example.test/0000/0000000000000001-0000000000000001.ltx
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0003/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0000/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0002/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: PUT /contract-bucket/t8-dd86cd04/shop-dd86cd04.example.test/0000/0000000000000002-0000000000000002.ltx
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0009/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0009/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: GET /contract-bucket/t8-dd86cd04/shop-dd86cd04.example.test/lock.json
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0001/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0002/
    hadrain_twobox_minio_linux_test.go:1241: S3 during the drain: LIST /contract-bucket?t8-dd86cd04/shop-dd86cd04.example.test/0003/
    hadrain_twobox_minio_linux_test.go:1243: drain took 132ms; S3 calls 53 (DELETE lock=1 GET files=3 GET head=1 GET lock=3 GET replica=2 LIST replica=36 PUT lock=3 PUT replica=4); deployment store calls 20 (GET edges=14 LIST edges=4 PUT edges=2)
    hadrain_twobox_minio_linux_test.go:1367: the fenced A's start gate answers 503 "This service is unavailable. Try again later.\n" (Retry-After "10")
2026/11/24 21:13:29 lease: t8-dd86cd04/plain-dd86cd04.example.test: acquired in 2ms (client 0s, lock read and write 1ms)
2026/11/24 21:13:29 activator: plain-dd86cd04.example.test: started carlos-instance@plain\x2ddd86cd04.example.test.service memory.max=536870912 (build 0s, prepare (dirs 0s, admin token 0s, instance key 0s, env 0s, control socket 0s, key gate 0s, logs 0s) 0s, launch file 0s, gate 0s, root start 1ms)
2026/11/24 21:13:29 activator: plain-dd86cd04.example.test: carlos-instance@plain\x2ddd86cd04.example.test.service launched in 1ms, healthy 0s later
2026/11/24 21:13:29 lease: /tmp/carlos-minio-contract-PocgBQ/g/dw3542043177/data/instances/plain-dd86cd04.example.test/plain-dd86cd04.example.test.db: continuity with the last clean close not proven; snapshot 1-0000000000000001 written before serving
2026/11/24 21:13:29 activator: plain-dd86cd04.example.test: woke in 10ms: checks 0s, lease 2ms, restore 0s, identity 0s, protect 1ms, spawn 2ms, replicate 6ms
2026/11/24 21:13:29 activator: next-due probe shop-dd86cd04.example.test: decode /api/next-due: invalid character 'b' looking for beginning of value — recording none (it sleeps until a request)
2026/11/24 21:13:29 activator: shop-dd86cd04.example.test: released with a marker (clean true, txid 2, files 3:80f0889322eec9faff3e778f03f50f578a2fa30ae9ccb0ffded1461e454c6daf) in 4ms: files 1ms, sync 0s, record 1ms, marker 2ms
2026/11/24 21:13:29 activator: shop-dd86cd04.example.test hibernated
2026/11/24 21:13:29 tenant admission is closed for shutdown
2026/11/24 21:13:29 activator: next-due probe plain-dd86cd04.example.test: decode /api/next-due: invalid character 'a' looking for beginning of value — recording none (it sleeps until a request)
2026/11/24 21:13:29 activator: plain-dd86cd04.example.test hibernated
--- PASS: TestHeldHandoverTwoBoxMinio (0.52s)
=== RUN   TestHeldHandoverLostLeaseMinio
2026/11/24 21:13:29 edge: mesh key: minted
2026/11/24 21:13:29 provision: minted sidecar route bot0.shop.bac.sidecar.internal (app "shop" acct "bac" args ["work"])
2026/11/24 21:13:29 provision: minted sidecar route bot0.shop.bac.sidecar.internal (app "shop" acct "bac" args ["work"])
2026/11/24 21:13:29 tenant admission is open. accepting tenant work
2026/11/24 21:13:29 activator: HA placement host=shop-e317e8c7.example.test kind=Place ref=annie reason=roomiest generation=2026-11-24T21:13:29Z lock_generation=0
2026/11/24 21:13:29 lease: t8-e317e8c7/shop-e317e8c7.example.test: HA lease acquired in 3ms (first wake)
2026/11/24 21:13:29 activator: shop-e317e8c7.example.test: restored (no-marker): first wake, the prefix proven empty, booting fresh
2026/11/24 21:13:29 activator: shop-e317e8c7.example.test: started carlos-instance@shop\x2de317e8c7.example.test.service memory.max=536870912 (build 0s, prepare (dirs 0s, admin token 0s, instance key 0s, env 6ms, control socket 0s, key gate 0s, logs 0s) 6ms, launch file 0s, gate 0s, root start 1ms)
2026/11/24 21:13:29 activator: shop-e317e8c7.example.test: carlos-instance@shop\x2de317e8c7.example.test.service launched in 7ms, healthy 0s later
2026/11/24 21:13:29 activator: shop-e317e8c7.example.test: woke in 67ms: checks 0s, lease 4ms, restore 0s, identity 0s, protect 0s, spawn 7ms, replicate 55ms
2026/11/24 21:13:30 activator: next-due probe shop-e317e8c7.example.test: decode /api/next-due: invalid character 'a' looking for beginning of value — recording none (it sleeps until a request)
2026/11/24 21:13:30 activator: final checkpoint shop-e317e8c7.example.test: lease: release marker owed for s3://contract-bucket/t8-e317e8c7/shop-e317e8c7.example.test/lock.json (If-Match "609f584a0ef8536f3db7f5bb2dd6ad4a"): lease: write release marker: operation error S3: PutObject, https response error StatusCode: 503, RequestID: , HostID: , api error ServiceUnavailable: witness: refused
2026/11/24 21:13:30 activator: shop-e317e8c7.example.test hibernated
2026/11/24 21:13:30 activator: handover of shop-e317e8c7.example.test left: released without a marker; its held requests get today's answer
    hadrain_twobox_minio_linux_test.go:1469: the held request's hold ended "shop-e317e8c7.example.test client 4 "
    hadrain_twobox_minio_linux_test.go:1486: driver calls: [begin shop-e317e8c7.example.test <nil> releasing shop-e317e8c7.example.test <nil> stop shop-e317e8c7.example.test marker=false clean=false <nil> left shop-e317e8c7.example.test released without a marker]
    hadrain_twobox_minio_linux_test.go:1487: a request after the loss: 503 "This instance cannot wake right now. Please try again shortly.\n" (Retry-After "10", holder "none", 0s, err <nil>)
2026/11/24 21:13:30 tenant admission is closed for shutdown
2026/11/24 21:13:30 http: proxy error: context canceled
--- PASS: TestHeldHandoverLostLeaseMinio (0.32s)
PASS
ok  	github.com/carlosframework/platform/internal/host	0.891s
Bucket created successfully `local/gen-take`.
local/gen-take versioning is enabled
Created policy `gen-take` successfully.
Added user `gentake` successfully.
Attached Policies: [gen-take]
To User: gentake
=== RUN   TestGenerationTakeMinio
=== RUN   TestGenerationTakeMinio/take
2026/11/24 21:13:31 lease: instances/gen-1795554811352640287.shop.example.com: HA lease acquired in 5ms (first wake)
2026/11/24 21:13:31 lease: instances/gen-1795554811352640287.shop.example.com: HA lease acquired in 3ms (holder terminated)
    gentake_minio_test.go:308: a second create-only copy onto instances/gen-1795554811352640287.shop.example.com/g-00000000000000000002/0000/0000000000000001-0000000000000001.ltx: <nil> (destination condition honoured: false)
2026/11/24 21:13:31 ERROR retention enforcement failed system=store db=w.example.com.db error="enforce snapshot retention: remove ltx files: lease: invalid or changed generation binding"
2026/11/24 21:13:31 http: proxy error: context canceled
2026/11/24 21:13:31 http: proxy error: context canceled
2026/11/24 21:13:31 ERROR retention enforcement failed system=store db=w.example.com.db error="enforce snapshot retention: remove ltx files: lease: a write has waited too long to reach storage (write fence)"
=== RUN   TestGenerationTakeMinio/switch-412
2026/11/24 21:13:31 lease: instances/gen-1795554811525429431.shop.example.com: HA lease acquired in 4ms (first wake)
2026/11/24 21:13:31 ERROR retention enforcement failed system=store db=seed.db error="enforce snapshot retention: fetch ltx files: lease: a write has waited too long to reach storage (write fence)"
2026/11/24 21:13:31 lease: instances/gen-1795554811525429431.shop.example.com: HA lease acquired in 3ms (clean marker)
=== RUN   TestGenerationTakeMinio/copy-version
=== RUN   TestGenerationTakeMinio/store-time
2026/11/24 21:13:31 lease: instances/gen-1795554811579220168.shop.example.com: HA lease acquired in 4ms (first wake)
2026/11/24 21:13:31 ERROR retention enforcement failed system=store db=seed.db error="enforce snapshot retention: remove ltx files: lease: invalid or changed generation binding"
2026/11/24 21:13:31 lease: instances/gen-1795554811579220168.shop.example.com: HA lease acquired in 3ms (clean marker)
2026/11/24 21:13:31 lease: instances/gen-1795554811579220168.shop.example.com: HA lease acquired in 4ms (unclean marker)
2026/11/24 21:13:31 lease: instances/gen-1795554811579220168.shop.example.com: HA lease acquired in 3ms (unclean marker)
2026/11/24 21:13:31 lease: instances/gen-1795554811579220168.shop.example.com: HA lease acquired in 3ms (unclean marker)
2026/11/24 21:13:31 lease: instances/gen-1795554811579220168.shop.example.com: HA lease acquired in 3ms (unclean marker)
=== RUN   TestGenerationTakeMinio/skew
--- PASS: TestGenerationTakeMinio (0.40s)
    --- PASS: TestGenerationTakeMinio/take (0.17s)
    --- PASS: TestGenerationTakeMinio/switch-412 (0.04s)
    --- PASS: TestGenerationTakeMinio/copy-version (0.01s)
    --- PASS: TestGenerationTakeMinio/store-time (0.16s)
    --- PASS: TestGenerationTakeMinio/skew (0.01s)
PASS
ok  	github.com/carlosframework/platform/internal/lease	0.411s
minio contract: PASS
=== staticcheck ===
go version go1.26.10 linux/arm64
go: downloading honnef.co/go/tools v0.8.2
go: downloading golang.org/x/exp/typeparams v0.0.0-20231108232855-2478ac86f678
go: downloading github.com/BurntSushi/toml v1.4.1-0.20240526193622-a339e1f7089c
go: downloading golang.org/x/sync v0.23.0
go: downloading golang.org/x/exp v0.0.0-20231110203233-9a3e6036ecaa
staticcheck: clean
=== govulncheck ===
go version go1.26.10 linux/arm64
go: downloading golang.org/x/vuln v1.8.0
go: downloading golang.org/x/telemetry v0.0.0-20260908163034-4bcc4b2ee518
go: downloading golang.org/x/tools v0.50.0
govulncheck: scanned github.com/carlosframework/platform, amadan.net/carlos/platform.git/launchctx
GO-2026-6859  called  stdlib@v1.26.10, fixed in v1.26.11
    HTTP/1 server crash due to MaxBytesReader header race in net/http
    excepted until 2027-01-31 (.amadan/govulncheck-exceptions.tsv:9): net/http MaxBytesReader header race, fixed in go1.26.11. CI and releases stay on go1.26.10 because 1.26.11 deadlocks the edge's Expect: 100-continue path (#897, .amadan/go-toolchain.sh); #904 checked every production MaxBytesReader site and found it unreachable.
GO-2026-5932  required  golang.org/x/crypto@v0.58.0, fixed in v0.58.1-0.20261009181718-2f1f834330b2
    The golang.org/x/crypto/openpgp package is unmaintained, unsafe by design, and has known security issues
    not fatal: no call path to the vulnerable code
govulncheck: clean (2 finding(s), none called outside .amadan/govulncheck-exceptions.tsv)
=== code-health ===
go version go1.26.10 linux/arm64
    codehealth_test.go:42: scanned in 1m49.319s
    codehealth_test.go:107: line metrics (code lines, then physical):
          file-lines  5471  7324  internal/activator activator_test.go
          file-lines  4223  7052  internal/console server.go
          file-lines  4175  6358  . apimode.go
          file-lines  3785  7224  internal/activator activator.go
          file-lines  3530  4459  . apimode_test.go
          file-lines  3261  3864  internal/registry registry_test.go
          file-lines  3188  6348  internal/host agent.go
          file-lines  3094  3992  internal/provision reconcile_test.go
          func-lines   870   891  internal/host plan14InstalledClaimLaunch
          func-lines   811  1275  internal/provision Reconcile
          func-lines   769  1242  internal/console (*Server).handleAPIInstanceCreate
          func-lines   689  1238  internal/host runAgent
          func-lines   571   908  internal/activator (*Service).doWakeOnce
          func-lines   538   546  internal/host runServingParkPeerNamespace
          func-lines   519   712  . runRoute
          func-lines   509   569  internal/host TestPagingIsRateLimited
          func-lines   494   809  internal/release adoptHost
          func-lines   441   500  internal/host TestRootInstanceStopExecStop
          func-lines   421   436  internal/host (*ClaimWakeAssembly).Build
          func-lines   421   437  internal/team TestFixture
          func-lines   412   414  internal/console TestDemoProtectionsSourceToLimitAndTakedown
          func-lines   408   485  . TestFleetAppServesThroughTheHub
          func-lines   402   406  internal/registry (*Registry).haJournal
          func-lines   400   868  internal/provision rootReadArchivedChain
          func-lines   399   732  internal/release PassFilter
          func-lines   390   398  internal/host runFilesSeedPreparationWithLive
          func-lines   383   406  internal/console TestDemoSourceToLiveAndUpdate
          func-lines   379   898  internal/edge (*Edge).ServeHTTP
          func-lines   378   600  internal/console (*Server).handleAPIShip
          func-lines   374   377  internal/host plan14RequiredArtifactsRootRunner
          func-lines   371   417  internal/host TestRootEgressKernelProof
          func-lines   367   636  cmd/console serve
          func-lines   364   371  internal/host testRootMigrationBootstrap
          func-lines   360   362  internal/edge TestDemoAPIAliasBoundary
          func-lines   357   358  internal/registry (*Registry).dispatchRemote
          func-lines   355   372  internal/host TestRootSandboxUpdateFromOldBox
          func-lines   343   354  internal/analytics Prune
          func-lines   340   353  internal/host newColdRootHarness
          func-lines   335   557  internal/console (*Store).migrate
          func-lines   334   334  internal/host TestPlan12RecoveryRestoreSourceDatabase
          func-lines   330   371  internal/edge TestRegionalNameNeverLeavesItsRegion
          func-lines   329   471  . runDeploy
          func-lines   329   329  internal/host TestPlan12RecoveryRestoreSourceDatabase.func1
          func-lines   327   369  internal/edge TestTunnelWebSocketEndToEnd
          func-lines   325   455  internal/objstore TestDeliveredContractMinio
          func-lines   320   654  internal/appconfig SyncExecWithCallbacks
          func-lines   315   318  internal/host plan14TimerIntention
          func-lines   311   314  internal/host plan14TimerIntention.func1
          func-lines   310   315  internal/hostbox ColdHandover.Run
          func-lines   308   309  internal/host rootFilesSeedIsolatedWitness
          func-lines   305   323  internal/host hairpinKernelWitness
          func-lines   304   308  internal/console TestHAP2ProductionDoors
          func-lines   302   329  internal/host TestRootG2PoolIngress
        release-importers: . cmd/console internal/activator internal/analytics internal/appconfig internal/apperr internal/applog internal/apppolicy internal/boxid internal/boxvolumes internal/console internal/dbreads internal/dbreads/dbreadstest internal/dbverify internal/demobuild internal/domains internal/doorkey internal/edge internal/edgeproof internal/edgesfile internal/fleetapi internal/grouproll internal/grouprollaws internal/historyreadback internal/host internal/hostactors internal/hostbox internal/hostclaim internal/hostevidence internal/hostexec internal/hostfence internal/hostfiles internal/hostfloor internal/hostguard internal/hostops internal/hostrelocate internal/hostresolve internal/instancectl internal/instanceupdates internal/interactive internal/layout internal/lease internal/ledger internal/mail internal/mailer internal/mailsubmit internal/metrics internal/moves internal/objstore internal/ops internal/park internal/plans internal/provision internal/relay internal/rollout internal/rootfsimage internal/runs internal/s3fake internal/schedule internal/seeds internal/status internal/telemetry internal/usage internal/vet scripts/pathmapcheck scripts/witness-pointer
        not scanned (211 files):
          cmd/carlos-media/drill_other.go: built only for other systems or tags
          cmd/carlos-media/harden_other.go: built only for other systems or tags
          cmd/console/fleetsocket_other.go: built only for other systems or tags
          cmd/console/servelock_windows.go: built only for other systems or tags
          cmd/moveprobe/detach_windows.go: built only for other systems or tags
          cmd/rootfswitness/mmap_other.go: built only for other systems or tags
          devbox_acl_other.go: built only for other systems or tags
          devbox_envfile_darwin_test.go: built only for other systems or tags
          devbox_envfile_other.go: built only for other systems or tags
          domains_transfer_signals_other.go: built only for other systems or tags
          interactive_term_darwin.go: built only for other systems or tags
          interactive_term_other.go: built only for other systems or tags
          internal/activator/claimprocess_root_other.go: built only for other systems or tags
          internal/activator/escrow_stamp_other.go: built only for other systems or tags
          internal/activator/fleetreserve_other.go: built only for other systems or tags
          internal/activator/harecord_other.go: built only for other systems or tags
          internal/activator/ownenv_other.go: built only for other systems or tags
          internal/activator/pty_other.go: built only for other systems or tags
          internal/activator/race_on_test.go: built only for other systems or tags
          internal/activator/rolelaunch_other.go: built only for other systems or tags
          internal/assetcache/statfs_other.go: built only for other systems or tags
          internal/boxself/io_other.go: built only for other systems or tags
          internal/cgroup/cleanup_other.go: built only for other systems or tags
          internal/cgroup/cleanup_other_test.go: built only for other systems or tags
          internal/cgroup/hostprocs_other.go: built only for other systems or tags
          internal/cgroup/recreate_other.go: built only for other systems or tags
          internal/cgroup/role_other.go: built only for other systems or tags
          internal/cgroup/shim_other.go: built only for other systems or tags
          internal/cgroup/strict_other.go: built only for other systems or tags
          internal/cgroup/verify_other.go: built only for other systems or tags
          internal/console/claim_sql_identity_other.go: built only for other systems or tags
          internal/console/geoipverify_other.go: built only for other systems or tags
          internal/console/hostreports_process_other.go: built only for other systems or tags
          internal/console/replicaview_other.go: built only for other systems or tags
          internal/console/restore_sim_nice_other_test.go: built only for other systems or tags
          internal/console/scalecost_other_test.go: built only for other systems or tags
          internal/console/seedscratch_windows.go: built only for other systems or tags
          internal/dbreads/worker_other.go: built only for other systems or tags
          internal/demobuild/security_other.go: built only for other systems or tags
          internal/democlaim/source_other.go: built only for other systems or tags
          internal/devbox/peer_darwin.go: built only for other systems or tags
          internal/devbox/peer_darwin_test.go: built only for other systems or tags
          internal/devbox/peer_other.go: built only for other systems or tags
          internal/devbox/socketcheck_other.go: built only for other systems or tags
          internal/edge/devboxpeer_other.go: built only for other systems or tags
          internal/edge/hairpin_other.go: built only for other systems or tags
          internal/edge/heldbudget_other.go: built only for other systems or tags
          internal/edge/purge_listen_unix.go: built only for other systems or tags
          internal/edge/purge_listen_windows.go: built only for other systems or tags
          internal/edge/race_on_test.go: built only for other systems or tags
          internal/edge/replicaconsole_owner_other.go: built only for other systems or tags
          internal/edge/replicaconsole_peer_other.go: built only for other systems or tags
          internal/edge/replicaconsole_socket_other_test.go: built only for other systems or tags
          internal/edge/static_artifact_other.go: built only for other systems or tags
          internal/edge/static_recordlock_other.go: built only for other systems or tags
          internal/edge/static_sweep_other.go: built only for other systems or tags
          internal/execsandbox/cleanup_other.go: built only for other systems or tags
          internal/execsandbox/file_other.go: built only for other systems or tags
          internal/execsandbox/oci_other.go: built only for other systems or tags
          internal/fileacl/fileacl_darwin.go: built only for other systems or tags
          internal/fileacl/fileacl_darwin_amd64.s: built only for other systems or tags
          internal/fileacl/fileacl_darwin_arm64.s: built only for other systems or tags
          internal/fileacl/fileacl_darwin_test.go: built only for other systems or tags
          internal/grouproll/state_other.go: built only for other systems or tags
          internal/grouprollaws/pty_darwin.go: built only for other systems or tags
          internal/grouprollaws/pty_other.go: built only for other systems or tags
          internal/hairpin/native_other.go: built only for other systems or tags
          internal/host/applylock_other_test.go: built only for other systems or tags
          internal/host/bootstrapfs_other.go: built only for other systems or tags
          internal/host/boxroles_config_other.go: built only for other systems or tags
          internal/host/claimfilesseed_delegation_other.go: built only for other systems or tags
          internal/host/claimfilesseed_transport_other.go: built only for other systems or tags
          internal/host/claimjournal_containment_other.go: built only for other systems or tags
          internal/host/claimjournal_migration_other.go: built only for other systems or tags
          internal/host/claimlaunch_kernel_other.go: built only for other systems or tags
          internal/host/claimlaunch_rev2_other_test.go: built only for other systems or tags
          internal/host/claimproduction_other.go: built only for other systems or tags
          internal/host/claimready_other.go: built only for other systems or tags
          internal/host/claimroleassembly_other.go: built only for other systems or tags
          internal/host/claimservingartifact_other.go: built only for other systems or tags
          internal/host/claimservinghandover_reboot_other.go: built only for other systems or tags
          internal/host/claimservinghandover_reboot_other_test.go: built only for other systems or tags
          internal/host/claimservingpark_other.go: built only for other systems or tags
          internal/host/claimstate_other.go: built only for other systems or tags
          internal/host/claimstop_kernel_other.go: built only for other systems or tags
          internal/host/claimtoken_inventory_other.go: built only for other systems or tags
          internal/host/claimunit_dropin_other.go: built only for other systems or tags
          internal/host/claimunit_files_other.go: built only for other systems or tags
          internal/host/claimunit_migrate_other.go: built only for other systems or tags
          internal/host/claimunit_ready_other.go: built only for other systems or tags
          internal/host/claimunit_socket_migration_other.go: built only for other systems or tags
          internal/host/consolefleet_owner_other.go: built only for other systems or tags
          internal/host/dbreads_other.go: built only for other systems or tags
          internal/host/egress_rail_other.go: built only for other systems or tags
          internal/host/fileowner_other.go: built only for other systems or tags
          internal/host/flock_windows.go: built only for other systems or tags
          internal/host/group_config_other.go: built only for other systems or tags
          internal/host/group_maintenance_other.go: built only for other systems or tags
          internal/host/group_maintenance_verbs_other.go: built only for other systems or tags
          internal/host/group_receipt_other.go: built only for other systems or tags
          internal/host/hadrain_call_other.go: built only for other systems or tags
          internal/host/hadrain_socket_other.go: built only for other systems or tags
          internal/host/hadrainfence_other.go: built only for other systems or tags
          internal/host/headroom_other.go: built only for other systems or tags
          internal/host/installchannel_other.go: built only for other systems or tags
          internal/host/metrics_nested_other.go: built only for other systems or tags
          internal/host/movesfloor_other.go: built only for other systems or tags
          internal/host/movesfloorgate_other.go: built only for other systems or tags
          internal/host/movesheldrelease_other.go: built only for other systems or tags
          internal/host/movesmeasure_other.go: built only for other systems or tags
          internal/host/offcloudcredentials_other.go: built only for other systems or tags
          internal/host/registrychild_exec_other.go: built only for other systems or tags
          internal/host/registrychild_other.go: built only for other systems or tags
          internal/host/registryowner_chown_other.go: built only for other systems or tags
          internal/host/registryowner_descriptor_unix.go: built only for other systems or tags
          internal/host/replicahealth_other.go: built only for other systems or tags
          internal/host/rootgeneration_census_other.go: built only for other systems or tags
          internal/host/rootgeneration_kernel_other.go: built only for other systems or tags
          internal/host/rootgeneration_payload_other.go: built only for other systems or tags
          internal/host/rootgeneration_retired_other.go: built only for other systems or tags
          internal/host/rootmigration_production_other.go: built only for other systems or tags
          internal/host/runscset_other.go: built only for other systems or tags
          internal/host/sandboxenv_other.go: built only for other systems or tags
          internal/host/statfs_windows.go: built only for other systems or tags
          internal/host/systemapply_other.go: built only for other systems or tags
          internal/hostbox/census_vendor_other.go: built only for other systems or tags
          internal/hostbox/inventory_identity_other.go: built only for other systems or tags
          internal/hostbox/journalmigration_other.go: built only for other systems or tags
          internal/hostbox/journalnamespace_other.go: built only for other systems or tags
          internal/hostbox/journaltrust_other.go: built only for other systems or tags
          internal/hostbox/migration_census_other.go: built only for other systems or tags
          internal/hostbox/typedpark_other.go: built only for other systems or tags
          internal/hostenv/group_other.go: built only for other systems or tags
          internal/hostenv/write_other.go: built only for other systems or tags
          internal/hostenv/write_other_test.go: built only for other systems or tags
          internal/hostexec/clock_other.go: built only for other systems or tags
          internal/hostexec/clock_other_test.go: built only for other systems or tags
          internal/hostexec/local_other.go: built only for other systems or tags
          internal/hostexec/pending_other.go: built only for other systems or tags
          internal/hostexec/probe_other.go: built only for other systems or tags
          internal/hostexec/rootprocess_other.go: built only for other systems or tags
          internal/hostfiles/dir_other.go: built only for other systems or tags
          internal/hostfiles/refuse_other.go: built only for other systems or tags
          internal/hostfiles/watch_other.go: built only for other systems or tags
          internal/hostfloor/controllers_other.go: built only for other systems or tags
          internal/hostfloor/image_other.go: built only for other systems or tags
          internal/hostguard/flock_other.go: built only for other systems or tags
          internal/hostguard/flock_other_test.go: built only for other systems or tags
          internal/hostguard/record_other.go: built only for other systems or tags
          internal/instancectl/claimexec_other.go: built only for other systems or tags
          internal/instancectl/claimexec_socket_other.go: built only for other systems or tags
          internal/instancectl/claimlaunch_snapshot_other.go: built only for other systems or tags
          internal/instancectl/claimnetwork_other.go: built only for other systems or tags
          internal/instancectl/demo_snapshot_other.go: built only for other systems or tags
          internal/instancectl/egress_cgroup_other.go: built only for other systems or tags
          internal/instancectl/egress_dropin_other.go: built only for other systems or tags
          internal/instancectl/fleetsize_other.go: built only for other systems or tags
          internal/instancectl/gvisorprobe_other.go: built only for other systems or tags
          internal/instancectl/peer_other.go: built only for other systems or tags
          internal/instancectl/peer_tuple_other.go: built only for other systems or tags
          internal/instancectl/rootfs_identity_other.go: built only for other systems or tags
          internal/instanceexec/claimexec_other.go: built only for other systems or tags
          internal/instanceexec/exec_rootfs_other.go: built only for other systems or tags
          internal/instanceexec/probe_gvisor_other.go: built only for other systems or tags
          internal/instanceexec/probe_hardening_other.go: built only for other systems or tags
          internal/instanceexec/probe_other.go: built only for other systems or tags
          internal/instanceexec/probe_rootfs_other.go: built only for other systems or tags
          internal/instanceexec/sandbox_other.go: built only for other systems or tags
          internal/instanceexec/scope_other.go: built only for other systems or tags
          internal/instanceexec/stop_other.go: built only for other systems or tags
          internal/instanceexec/tty_other.go: built only for other systems or tags
          internal/instancefs/instancefs_other.go: built only for other systems or tags
          internal/launchd/activate_darwin.go: built only for other systems or tags
          internal/launchd/activate_darwin_amd64.s: built only for other systems or tags
          internal/launchd/activate_darwin_arm64.s: built only for other systems or tags
          internal/launchd/activate_darwin_test.go: built only for other systems or tags
          internal/layout/journal_other.go: built only for other systems or tags
          internal/layout/links_other.go: built only for other systems or tags
          internal/mailer/keys_other.go: built only for other systems or tags
          internal/maintenanceexec/run_other.go: built only for other systems or tags
          internal/mediahandler/collect_other.go: built only for other systems or tags
          internal/mediahandler/procs_other.go: built only for other systems or tags
          internal/medialocal/runner_other.go: built only for other systems or tags
          internal/moves/archive/open_other.go: built only for other systems or tags
          internal/moves/archive/sync_other.go: built only for other systems or tags
          internal/ops/flock_windows.go: built only for other systems or tags
          internal/park/local_other.go: built only for other systems or tags
          internal/privatefile/io_other.go: built only for other systems or tags
          internal/proxyproto/peek_other.go: built only for other systems or tags
          internal/relay/race_on_test.go: built only for other systems or tags
          internal/release/consumedfence_other.go: built only for other systems or tags
          internal/release/digestcache_other.go: built only for other systems or tags
          internal/rootaws/credentials_other.go: built only for other systems or tags
          internal/rootaws/open_darwin.go: built only for other systems or tags
          internal/rootfsimage/dir_other.go: built only for other systems or tags
          internal/rootstate/authoritydir_other.go: built only for other systems or tags
          internal/rootstate/authorityfile_other.go: built only for other systems or tags
          internal/rootstate/file_other.go: built only for other systems or tags
          internal/rootstate/link_other.go: built only for other systems or tags
          internal/rootstate/persistent_other.go: built only for other systems or tags
          internal/rootstate/state_other.go: built only for other systems or tags
          internal/safefile/file_other.go: built only for other systems or tags
          internal/safefile/reap_other.go: built only for other systems or tags
          internal/stopevidence/fds_other.go: built only for other systems or tags
          internal/stopevidence/fds_other_test.go: built only for other systems or tags
          internal/stopevidence/holders_other.go: built only for other systems or tags
          internal/stopevidence/reconstruct_other.go: built only for other systems or tags
          internal/team/storelock_other.go: built only for other systems or tags
          internal/team/storelock_windows.go: built only for other systems or tags
          move_offline_run_other.go: built only for other systems or tags
          system_group_other.go: built only for other systems or tags
        
    codehealth_test.go:115: fatal               1094 at  474 sites  log.Fatal*, (*log.Logger).Fatal* and os.Exit in the root package's production files
    codehealth_test.go:115: sleep               1005 at  811 sites  time.Sleep in test files
    codehealth_test.go:115: db-no-context        885 at  703 sites  database calls with no context (dbOpWithoutContext) in production files
    codehealth_test.go:115: host-context         188 at  142 sites  context.Background and context.TODO in internal/host production files
    codehealth_test.go:115: func-lines         18619 at   45 sites  functions over 300 code lines (blank and comment-only lines not counted)
    codehealth_test.go:115: file-lines         30727 at    8 sites  files over 3,000 code lines, counted the same way
    codehealth_test.go:115: release-importers     66 at    1 sites  packages whose production files import internal/release
    codehealth_test.go:119: below the record: file-lines . apimode.go -: 4175 in the code, the record allows 4184 (make code-health-record lowers it)
    codehealth_test.go:119: below the record: file-lines internal/host agent.go -: 3188 in the code, the record allows 3214 (make code-health-record lowers it)
--- PASS: TestCodeHealth (109.32s)
PASS
ok  	github.com/carlosframework/platform/internal/codehealth	110.405s
=== code-health-record ===
go version go1.26.10 linux/arm64
code-health record: comparing with the merge base 67a5b32da13c72d79b256e8b389a3f61e0ee41c2 (main is 67a5b32da13c72d79b256e8b389a3f61e0ee41c2)
=== RUN   TestRecordAgainstBase
    codehealth_test.go:186: accepted: func-lines internal/activator (*Service).doWakeOnce -: 571, up from 570: # raised: step 0.69, the one call that delivers an instance's config before its wake is planned (body in configbeforewake.go); before it, #1290 step 2c
    codehealth_test.go:186: accepted: func-lines internal/host runAgent -: 689, up from 688: # raised: sets the activator's ConfigBeforeWake beside BeforeExec, where every wake hook is set before Start (body in configbeforewake.go); before it, #1290's continuity directory
    codehealth_test.go:186: accepted: file-lines internal/activator activator.go -: 3785, up from 3783: # raised: the Service.ConfigBeforeWake field and doWakeOnce's one call to it (the body lives in configbeforewake.go); before it, #1290 step 2c
--- PASS: TestRecordAgainstBase (0.01s)
PASS
ok  	github.com/carlosframework/platform/internal/codehealth	0.008s
code-health record: no line went up without a reason
=== race ===
go version go1.26.10 linux/arm64
GATE_RACE=1 .amadan/test-gate.sh
=== internal_systemd@0 (13 s, from +15 s)
ok  	github.com/carlosframework/platform/internal/systemd	13.153s
=== internal_rootaws@0 (26 s, from +35 s)
ok  	github.com/carlosframework/platform/internal/rootaws	25.365s
=== internal_activator@0 (270 s, from +113 s)
ok  	github.com/carlosframework/platform/internal/activator	268.074s
=== internal_activator@1 (265 s, from +113 s)
ok  	github.com/carlosframework/platform/internal/activator	263.107s
=== internal_activator@2 (279 s, from +113 s)
ok  	github.com/carlosframework/platform/internal/activator	277.169s
=== internal_activator@3 (425 s, from +113 s)
ok  	github.com/carlosframework/platform/internal/activator	422.826s
=== internal_activator@4 (278 s, from +113 s)
ok  	github.com/carlosframework/platform/internal/activator	276.469s
=== internal_activator@5 (313 s, from +113 s)
ok  	github.com/carlosframework/platform/internal/activator	311.051s
=== internal_activator@6 (324 s, from +113 s)
ok  	github.com/carlosframework/platform/internal/activator	322.398s
=== internal_activator@7 (412 s, from +113 s)
ok  	github.com/carlosframework/platform/internal/activator	410.513s
=== internal_edge@0 (84 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	81.067s
=== internal_edge@1 (146 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	142.566s
=== internal_edge@2 (200 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	196.590s
=== internal_edge@3 (171 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	167.524s
=== internal_edge@4 (156 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	152.579s
=== internal_edge@5 (236 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	232.307s
=== internal_edge@6 (239 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	235.668s
=== internal_edge@7 (234 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	231.042s
=== internal_edge@8 (227 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	223.405s
=== internal_edge@9 (252 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	248.618s
=== internal_edge@10 (221 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	218.091s
=== internal_edge@11 (213 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	209.466s
=== internal_edge@12 (234 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	230.571s
=== internal_edge@13 (268 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	264.327s
=== internal_edge@14 (175 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	171.742s
=== internal_edge@15 (244 s, from +134 s)
ok  	github.com/carlosframework/platform/internal/edge	240.354s
=== internal_host@0 (8 s, from +194 s)
ok  	github.com/carlosframework/platform/internal/host	5.055s
=== internal_host@1 (16 s, from +194 s)
ok  	github.com/carlosframework/platform/internal/host	13.183s
=== lists: internal_edge 133 s, internal_activator 111 s, internal_host 193 s, internal_rootaws 34 s, internal_systemd 14 s
=== cpu: the gate used 7669 cpu-seconds in 538 s, about 14.3 of 32 cores; the machine as a whole was 44% busy
=== gitleaks ===
go version go1.26.10 linux/arm64
go: downloading github.com/zricethezav/gitleaks/v8 v8.30.1
go: downloading github.com/rs/zerolog v1.33.0
go: downloading github.com/spf13/cobra v1.9.1
go: downloading github.com/charmbracelet/lipgloss v0.5.0
go: downloading github.com/gitleaks/go-gitdiff v0.9.1
go: downloading github.com/Masterminds/sprig/v3 v3.3.0
go: downloading github.com/h2non/filetype v1.1.3
go: downloading github.com/mholt/archives v0.1.2
go: downloading github.com/fatih/semgroup v1.2.0
go: downloading github.com/BobuSumisu/aho-corasick v1.0.3
go: downloading golang.org/x/exp v0.0.0-20250218142911-aa4b98e5adaa
go: downloading github.com/spf13/viper v1.19.0
go: downloading github.com/hashicorp/go-version v1.7.0
go: downloading github.com/fsnotify/fsnotify v1.8.0
go: downloading github.com/spf13/afero v1.12.0
go: downloading github.com/hashicorp/hcl v1.0.0
go: downloading github.com/sagikazarmark/slog-shim v0.1.0
go: downloading gopkg.in/ini.v1 v1.67.0
go: downloading gopkg.in/yaml.v3 v3.0.1
go: downloading github.com/magiconair/properties v1.8.9
go: downloading github.com/subosito/gotenv v1.6.0
go: downloading github.com/pelletier/go-toml/v2 v2.2.3
go: downloading github.com/spf13/cast v1.7.1
go: downloading github.com/Masterminds/goutils v1.1.1
go: downloading github.com/spf13/pflag v1.0.6
go: downloading github.com/mitchellh/mapstructure v1.5.0
go: downloading dario.cat/mergo v1.0.1
go: downloading github.com/huandu/xstrings v1.5.0
go: downloading github.com/shopspring/decimal v1.4.0
go: downloading github.com/mitchellh/copystructure v1.2.0
go: downloading golang.org/x/crypto v0.35.0
go: downloading github.com/Masterminds/semver/v3 v3.3.0
go: downloading github.com/mattn/go-colorable v0.1.14
go: downloading golang.org/x/text v0.22.0
go: downloading github.com/mitchellh/reflectwalk v1.0.2
go: downloading golang.org/x/sys v0.30.0
go: downloading github.com/muesli/termenv v0.15.1
go: downloading github.com/muesli/reflow v0.2.1-0.20210115123740-9e1d0d53df68
go: downloading github.com/mattn/go-runewidth v0.0.14
go: downloading github.com/lucasb-eyer/go-colorful v1.2.0
go: downloading golang.org/x/sync v0.11.0
go: downloading github.com/pierrec/lz4/v4 v4.1.21
go: downloading github.com/klauspost/pgzip v1.2.6
go: downloading github.com/klauspost/compress v1.17.11
go: downloading github.com/therootcompany/xz v1.0.1
go: downloading github.com/STARRY-S/zip v0.2.1
go: downloading github.com/andybalholm/brotli v1.1.2-0.20250424173009-453214e765f3
go: downloading github.com/ulikunitz/xz v0.5.12
go: downloading github.com/bodgit/sevenzip v1.6.0
go: downloading github.com/nwaples/rardecode/v2 v2.1.0
go: downloading github.com/dsnet/compress v0.0.2-0.20230904184137-39efe44ab707
go: downloading github.com/minio/minlz v1.0.0
go: downloading github.com/sorairolake/lzip-go v0.3.5
go: downloading github.com/bodgit/plumbing v1.3.0
go: downloading github.com/hashicorp/go-multierror v1.1.1
go: downloading go4.org v0.0.0-20230225012048-214862532bf5
go: downloading github.com/hashicorp/golang-lru/v2 v2.0.7
go: downloading github.com/bodgit/windows v1.0.1
go: downloading github.com/hashicorp/errwrap v1.1.0
go: downloading github.com/rivo/uniseg v0.2.0
go: downloading github.com/aymanbagabas/go-osc52/v2 v2.0.1
self-test: reported source file: a key
self-test: reported source file: a 64-hex key
self-test: reported source file: a census-shaped entry
self-test: reported source file: a key marked gitleaks:allow
self-test: reported source file: a test's fake value outside tests
self-test: reported allowed file: another key beside its allowed value
self-test: reported a tracked file named gitleaks-gate-sentinel.env
self-test: reported 97 near misses of the names notscanned.go lists
self-test: skipped  the 32 files notscanned.go lists
self-test: refused  a notscanned.go entry git does not track
self-test: refused  a config that does not parse
self-test: refused  a config that does not exist
self-test: refused  a missing gitleaks binary
self-test: 6 planted keys reported, 130 tracked files judged, 3 broken setups refused
gitleaks: scanned 11453 tracked files; 32 not scanned, by exact path (scripts/gitleaks-gate/notscanned.go)
gitleaks: clean
diff --git a/docs/superpowers/notes/census-proposal-instance-ready-before-wake.md b/docs/superpowers/notes/census-proposal-instance-ready-before-wake.md
index eb6e1ef24..6eb13dfee 100644
--- a/docs/superpowers/notes/census-proposal-instance-ready-before-wake.md
+++ b/docs/superpowers/notes/census-proposal-instance-ready-before-wake.md
@@ -17,7 +17,7 @@ Recorded dispositions, which each change must still satisfy:
- `internal/activator/activator.go` `type Service`: authority, task B,C,D,F,J4. Basis: rev3=PROPOSED-seed; existing activator lifecycle and due-wake state plus owned seed exclusion and incarnation-keyed diagnostics; normal refusal and preparation ordering remain authoritative; PROPOSED-plans-2-box-limits adds the idleFor hook field, which only narrows idle windows;rev3=census-ruling-plans-4c-box-throttle;basis=gains the maxRunFor hook field beside idleFor (plans 4c). No read added.;rev3=census-ruling-plans-4d-lapse;basis=gains the disabledFor hook field beside maxRunFor (plans 4d). No read added.;rev3=census-ruling-remote-instance-metrics;basis=gains tenancySeq, hostTenants and hostMixed, in-memory fields for Tenancies; no read added;rev3=census-ruling-region-ha-p1a;basis=the agent as carlos: one more field, markers (markerRetry: an atomic running flag and the last log time) for retryOwedMarkers; no read added; merge of origin/main d7ae1d76: main's fields are kept as main has them (census-ruling-remote-instance-metrics: tenancySeq, hostTenants, hostMixed); this branch's change is the same as above;rev3=census-ruling-rootfs-apps-3;basis=rootfs Plan 3 Tasks 7 and 8: new fields for rootfs admission (rootfsArmed, rootfsSwept), the per-host gate ask and refusal memo, and residency state (lister, backoff, start ceiling, cursor, test seam); no read;rev3=census-ruling-rootfs-apps-3-release;basis=rootfs Plan 3 Group R: one new field, releaseOps (host to the in-memory release record, under a.mu); no read;rev3=census-ruling-rootfs-apps-3-workers;basis=rootfs Plan 3 Group W: one new field, leaseNow (a clock seam for a worker start's headroom against the lease deadline, nil is the real clock); no read;rev3=census-ruling-region-ha-p1b2;basis=region HA P1b-2: gains the holder cache and its single-flight state; no read;rev3=census-ruling-managed-fleets-1b;basis=managed fleets 1b (controller ruling after branch review R1, and Paul's R2 ruling): one field, Fleet (activator.FleetWake: the box's fleet state, not on a fleet by default, on a fleet with a known label and a record reader, or on a fleet with an invalid identity), set by the agent before Start and read only by routeCurrentUnderLease. No read in the declaration. Agent, not root.;rev3=census-ruling-rootfs-apps-6;basis=rootfs Plan 6 Task 7a fix round 1: one field, drainBudget (time.Duration), which New copies from residentDrainBudget and a rootfs entry's lease watch reads in its place, so a test's change of the package var never races a watch goroutine; declaration only, reads nothing; merge of origin/main 6f1f6ca6: main's one field, Fleet (activator.FleetWake), is kept as main has it (census-ruling-managed-fleets-1b); this branch's change is the same as above;rev3=census-ruling-region-ha-p1b3a;basis=Add bounded placement peer and diagnostic state and the over-capacity callback; no read in this declaration and no new root authority.;rev3=census-ruling-stateless-replicas-1;basis=Add coordinator, existing-record observation callback and per-host preparation locks; no read in the declaration. Task 3a: Add optional canonical storage-selection and durable deploy-ID callbacks; declaration only, no read or authority in these fields.;rev3=census-ruling-edge-held-streams;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): adds the heldLegs map to actEntry (legs by id, under a.mu) and heldWakeHook (atomic pointer to a callback) and heldLegSeq (atomic counter) to Service. State only, in memory; no read of tenant, app or box-agent-writable input.;rev3=census-ruling-wake-storm-cap;basis=the agent as carlos: one field, wakeSlots (chan struct{}, the wake semaphore made by New from Config.WakeSlots, default 4); declaration only, no read.;rev3=census-ruling-region-ha-p1b3b-t;basis=Add the B2 DutyStore interface field and process-local duty view, suppression and invalidation state. No read added. B2 adds the verified-successor identity callback; no read in the declaration. B3b adds a nonblocking departure-suspicion callback, invoked only after an accepted holder-forward failure and after cache locks release; it cannot authorize a take.;rev3=census-ruling-region-ha-p3a;basis=P3a Task 3: immutable callbacks installed before Start for tenant admission, local start permission, fixed route exemptions and shutdown closure; nil callbacks preserve switch-off behavior; no new reads. Fix R1: add an immutable startup-phase callback for response copy, set before service startup. No new read or execution authority.;rev3=census-ruling-region-ha-g2-fixes;basis=Add in-memory HA loss state and pool withdrawal jobs; no new read.;rev3=census-ruling-region-ha-held-build;basis=region HA held-requests Task 1: one new field, drain (drainSources: two atomic func pointers for this box's and peers' drain state); no read added. region HA held-requests Task 2: one new field, moves (moveTable: per-host move state, hold counts and admission tickets in memory, under mu); no read added;rev3=census-ruling-held-move-speed;basis=the agent as carlos: one new field, moveStreams (per-host in-memory set of edge.StreamEnd for requests in flight, own mutex), for the move's early stream cut; actEntry gains drainRelease (bool, under a.mu), set by DrainStop; declarations only, no read added;rev3=census-ruling-fix-silent-start-kill-861;basis=#861: two fields, wakeFailMu and wakeFailLogged (per-host in-memory note of the last journalled wake failure); declaration only, no read;rev3=census-ruling-w6-ingress-drain;basis=new field TenantStartsClosed func() bool; when it answers true tenantStartRefusal refuses every start, exempt routes included. Wired only by fixedAdmission.bind to the ingress drain's closed flag. Struct field only; no read added.;rev3=census-ruling-stateless-replicas-4-task2;basis=Task 2: one field, replicaPolicies (host to the newest observed replica deploy and this box label, under mu), set only by SetReplicaDeploy; declaration only, no read.;rev3=census-ruling-stateless-replicas-4-task2-fix1;basis=Task 2 fix round 1: one more in-memory field, replicaFailed (host to the permit whose successor failed here, under mu), so that step only proves what it kept; declaration only, no read.;rev3=census-ruling-stateless-replicas-4-task3f;basis=Task 3F fix round 3 (#511 F11): two hook fields, MarkReplicaRelease and ReplicaReleaseMark (the failure book's per-host release mark on this box's disk). No read site.;rev3=census-ruling-stateless-replicas-4-task5;basis=Task 5 first commit (#511 F11): one in-memory field, heldSeen (host to the last held release attempt, error class and when it was met), under the existing wakeFailMu. Declaration only, no read.;rev3=census-ruling-stateless-replicas-4-merge-main;basis=Merge of main 5fac2ff1: both sides changed it. Main (27d3f501) adds the background atomic.Int64 field that tests wait on; this branch keeps its replica fields. Both kept as-is; no read added.;rev3=census-ruling-stateless-replicas-4-final;basis=#511 final wave item 3: adds replicaSwitched, an in-memory map of the permit each set row switched under (host -> permit key, time, resident flag); no read added; #511 micro-fix P1b: adds replicaNoGen, an in-memory map (host -> permit key and when first seen) that is only the bound's clock for a restarted permit holder with no generation; no read added;rev3=census-ruling-stateless-replicas-4-drill1;basis=#511 drill 1 R20 bound (round 1: clock with start and last seen): one in-memory field, releaseConfigWaits (per host, a stateless release's config wait), under mu; no read;rev3=census-ruling-stateless-replicas-4-r28;basis=R28 review round 2 (#511): one field, retiringCopy, an atomic pointer to the edge's in-memory retired-copy check, handed over by edge.New (SetRetiringCopy); no read, no root decision;rev3=census-ruling-g6-fence;basis=G6 F-C Task 3, the agent as carlos: four fields, fenceWatchers (sync.WaitGroup of running write-fence watchers) and three test seams nil in production (fenceWatchStarted, retainDB, wakeReturned). Declaration only, no read.;rev3=census-ruling-fleet-record-labels-m1;basis=fleet record labels R1/R2: actEntry gains checkpoint state (busy while CloseProven runs, unproven, named-once flag for C45), in-memory under a.mu; the worker gains fence pacing apart from crash backoff; Service gains test seams nil in production; declarations only, no read;rev3=census-ruling-race-activator-1249;basis=adds two test-only fields: leaseWork (a WaitGroup counting lease watches and the one-shot stops a short lease starts) and leaseWatchStop (a channel, nil in production, that a test closes to end every lease watch); no read added and production never waits on or closes either;rev3=census-ruling-fleet-restart-wake;basis=Fleet restart wake Task 1: the per-host journal note maps (wakeFailLogged, heldSeen) move into the embedded wakeNotes struct in wakefaillog.go, which adds fenceSeen. In-memory only; no read added.;rev3=census-ruling-stateless-scale-2-fleet-sizes;basis=the agent (carlos-edge.service, user carlos), not root: one embedded field (#892 S2), fleetSizeService (fleetreserve.go), which holds BoxLabel (string, the rollout's own box label, set by armRollout) and fleetReserve (fleetReservations, ready as its zero value; it reads /proc/meminfo through memAvailable only when a fleet-size overlap reserves), the box's in-memory overlap reservation for fleet sizes. Declaration only; no read added
- `internal/appconfig/syncexec.go` `SyncExecWithCallbacks`: legacy, task accepted-legacy. Basis: accepted-legacy;rev3=census-ruling-moves-offline-fixes;basis=route-and-input (J1,J4, main's disposition); the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos), through syncExecSerialized: main's body, with a nested row whose write found no instance directory named and skipped (errInstanceDirAbsent, WhenInstanceDirAbsent) instead of failing the pass, and each in-scope host reported done or not done (WithHostOutcome) once the pass has gone through every route; no new read site;rev3=PROPOSED-s3-change-index;identity=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos);basis=the scoped pass's route filter (WithRouteFilter, syncOptions.kept) is checked in its three route loops, so a route the filter leaves out is out of scope before anything is read for it; three whole-Route sites added, each passing rt to kept; no bucket or file read added;rev3=census-ruling-team-scoped-credentials;basis=team-scoped credentials (#449 §3): checkOptedIn's default-bundle thunk answers no default bundle for an OWNED environment bundle, so its exec_delivery is its own and never inherited; the same bundle reads as before, no read site added;rev3=census-ruling-named-unit-delivery-114;basis=the stale-file notice loop gains the stamped case: os.Stat of ConfigEnvPath(dataDir, rt), the path the exec-addr case already stats, and a notice line; no write, no new path;rev3=census-ruling-design-console-secrets;basis=the <host>.config collision set is built by routeHostSet (shared with the classifier) instead of inline; same rows read, same skip; no read site added
-- `internal/host/agent.go` `runAgent`: authority, task B,C,D,F. Basis: rev3=census-ruling-self-serve-moves-1;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): builds the box's lifetime judge once (newBoxJudge, nil with host claims on) and hands it to the seed placement, the moves and runs workers and every loop it starts; read sites unchanged, offsets moved; B,C,D,F authority retained; self-serve moves 1 Task 8: derives the box's lifetimes switch from the judge once (lifetimes := boxJudge != nil) and hands it to the edges file loop; read sites unchanged, offsets moved;rev3=census-ruling-plans-4d-lapse;basis=arms two more plans hooks from the same snapshot: e.SetPlanDisabledFor(planDisabledFor) beside SetPlanGovernedFor, and svc.SetDisabledFor(planDisabledRoute) beside SetMaxRunFor (plans 4d); the reads live in those units (plans-4d-units decision); read sites unchanged, offsets moved;rev3=census-ruling-rootfs-apps-2;basis=main's body as of the merge of origin/main 9b81d97b (with main's plan rate ceiling, edge request records, regional box names, self-serve moves plan 1, plans 4d-1 lapse and its other later changes under main's own census rulings) plus the rootfs placement wiring in the activator start: an agentRootfs built from eb.NestedOK, CARLOS_DEPLOYMENT_SINGLE_TENANT, CARLOS_POOLS, the claim flag, swapArming's answer, the control client's /ready/rootfs and, on a fleet box whose identity resolved, fleetOwnerCheck over the deploy store main already opens for the fleet label (fleetStore), then arm and armedRootfs.Store; this body reads nothing new itself; the closures it wires read later, at a rootfs wake and each status tick: GET /ready/rootfs over the control socket, NestedOK's checks, and release.FleetOwnerKey for the judged row's own account and this box's fleet from the deploy store;rev3=census-ruling-instance-egress-sizes-328-329;basis=#328 plan 2 Tasks 7 and 11, #329 plan 3 Task 7 and plan 1 Task 7's policy cache: the control client is built once and handed to eb.Control, to the status tick (egressStatus) and to a new egressNudgeLoop goroutine; armSizeSource(svc, "/sys/fs/cgroup") after the activator Service; armPolicyCache() after armChangeIndex; statusLoop takes egressStatus. The reads are those units' own (decision rows); this body reads nothing new: the same five sites, offsets moved, in the agent; B,C,D,F authority retained.;rev3=census-ruling-remote-instance-metrics;basis=builds the metrics loop's owners closure (metricsOwners over the agent's registry, the activator and cgm.Leftover) when an activator exists and hands it to metricsLoop; reads nothing new itself;rev3=census-ruling-edge-asset-cache-3;basis=adds file:Statfs. runAgent keeps its authority (B,C,D,F). The new site is assetcache.Statfs, an exported assetcache.FS interface value (var Statfs FS = statfsFS{}), not a function value and not a call in runAgent: the ready hook passes it to armEdgeAssetCache as the store's filesystem, and armEdgeAssetCache calls its Space method on the configured data directory (dataDir(): $CARLOS_DATA_DIR, else /data), which calls unix.Statfs there (statfsFS.Space, accepted legacy at census-ruling-edge-asset-cache-2). No request-supplied pathname reaches it.;rev3=census-ruling-remote-metrics-nested;basis=main's body (merged origin/main acfa4f80, under main's own census rulings) plus: snapshots the nested layout (snapshotNestedUnits over /sys/fs/cgroup/carlos.slice/carlos-instances.slice) once at start, before the activator, and hands the metrics loop a unitSources struct (stamped units, routeHostNames, that root and the snapshot); reads nothing new itself;rev3=census-ruling-region-ha-p1a;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): wires region HA P1a into the activator: cfg.Record = haRecordFacts(openDeployStore, boxJudge) (the box's lifetime judge this body already builds with newBoxJudge, nil with host claims on; CI fix) and cfg.Self = lease.CurrentSelf; eb.Lifetimes (the process's lifetime index), eb.Registry, eb.StartupSwept (seedSweptAtStart.Load), eb.FilesStore from newProductionFilesStore (now lease.NewFilesStore, rootaws-loaded, a log line on failure) and lease.SetObligationDir(<data>/.ha-owed) (logged on failure; HA acquires then refuse); this body reads nothing new itself, the same five sites; the reads are those units' own (haRecordFacts and lease's SetObligationDir are new rows on this card); merge of origin/main d7ae1d76: main's own later changes to this body are kept as main has them, under main's rulings (census-ruling-remote-instance-metrics: the metricsOwners closure for metricsLoop; census-ruling-edge-asset-cache-3: the +file:Statfs site, assetcache.Statfs handed to the asset ready hook); this branch's change is the same as above;rev3=census-ruling-region-ha-p1b1;basis=region HA P1b-1: builds one termfence.Confirmer (Self from lease.CurrentSelf at each call, EC2 DescribeInstances method only, client from rootaws.LoadDefaultConfig with retries off, built lazily on first use) and sets eb.OwnerTerminated; this body reads nothing new itself, the same six sites;rev3=census-ruling-rootfs-apps-3;basis=rootfs Plan 3 Task 7: the startup Sweep literal hands its answer to startupSwept, which logs as before and, only on a clean sweep, marks rootfs admission swept (MarkRootfsSwept); same Sweep call, no read added;rev3=census-ruling-managed-fleets-1b;basis=managed fleets 1b (controller ruling after branch review R1, and Paul's R2 ruling): sets svc.Fleet = fleetWakeFor(os.Getenv, identity, identErr, fleetStore) from the identity it already resolves once and the deployment store the fleet loops already opened, and logs an ERROR naming the identity error when the box is on a fleet with an invalid identity. fleetWakeFor reads CARLOS_REGION and CARLOS_FLEET from the same environment. Read sites unchanged (6). Agent, not root; a platform box is unchanged.;rev3=census-ruling-rootfs-apps-6;basis=rootfs Plan 6 Task 12: one call more beside armRunsPass, armInteractivePass(svc, reg, rolloutSink, boxJudge), in the same activator Configure hook, handing it the same box judge; fix round 1 (Astra P2, shutdown): after svc.Shutdown(ctx), shutdownInteractive(ctx) ends and joins every interactive session under the same shutdown budget; the worker's own reads are its units' (interactive.go); this body reads nothing new, the same six sites; merge of origin/main 6f1f6ca6: main's svc.Fleet = fleetWakeFor(...) and its invalid-identity ERROR line are kept as main has them (census-ruling-managed-fleets-1b); this branch's change is the same as above; read sites unchanged (6);rev3=census-ruling-fix-set-aside-exdev;basis=set-aside EXDEV fix: one field more on the agent ExecBackend literal, RawInstanceDir: layout.RawInstanceDir (a pure path join: <dataDir>/.instances/<InstanceID(host)>), so the start rule set-aside moves a copy out through the raw directory instead of through the nosymfollow bind; this body reads nothing new, the same six sites;rev3=census-ruling-durability-3a-escrow;basis=durability 3a Task 3: one more assignment beside eb.FilesStore: eb.EscrowKey = haEscrowKey(os.Getenv("CARLOS_SECRETS_KEY")), the agent's own environment parsed by appconfig.ParsePrivateKey as the moves pass parses it (unset or unparseable: a log line and nil, and HA publication refuses on the box). No path is opened or read, no read site added; the same six sites, offsets moved; B,C,D,F authority retained. Durability 3a Task 4: one more goroutine beside configSyncLoop: go escrowLoop(agentCtx, reg, svc), the escrow sweep every 30 s over the same registry and Service. This body reads nothing new itself; the same six sites, offsets moved; B,C,D,F authority retained. Durability 3a Task 5: one more call beside eb.EscrowKey: wireRawSecretPages(eb, PageOperator, metricsBoxLabel(os.Getenv, readMachineID())), which sets eb.OnRawSecret to page an operator (alerting.Page through PageOperator, LevelIncident) on its own goroutine with a 20 s timeout; metricsBoxLabel and readMachineID are the reads this body already makes for the moves refusal log; no new read site; the same six sites, offsets moved; B,C,D,F authority retained. Merge of origin/main 90c4d3aa: main's own later changes to this body are kept as main has them, under main's rulings; this branch's change is the same as above. Merge of origin/main 00bf5b8c (fleet set-aside EXDEV fix): main's change to this body is kept as main has it, under its own census ruling; this branch's change is unchanged.;rev3=census-ruling-probe-burst-limit;basis=two more sink wirings beside setAnalyticsSink: setProtectionSink(e.SetProtectionRecordOnly) and setAssetOwnersSource(e.AssetOwners), function values the telemetry pass calls; this body reads nothing new, the same six sites; authority B,C,D,F retained; no new root read or write kind;rev3=census-ruling-region-ha-p1b3a;basis=Arm HA placement exactly once on the existing Service before activatorStart and edges publication, wiring AwakeApps and the PageOperator callback; existing six read sites unchanged, no new root authority.;rev3=census-ruling-stateless-replicas-1;basis=Final review I3: start the concrete coordinator's renewal worker with agent setup; existing closeReplicaCoordinator shutdown cancels and joins it before release. No new read sites or credentials. Merge origin/main c59715e7: retain main's armHAPlacement(svc, PageOperator) wiring beside the existing activator setup; stateless coordinator and shutdown wiring remain. Same read sites; no new root read or credential.;rev3=census-ruling-edge-held-streams;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): in the edge-ready callback, calls act.SetHeldWakeHook(e.HeldWake) when act is non-nil (installing the non-blocking wake callback) and stores e.HeldStreamsForStatus in heldStreamsSource. Wiring of in-memory callbacks only; no read added.;rev3=census-ruling-region-ha-p1b3b-t;basis=Wire Service.SetDutyView to the live edge DutySnapshot in the ready callback. No new read; no new loop or cloud operation. B2 wires the registry as the persistent DutyStore before service startup; no new cloud or filesystem path. B3b: arm one journal-backed termination consumer before service startup using agentCtx and the shared confirmer; expose edge tick and join at edge shutdown. No new direct read sites.;rev3=census-ruling-agent-start-demo-1;basis=Passes the existing registry, data store and hibernation prefix into the demo worker, and the existing instance-control client into the demo before-exec hook. No alternate data store or polling loop. Merge resolution against origin/main 9bd45488 retains main's HA departure controller, lifecycle and duty wiring alongside the demo data store and worker; no read site added by the resolution.;rev3=census-ruling-region-ha-p3a;basis=P3a Task 3: install closed fixed admission before every launch source, bind activator/backend and edge, wire the real termination Started lifecycle and role reader after the change index; close before cancellation/child shutdown. No new external reads or cloud authority. Fix R1: move bind/lifecycle/edge-option wiring into wireAgentAdmission and worker listing into runWorkerBootPassAfterAdmission. Worker boot waits for admission before listing then uses unchanged bounded wakes and per-host serialization; whole Route read moves to the helper. No new storage, cloud, or root execution authority. Preserve merged main's agent wiring and census basis; the branch removes one whole Route use by moving worker iteration to the helper, with no added read kind.;rev3=census-ruling-stateless-replicas-2;basis=Slice 3b: arms a fleet-only worker using the existing registry, activator, backend and authenticated console transport. Owned worker stops and joins at shutdown. No new bucket reader. merge of origin/main 9b8b2c50: retain HA duty/departure lifecycle, wake-slot and existing agent wiring alongside the replica placement worker; no new read introduced by resolution. merge of origin/main 6be08467: Retain main demo configuration, admission, build and expiry wiring alongside the replica worker; merge-only body change, no additional read. merge of origin/main 7920cccf: Retain main box-role/group admission wiring and boot publication beside the owned replica worker and shutdown; main moves the boot registry List into runWorkerBootPassAfterAdmission, removing its inline whole Route site. No new read introduced by conflict resolution.;rev3=census-ruling-stateless-replicas-3;basis=Task 1 fix round 1 M3: retain the private snapshot source and cancel/join ownership, but use the replica-health-specific retry loop. It logs its first failure only and retains the existing exponential backoff capped at 30 seconds; unsupported builds return nil. Existing five direct read sites unchanged; no new credentials, bucket reader or app lifecycle action. Fix round 1 Q20: publish Edge.ReplicaSnapshots as a separate in-memory status source, leaving the tenant-visible Upstreams source unchanged. No new external reader or authority.;rev3=census-ruling-region-ha-p3b;basis=Load root-written group marker/configuration, configure signed boot binding and agent receipt completer, wire cancellable admission into departure work and expose cached GroupReaderSnapshot. New indirect boot reads use protected root files; agent-owned receipt controls duplicate initial completion only, never root restart permission. Same five direct sites. Merge 45cebde4 retains the replica health socket lifecycle and setReplicaSource beside GroupReaderSnapshot; no extra read beyond main.;rev3=census-ruling-agent-start-demo-2;basis=agent.go:309-329 opens demo-traffic.db beside the operator-configured registry when a demo domain exists, closes it at shutdown and wires drain-before-purge; :1010-1019 shares the worker and write gate; :1164-1177 installs the fleet identity and closed-until-worker serving callback. One added whole Route pass; the new indirect filesystem/SQL reads are claimed in openDemoTraffic and worker/store units. No request chooses the database pathname.;rev3=census-ruling-region-ha-p1b3b-s;basis=Wire the service duty view to authoritative cached sidecar manifest placement in LifetimeIndex and the edge sidecar projection; missing policy denies duty. Existing instance duty wiring remains.;rev3=census-ruling-region-ha-g2-t3;basis=T3a: wire eb.Page = PageOperator beside OwnerTerminated before departures arm, so suspect-holder pages work if departure setup fails; no new read; existing nine sites and authority unchanged; pages through the existing sink. T3b: publish the same backend through an atomic pointer for the metrics observer, and clear it on return; no new external read or authority.;rev3=census-ruling-agent-start-demo-3;basis=Wire the claim activator and root snapshot client into the demo worker; pass moved readiness to status reporting. Census read-site delta: unchanged (9).;rev3=census-ruling-region-ha-g2-fixes;basis=Wire local pool evidence, live withdrawal activator, startup ingress scan and alias publication, and edge lookup; no new direct sites; new indirect record/claim reads use existing store/judge paths described in ingress helpers.;rev3=census-ruling-region-ha-g2r-fixes;basis=W3: starts the existing record-view backstop loop with a departure-inventory listener (non-blocking, coalesced signal) even without an armed RecordView; it requests the existing full pass (backstopFullDue) there. Same nine read sites; no new read or authority.;rev3=census-ruling-region-ha-graceful-terminate-t2;basis=Derive one signal-time deadline with a 90-second budget; cap departure stop and startup/seed/service shutdown joins by it. No read added.;rev3=census-ruling-static-sweep-periodic;basis=in the edge-ready callback, publishes e.LargestStaticTree in staticTreeSource for the disk alert line (diskAlertFrac in the metrics loop); in-memory wiring only, no read added; read sites unchanged (9);rev3=census-ruling-edge-page-cache-1;basis=wires the exec backend's CurrentInputs into the edge cache (wireCurrentInputs) and, in the ready hook after armEdgeAssetCache (whose returned store it now keeps), calls armEdgePageCache, which does nothing unless CARLOS_PAGE_CACHE=1; read sites unchanged (9); no read added;rev3=census-ruling-gvisor-demos;basis=Capture sandbox resolution and refusal once; log errors once; gate route admission and BeforeExec before process launch. No new root read. Task 5: pass the once-captured sandbox effective mode/config error into ExecBackend, UnitBackend and the immutable Client expectation. Same startup environment/registry reads; swapArming declines gVisor before placement. Task 8: arm read-only status projection with the existing Client.SandboxStatus callback. Agent status now queries the existing root /ready endpoint; no new root authority or guest-file input. Merge2 e8a1ddde: retain main wireCurrentInputs and armEdgePageCache through the existing asset-store ready hook alongside branch once-captured sandbox mode, wake gates and root status wiring. No new direct read; main page-cache helpers retain their own census overlays.;rev3=census-ruling-region-ha-held-build;basis=wires the drain state: svc.SetDrainingSource(boxDrain.IsDraining), svc.SetPeerDrainView(e.PeerDraining), e.SetPeerDrainedHook(svc.DropHoldersNaming); in-memory only; no read added; region HA held-requests Task 5: on group members, starts the drain driver over the activator, the edge and boxDrain, and serves its root-only drain socket; no read added beyond the socket's own Branch review r1: the drain state follows the root start fence on group members (the fence reader is the existing fenceLocation.read, a root-owned fixed path); e.SetPeerUndrainedHook(svc.AllowHoldersNaming) beside the drained hook (memory only); the drain socket serves only the agent's own user. No read added.;rev3=census-ruling-security-review-mitigations;basis=Wire the cached operator flat-layout choice into the exec backend's new-resident refusal; no read source added, existing authority retained.;rev3=census-ruling-w6-ingress-drain;basis=agent (user carlos), not root. Builds the ingress drain (newIngressDrain) with arming read at ask time from os.Getenv (CARLOS_REGION_HA, CARLOS_INGRESS_TARGET_GROUPS, both from the root-owned host.env), the fixed admission and lease.CurrentSelf (existing IMDS identity); its reader is awstg.Load, the box role's credentials calling ELB DescribeTargetHealth/DescribeTargetGroupAttributes (new AWS reads, by the agent). Wires admission.closeStartsForIngressDrain, the lbhealth drain condition, ingress.setEdge, and ingress.shutdownStarted in WithShutdownStarted. The drain socket (/run/carlos/.ha-drain/drain.sock, agent-user only, existing) is now also served on a fixed box with the drain configured (was group members only), routing /v1/ingress/* to the ingress drain and the group drain verbs to 404 there. armHADepartures now takes fixtureDepartureGetenv() and MakeQueue fixtureDepartureQueue(), which in a production (non-rootrunner) build are os.Getenv and nil, as before. Read sites unchanged (9).;rev3=census-ruling-stateless-replicas-4-task1;basis=Arms the fleet-only replica swap worker next to the placement worker: same console URL and fleet token as the existing replicaCoordinatorAPI, the existing activator Service; stops and joins at shutdown. No new read site, credential or bucket reader.;rev3=census-ruling-stateless-replicas-4-task2;basis=Task 2: sets deployWorker.step to the rollout scheduler answer for the record permit (replicaStepOf over armedRollout), an in-memory callback; no read site, credential or bucket reader added.;rev3=census-ruling-stateless-replicas-4-task2-fix2;basis=Task 2 fix round 2: the swap worker step is armedReplicaStep, the same lazy scheduler lookup as before as a named function; no read site added.;rev3=census-ruling-stateless-replicas-4-merge-main;basis=Merge of main 5fac2ff1: both sides changed it. Main (01d6ca78, linked-deployments-slice1) starts linkLoop beside tunnelLoop; this branch keeps its replica coordinator wiring. Both kept as-is; no read added.;rev3=census-ruling-stateless-replicas-4-final;basis=#511 final wave item 2: wires the swap worker's drive (armedReplicaDrive, the armed rollout manager's DriveReplicaRelease); no read added;rev3=census-ruling-stateless-replicas-4-merge-main2;basis=Merge of main af871da0 (v0.34.49): both sides changed it. Main (178dcfe5, member-backups-2a) moves the inline duty-view closure into armDutyView/dutyView and starts verifyAssignLoop; its sites drop by registry:Host and whole:Route x2 as main recorded them. This branch keeps its replica coordinator, swap worker and drive wiring. Both kept as-is; no read added.;rev3=census-ruling-stateless-replicas-4-drill3;basis=drill 3 R24: makes one in-memory channel, closes it (once) inside the edge's existing shutdown-started callback after ingress.shutdownStarted, and passes it to tunnelLoop, which drains only a fleet channel name; no read added, same six sites; touches no admission, lease, ingress drain, listener or file; the agent process, no root decision;rev3=census-ruling-edge-ppv2;basis=Agent (uid carlos), not root. memwatchLoop now gets edgeProxyCounters(&demoEdge) (in-process counters, no read). The drain socket's driver is newAgentDrainSocket(ingress, e, os.Getenv), which attaches the edge trust handler only when CARLOS_INGRESS_PROXY_SOURCES in the agent's environment (from the root-owned host.env) parses to a non-empty list; the socket is served when drainSocketServed: a group member or a configured ingress drain (both as before), or a box armed for PROXY protocol (new). The socket's path and agent-user-only permissions are unchanged. Read sites unchanged (6).;rev3=census-ruling-same-box-edge-fence;basis=Agent (uid carlos), not root. One added line: armEdgeFenceStatus(ctl.EdgeFence), beside the existing armExecSandboxStatus, so the layout report can ask root's /ready for the edge fence state over the control socket client the agent already holds. No read added.;rev3=census-ruling-platform-mail-submission;basis=Task 4: sets eb.Mail = mailsubmit.SocketForwarder{} on every box, and eb.MailSwitch to a mailSwitchCache's On that opens the deploy store itself through openDeployStore, retried at most once a minute with an error line until it opens (review round 1, Task 4 P3), armed for the serial-move refresh (armedMailSwitch). Task 6: also sets the ExecBackend's ManifestOf, the same staged-manifest read as TierOf (rt.App and RouteAccount(rt), hence +registry:App and +whole:Route), for the spawn-time check of decision 10, which logs and emits an event and never refuses. Agent, not root. Fable final P2-2: eb.MailSwitch is the cache's State (three-valued: on, off, unknown) in place of On; an unreadable switch is unknown, never off. No read added.;rev3=census-ruling-fleet-drain-followups;basis=P3 (#1008 T9): one call after armChangeIndex, requestBootFullPass(v, &backstopFullDue), which stores true in the existing in-memory backstopFullDue flag only when no record view is armed, so the fast loop runs its existing full pass on its first tick instead of instancesLoop a minute later; armed boxes unchanged. No read added; read sites unchanged (8); agent, not root.;rev3=census-ruling-fleet-first-reconcile-speed;basis=Startup timing log lines only: runDuties builds a step logger (newStartupLog, which reads the in-memory agent start time) and logs one line after the wait on the activator startup latch and after each existing duty before go fastConvergeLoop. One newStartupLog().at line in the edge ready hook before go tunnelLoop. No read added; read sites unchanged (8). Agent, not root.;rev3=census-ruling-ha-1192;basis=sets the group drain driver's departed hook to armedPeerDeparted (the armed departure controller's PeerDeparted: local registry identity + departure journal); no new read;rev3=census-ruling-replica-wake-gap-r3;basis=Calls lease.SetContinuityDir(<data dir>/.continuity) beside the existing obligation store: the agent's own 0700 directory for clean records, outside every instance tree (#1290 round 3). No new read; failure is logged and every start then takes a full image.;rev3=census-ruling-fleet-restart-wake;basis=Fleet restart wake Task 2: cfg.ReplicaRecord = replicaRecordFacts(boxLifetimes, cfg.Record): hands the existing judged record read (haRecordFacts over openDeployStore and boxJudge) as the live read on a lifetime index miss. No read site added here; agent, not root.;rev3=census-ruling-alias-publish-precert-1293;basis=starts edgesFileLoop with one more argument, edgeAcmeDir(os.Getenv, peekAcmeCache(args)): the agent's own -acme-cache flag (already parsed for domainsLoop) or $CARLOS_DATA_DIR/acme; a string computed from the operator's command line and environment, no read. Same 8 read sites.
+- `internal/host/agent.go` `runAgent`: authority, task B,C,D,F. Basis: rev3=census-ruling-self-serve-moves-1;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): builds the box's lifetime judge once (newBoxJudge, nil with host claims on) and hands it to the seed placement, the moves and runs workers and every loop it starts; read sites unchanged, offsets moved; B,C,D,F authority retained; self-serve moves 1 Task 8: derives the box's lifetimes switch from the judge once (lifetimes := boxJudge != nil) and hands it to the edges file loop; read sites unchanged, offsets moved;rev3=census-ruling-plans-4d-lapse;basis=arms two more plans hooks from the same snapshot: e.SetPlanDisabledFor(planDisabledFor) beside SetPlanGovernedFor, and svc.SetDisabledFor(planDisabledRoute) beside SetMaxRunFor (plans 4d); the reads live in those units (plans-4d-units decision); read sites unchanged, offsets moved;rev3=census-ruling-rootfs-apps-2;basis=main's body as of the merge of origin/main 9b81d97b (with main's plan rate ceiling, edge request records, regional box names, self-serve moves plan 1, plans 4d-1 lapse and its other later changes under main's own census rulings) plus the rootfs placement wiring in the activator start: an agentRootfs built from eb.NestedOK, CARLOS_DEPLOYMENT_SINGLE_TENANT, CARLOS_POOLS, the claim flag, swapArming's answer, the control client's /ready/rootfs and, on a fleet box whose identity resolved, fleetOwnerCheck over the deploy store main already opens for the fleet label (fleetStore), then arm and armedRootfs.Store; this body reads nothing new itself; the closures it wires read later, at a rootfs wake and each status tick: GET /ready/rootfs over the control socket, NestedOK's checks, and release.FleetOwnerKey for the judged row's own account and this box's fleet from the deploy store;rev3=census-ruling-instance-egress-sizes-328-329;basis=#328 plan 2 Tasks 7 and 11, #329 plan 3 Task 7 and plan 1 Task 7's policy cache: the control client is built once and handed to eb.Control, to the status tick (egressStatus) and to a new egressNudgeLoop goroutine; armSizeSource(svc, "/sys/fs/cgroup") after the activator Service; armPolicyCache() after armChangeIndex; statusLoop takes egressStatus. The reads are those units' own (decision rows); this body reads nothing new: the same five sites, offsets moved, in the agent; B,C,D,F authority retained.;rev3=census-ruling-remote-instance-metrics;basis=builds the metrics loop's owners closure (metricsOwners over the agent's registry, the activator and cgm.Leftover) when an activator exists and hands it to metricsLoop; reads nothing new itself;rev3=census-ruling-edge-asset-cache-3;basis=adds file:Statfs. runAgent keeps its authority (B,C,D,F). The new site is assetcache.Statfs, an exported assetcache.FS interface value (var Statfs FS = statfsFS{}), not a function value and not a call in runAgent: the ready hook passes it to armEdgeAssetCache as the store's filesystem, and armEdgeAssetCache calls its Space method on the configured data directory (dataDir(): $CARLOS_DATA_DIR, else /data), which calls unix.Statfs there (statfsFS.Space, accepted legacy at census-ruling-edge-asset-cache-2). No request-supplied pathname reaches it.;rev3=census-ruling-remote-metrics-nested;basis=main's body (merged origin/main acfa4f80, under main's own census rulings) plus: snapshots the nested layout (snapshotNestedUnits over /sys/fs/cgroup/carlos.slice/carlos-instances.slice) once at start, before the activator, and hands the metrics loop a unitSources struct (stamped units, routeHostNames, that root and the snapshot); reads nothing new itself;rev3=census-ruling-region-ha-p1a;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): wires region HA P1a into the activator: cfg.Record = haRecordFacts(openDeployStore, boxJudge) (the box's lifetime judge this body already builds with newBoxJudge, nil with host claims on; CI fix) and cfg.Self = lease.CurrentSelf; eb.Lifetimes (the process's lifetime index), eb.Registry, eb.StartupSwept (seedSweptAtStart.Load), eb.FilesStore from newProductionFilesStore (now lease.NewFilesStore, rootaws-loaded, a log line on failure) and lease.SetObligationDir(<data>/.ha-owed) (logged on failure; HA acquires then refuse); this body reads nothing new itself, the same five sites; the reads are those units' own (haRecordFacts and lease's SetObligationDir are new rows on this card); merge of origin/main d7ae1d76: main's own later changes to this body are kept as main has them, under main's rulings (census-ruling-remote-instance-metrics: the metricsOwners closure for metricsLoop; census-ruling-edge-asset-cache-3: the +file:Statfs site, assetcache.Statfs handed to the asset ready hook); this branch's change is the same as above;rev3=census-ruling-region-ha-p1b1;basis=region HA P1b-1: builds one termfence.Confirmer (Self from lease.CurrentSelf at each call, EC2 DescribeInstances method only, client from rootaws.LoadDefaultConfig with retries off, built lazily on first use) and sets eb.OwnerTerminated; this body reads nothing new itself, the same six sites;rev3=census-ruling-rootfs-apps-3;basis=rootfs Plan 3 Task 7: the startup Sweep literal hands its answer to startupSwept, which logs as before and, only on a clean sweep, marks rootfs admission swept (MarkRootfsSwept); same Sweep call, no read added;rev3=census-ruling-managed-fleets-1b;basis=managed fleets 1b (controller ruling after branch review R1, and Paul's R2 ruling): sets svc.Fleet = fleetWakeFor(os.Getenv, identity, identErr, fleetStore) from the identity it already resolves once and the deployment store the fleet loops already opened, and logs an ERROR naming the identity error when the box is on a fleet with an invalid identity. fleetWakeFor reads CARLOS_REGION and CARLOS_FLEET from the same environment. Read sites unchanged (6). Agent, not root; a platform box is unchanged.;rev3=census-ruling-rootfs-apps-6;basis=rootfs Plan 6 Task 12: one call more beside armRunsPass, armInteractivePass(svc, reg, rolloutSink, boxJudge), in the same activator Configure hook, handing it the same box judge; fix round 1 (Astra P2, shutdown): after svc.Shutdown(ctx), shutdownInteractive(ctx) ends and joins every interactive session under the same shutdown budget; the worker's own reads are its units' (interactive.go); this body reads nothing new, the same six sites; merge of origin/main 6f1f6ca6: main's svc.Fleet = fleetWakeFor(...) and its invalid-identity ERROR line are kept as main has them (census-ruling-managed-fleets-1b); this branch's change is the same as above; read sites unchanged (6);rev3=census-ruling-fix-set-aside-exdev;basis=set-aside EXDEV fix: one field more on the agent ExecBackend literal, RawInstanceDir: layout.RawInstanceDir (a pure path join: <dataDir>/.instances/<InstanceID(host)>), so the start rule set-aside moves a copy out through the raw directory instead of through the nosymfollow bind; this body reads nothing new, the same six sites;rev3=census-ruling-durability-3a-escrow;basis=durability 3a Task 3: one more assignment beside eb.FilesStore: eb.EscrowKey = haEscrowKey(os.Getenv("CARLOS_SECRETS_KEY")), the agent's own environment parsed by appconfig.ParsePrivateKey as the moves pass parses it (unset or unparseable: a log line and nil, and HA publication refuses on the box). No path is opened or read, no read site added; the same six sites, offsets moved; B,C,D,F authority retained. Durability 3a Task 4: one more goroutine beside configSyncLoop: go escrowLoop(agentCtx, reg, svc), the escrow sweep every 30 s over the same registry and Service. This body reads nothing new itself; the same six sites, offsets moved; B,C,D,F authority retained. Durability 3a Task 5: one more call beside eb.EscrowKey: wireRawSecretPages(eb, PageOperator, metricsBoxLabel(os.Getenv, readMachineID())), which sets eb.OnRawSecret to page an operator (alerting.Page through PageOperator, LevelIncident) on its own goroutine with a 20 s timeout; metricsBoxLabel and readMachineID are the reads this body already makes for the moves refusal log; no new read site; the same six sites, offsets moved; B,C,D,F authority retained. Merge of origin/main 90c4d3aa: main's own later changes to this body are kept as main has them, under main's rulings; this branch's change is the same as above. Merge of origin/main 00bf5b8c (fleet set-aside EXDEV fix): main's change to this body is kept as main has it, under its own census ruling; this branch's change is unchanged.;rev3=census-ruling-probe-burst-limit;basis=two more sink wirings beside setAnalyticsSink: setProtectionSink(e.SetProtectionRecordOnly) and setAssetOwnersSource(e.AssetOwners), function values the telemetry pass calls; this body reads nothing new, the same six sites; authority B,C,D,F retained; no new root read or write kind;rev3=census-ruling-region-ha-p1b3a;basis=Arm HA placement exactly once on the existing Service before activatorStart and edges publication, wiring AwakeApps and the PageOperator callback; existing six read sites unchanged, no new root authority.;rev3=census-ruling-stateless-replicas-1;basis=Final review I3: start the concrete coordinator's renewal worker with agent setup; existing closeReplicaCoordinator shutdown cancels and joins it before release. No new read sites or credentials. Merge origin/main c59715e7: retain main's armHAPlacement(svc, PageOperator) wiring beside the existing activator setup; stateless coordinator and shutdown wiring remain. Same read sites; no new root read or credential.;rev3=census-ruling-edge-held-streams;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): in the edge-ready callback, calls act.SetHeldWakeHook(e.HeldWake) when act is non-nil (installing the non-blocking wake callback) and stores e.HeldStreamsForStatus in heldStreamsSource. Wiring of in-memory callbacks only; no read added.;rev3=census-ruling-region-ha-p1b3b-t;basis=Wire Service.SetDutyView to the live edge DutySnapshot in the ready callback. No new read; no new loop or cloud operation. B2 wires the registry as the persistent DutyStore before service startup; no new cloud or filesystem path. B3b: arm one journal-backed termination consumer before service startup using agentCtx and the shared confirmer; expose edge tick and join at edge shutdown. No new direct read sites.;rev3=census-ruling-agent-start-demo-1;basis=Passes the existing registry, data store and hibernation prefix into the demo worker, and the existing instance-control client into the demo before-exec hook. No alternate data store or polling loop. Merge resolution against origin/main 9bd45488 retains main's HA departure controller, lifecycle and duty wiring alongside the demo data store and worker; no read site added by the resolution.;rev3=census-ruling-region-ha-p3a;basis=P3a Task 3: install closed fixed admission before every launch source, bind activator/backend and edge, wire the real termination Started lifecycle and role reader after the change index; close before cancellation/child shutdown. No new external reads or cloud authority. Fix R1: move bind/lifecycle/edge-option wiring into wireAgentAdmission and worker listing into runWorkerBootPassAfterAdmission. Worker boot waits for admission before listing then uses unchanged bounded wakes and per-host serialization; whole Route read moves to the helper. No new storage, cloud, or root execution authority. Preserve merged main's agent wiring and census basis; the branch removes one whole Route use by moving worker iteration to the helper, with no added read kind.;rev3=census-ruling-stateless-replicas-2;basis=Slice 3b: arms a fleet-only worker using the existing registry, activator, backend and authenticated console transport. Owned worker stops and joins at shutdown. No new bucket reader. merge of origin/main 9b8b2c50: retain HA duty/departure lifecycle, wake-slot and existing agent wiring alongside the replica placement worker; no new read introduced by resolution. merge of origin/main 6be08467: Retain main demo configuration, admission, build and expiry wiring alongside the replica worker; merge-only body change, no additional read. merge of origin/main 7920cccf: Retain main box-role/group admission wiring and boot publication beside the owned replica worker and shutdown; main moves the boot registry List into runWorkerBootPassAfterAdmission, removing its inline whole Route site. No new read introduced by conflict resolution.;rev3=census-ruling-stateless-replicas-3;basis=Task 1 fix round 1 M3: retain the private snapshot source and cancel/join ownership, but use the replica-health-specific retry loop. It logs its first failure only and retains the existing exponential backoff capped at 30 seconds; unsupported builds return nil. Existing five direct read sites unchanged; no new credentials, bucket reader or app lifecycle action. Fix round 1 Q20: publish Edge.ReplicaSnapshots as a separate in-memory status source, leaving the tenant-visible Upstreams source unchanged. No new external reader or authority.;rev3=census-ruling-region-ha-p3b;basis=Load root-written group marker/configuration, configure signed boot binding and agent receipt completer, wire cancellable admission into departure work and expose cached GroupReaderSnapshot. New indirect boot reads use protected root files; agent-owned receipt controls duplicate initial completion only, never root restart permission. Same five direct sites. Merge 45cebde4 retains the replica health socket lifecycle and setReplicaSource beside GroupReaderSnapshot; no extra read beyond main.;rev3=census-ruling-agent-start-demo-2;basis=agent.go:309-329 opens demo-traffic.db beside the operator-configured registry when a demo domain exists, closes it at shutdown and wires drain-before-purge; :1010-1019 shares the worker and write gate; :1164-1177 installs the fleet identity and closed-until-worker serving callback. One added whole Route pass; the new indirect filesystem/SQL reads are claimed in openDemoTraffic and worker/store units. No request chooses the database pathname.;rev3=census-ruling-region-ha-p1b3b-s;basis=Wire the service duty view to authoritative cached sidecar manifest placement in LifetimeIndex and the edge sidecar projection; missing policy denies duty. Existing instance duty wiring remains.;rev3=census-ruling-region-ha-g2-t3;basis=T3a: wire eb.Page = PageOperator beside OwnerTerminated before departures arm, so suspect-holder pages work if departure setup fails; no new read; existing nine sites and authority unchanged; pages through the existing sink. T3b: publish the same backend through an atomic pointer for the metrics observer, and clear it on return; no new external read or authority.;rev3=census-ruling-agent-start-demo-3;basis=Wire the claim activator and root snapshot client into the demo worker; pass moved readiness to status reporting. Census read-site delta: unchanged (9).;rev3=census-ruling-region-ha-g2-fixes;basis=Wire local pool evidence, live withdrawal activator, startup ingress scan and alias publication, and edge lookup; no new direct sites; new indirect record/claim reads use existing store/judge paths described in ingress helpers.;rev3=census-ruling-region-ha-g2r-fixes;basis=W3: starts the existing record-view backstop loop with a departure-inventory listener (non-blocking, coalesced signal) even without an armed RecordView; it requests the existing full pass (backstopFullDue) there. Same nine read sites; no new read or authority.;rev3=census-ruling-region-ha-graceful-terminate-t2;basis=Derive one signal-time deadline with a 90-second budget; cap departure stop and startup/seed/service shutdown joins by it. No read added.;rev3=census-ruling-static-sweep-periodic;basis=in the edge-ready callback, publishes e.LargestStaticTree in staticTreeSource for the disk alert line (diskAlertFrac in the metrics loop); in-memory wiring only, no read added; read sites unchanged (9);rev3=census-ruling-edge-page-cache-1;basis=wires the exec backend's CurrentInputs into the edge cache (wireCurrentInputs) and, in the ready hook after armEdgeAssetCache (whose returned store it now keeps), calls armEdgePageCache, which does nothing unless CARLOS_PAGE_CACHE=1; read sites unchanged (9); no read added;rev3=census-ruling-gvisor-demos;basis=Capture sandbox resolution and refusal once; log errors once; gate route admission and BeforeExec before process launch. No new root read. Task 5: pass the once-captured sandbox effective mode/config error into ExecBackend, UnitBackend and the immutable Client expectation. Same startup environment/registry reads; swapArming declines gVisor before placement. Task 8: arm read-only status projection with the existing Client.SandboxStatus callback. Agent status now queries the existing root /ready endpoint; no new root authority or guest-file input. Merge2 e8a1ddde: retain main wireCurrentInputs and armEdgePageCache through the existing asset-store ready hook alongside branch once-captured sandbox mode, wake gates and root status wiring. No new direct read; main page-cache helpers retain their own census overlays.;rev3=census-ruling-region-ha-held-build;basis=wires the drain state: svc.SetDrainingSource(boxDrain.IsDraining), svc.SetPeerDrainView(e.PeerDraining), e.SetPeerDrainedHook(svc.DropHoldersNaming); in-memory only; no read added; region HA held-requests Task 5: on group members, starts the drain driver over the activator, the edge and boxDrain, and serves its root-only drain socket; no read added beyond the socket's own Branch review r1: the drain state follows the root start fence on group members (the fence reader is the existing fenceLocation.read, a root-owned fixed path); e.SetPeerUndrainedHook(svc.AllowHoldersNaming) beside the drained hook (memory only); the drain socket serves only the agent's own user. No read added.;rev3=census-ruling-security-review-mitigations;basis=Wire the cached operator flat-layout choice into the exec backend's new-resident refusal; no read source added, existing authority retained.;rev3=census-ruling-w6-ingress-drain;basis=agent (user carlos), not root. Builds the ingress drain (newIngressDrain) with arming read at ask time from os.Getenv (CARLOS_REGION_HA, CARLOS_INGRESS_TARGET_GROUPS, both from the root-owned host.env), the fixed admission and lease.CurrentSelf (existing IMDS identity); its reader is awstg.Load, the box role's credentials calling ELB DescribeTargetHealth/DescribeTargetGroupAttributes (new AWS reads, by the agent). Wires admission.closeStartsForIngressDrain, the lbhealth drain condition, ingress.setEdge, and ingress.shutdownStarted in WithShutdownStarted. The drain socket (/run/carlos/.ha-drain/drain.sock, agent-user only, existing) is now also served on a fixed box with the drain configured (was group members only), routing /v1/ingress/* to the ingress drain and the group drain verbs to 404 there. armHADepartures now takes fixtureDepartureGetenv() and MakeQueue fixtureDepartureQueue(), which in a production (non-rootrunner) build are os.Getenv and nil, as before. Read sites unchanged (9).;rev3=census-ruling-stateless-replicas-4-task1;basis=Arms the fleet-only replica swap worker next to the placement worker: same console URL and fleet token as the existing replicaCoordinatorAPI, the existing activator Service; stops and joins at shutdown. No new read site, credential or bucket reader.;rev3=census-ruling-stateless-replicas-4-task2;basis=Task 2: sets deployWorker.step to the rollout scheduler answer for the record permit (replicaStepOf over armedRollout), an in-memory callback; no read site, credential or bucket reader added.;rev3=census-ruling-stateless-replicas-4-task2-fix2;basis=Task 2 fix round 2: the swap worker step is armedReplicaStep, the same lazy scheduler lookup as before as a named function; no read site added.;rev3=census-ruling-stateless-replicas-4-merge-main;basis=Merge of main 5fac2ff1: both sides changed it. Main (01d6ca78, linked-deployments-slice1) starts linkLoop beside tunnelLoop; this branch keeps its replica coordinator wiring. Both kept as-is; no read added.;rev3=census-ruling-stateless-replicas-4-final;basis=#511 final wave item 2: wires the swap worker's drive (armedReplicaDrive, the armed rollout manager's DriveReplicaRelease); no read added;rev3=census-ruling-stateless-replicas-4-merge-main2;basis=Merge of main af871da0 (v0.34.49): both sides changed it. Main (178dcfe5, member-backups-2a) moves the inline duty-view closure into armDutyView/dutyView and starts verifyAssignLoop; its sites drop by registry:Host and whole:Route x2 as main recorded them. This branch keeps its replica coordinator, swap worker and drive wiring. Both kept as-is; no read added.;rev3=census-ruling-stateless-replicas-4-drill3;basis=drill 3 R24: makes one in-memory channel, closes it (once) inside the edge's existing shutdown-started callback after ingress.shutdownStarted, and passes it to tunnelLoop, which drains only a fleet channel name; no read added, same six sites; touches no admission, lease, ingress drain, listener or file; the agent process, no root decision;rev3=census-ruling-edge-ppv2;basis=Agent (uid carlos), not root. memwatchLoop now gets edgeProxyCounters(&demoEdge) (in-process counters, no read). The drain socket's driver is newAgentDrainSocket(ingress, e, os.Getenv), which attaches the edge trust handler only when CARLOS_INGRESS_PROXY_SOURCES in the agent's environment (from the root-owned host.env) parses to a non-empty list; the socket is served when drainSocketServed: a group member or a configured ingress drain (both as before), or a box armed for PROXY protocol (new). The socket's path and agent-user-only permissions are unchanged. Read sites unchanged (6).;rev3=census-ruling-same-box-edge-fence;basis=Agent (uid carlos), not root. One added line: armEdgeFenceStatus(ctl.EdgeFence), beside the existing armExecSandboxStatus, so the layout report can ask root's /ready for the edge fence state over the control socket client the agent already holds. No read added.;rev3=census-ruling-platform-mail-submission;basis=Task 4: sets eb.Mail = mailsubmit.SocketForwarder{} on every box, and eb.MailSwitch to a mailSwitchCache's On that opens the deploy store itself through openDeployStore, retried at most once a minute with an error line until it opens (review round 1, Task 4 P3), armed for the serial-move refresh (armedMailSwitch). Task 6: also sets the ExecBackend's ManifestOf, the same staged-manifest read as TierOf (rt.App and RouteAccount(rt), hence +registry:App and +whole:Route), for the spawn-time check of decision 10, which logs and emits an event and never refuses. Agent, not root. Fable final P2-2: eb.MailSwitch is the cache's State (three-valued: on, off, unknown) in place of On; an unreadable switch is unknown, never off. No read added.;rev3=census-ruling-fleet-drain-followups;basis=P3 (#1008 T9): one call after armChangeIndex, requestBootFullPass(v, &backstopFullDue), which stores true in the existing in-memory backstopFullDue flag only when no record view is armed, so the fast loop runs its existing full pass on its first tick instead of instancesLoop a minute later; armed boxes unchanged. No read added; read sites unchanged (8); agent, not root.;rev3=census-ruling-fleet-first-reconcile-speed;basis=Startup timing log lines only: runDuties builds a step logger (newStartupLog, which reads the in-memory agent start time) and logs one line after the wait on the activator startup latch and after each existing duty before go fastConvergeLoop. One newStartupLog().at line in the edge ready hook before go tunnelLoop. No read added; read sites unchanged (8). Agent, not root.;rev3=census-ruling-ha-1192;basis=sets the group drain driver's departed hook to armedPeerDeparted (the armed departure controller's PeerDeparted: local registry identity + departure journal); no new read;rev3=census-ruling-replica-wake-gap-r3;basis=Calls lease.SetContinuityDir(<data dir>/.continuity) beside the existing obligation store: the agent's own 0700 directory for clean records, outside every instance tree (#1290 round 3). No new read; failure is logged and every start then takes a full image.;rev3=census-ruling-fleet-restart-wake;basis=Fleet restart wake Task 2: cfg.ReplicaRecord = replicaRecordFacts(boxLifetimes, cfg.Record): hands the existing judged record read (haRecordFacts over openDeployStore and boxJudge) as the live read on a lifetime index miss. No read site added here; agent, not root.;rev3=census-ruling-alias-publish-precert-1293;basis=starts edgesFileLoop with one more argument, edgeAcmeDir(os.Getenv, peekAcmeCache(args)): the agent's own -acme-cache flag (already parsed for domainsLoop) or $CARLOS_DATA_DIR/acme; a string computed from the operator's command line and environment, no read. Same 8 read sites.;rev3=census-ruling-console-addr-from-install;basis=publishes the running edge to consoleFleetEdgeSource for the heartbeat; no read added
- `internal/activator/activator.go` `Service.doWakeOnce`: legacy, task accepted-legacy. Basis: accepted-legacy;rev3=census-ruling-stateless-replicas-1;basis=Task 3a: The former doWake body, not deleted logic: refresh/admit/fence/layout checks remain. Select and verify the actual staged identity before serving Acquire; use canonical mode to call doStatelessWake. Keep SQLite acquire/restore/seed/marker/replicate only in the stateful arm, with the post-acquisition selection recheck and existing cleanup proofs. Fix 3a round 1 I1/I3a: admit config directly only for stateless and mark runtime ownership refusals. Stateful Acquire/Restore precede selection and pending publication; canonical mode inspection is separate, replan precedes settlement. Fix round 2 N2/N3: retain the original route/pin projection for post-lease declaration checks; reuse the unplanned capture so a live-link repoint cannot change the selected build. Stateful capture and changed-copy errors remain start failures after Acquire/Restore. A failed preliminary verification supplies no cached mode observation. No new file path or database authority. Final review C1/R26: unprojected stateful wakes capture and materialize the live link only after Acquire and Restore. Retain original route/generation/pin stateless evidence on the context across fallback, so missing stateless evidence cannot take stateful recovery inference. Known good stateful identity skips canonical declaration lookup. Existing pre-exec verification remains. R28 final fix 2: carry whether this wake has a plan in attempt-local context; no new read here; route, generation and pin stateless projection remains intact.;rev3=census-ruling-agent-start-demo-1;basis=Reads IsDemo and demo admission/capability state; chooses local lease retention, skips seed upload and sidecar selection. Existing stop and under-lease ordering retained.;rev3=census-ruling-region-ha-p3a;basis=P3a Task 3: refuse tenant starts under the existing service lock before main's demoWakeRefusal, and recheck before backend Acquire. Retain main's demo refusal and all lease, restore and serialization checks. Two added whole Route uses feed the in-memory admission predicate; no new filesystem or store read.;rev3=census-ruling-stateless-replicas-2;basis=P14: after verified storage-mode selection, before clearing the projected hint or acquiring a database lease, a set row still on the stateful branch returns ErrFenced. Reads the existing route FleetBoxes field only. Verified stateless wakes take their existing branch; legacy rows remain unchanged. No new file, registry query or bucket read. merge of origin/main 9b8b2c50: retain wake-slot and HA duty logic alongside the replica stateful-start refusal; no gate removed. merge of origin/main 6be08467: Keep main demo lease, local database and KeepLocal path; never equate replication-disabled demos with stateless generations. Merge-only body/read-site change. merge of origin/main 7920cccf: Retain main tenant admission and startOwnedLocked gates alongside the replica stateful-start refusal; whole Route passed to main admission checks, no new path or store read.;rev3=census-ruling-agent-start-demo-3;basis=Route claim seeds through seed restore/admission; do not fall back to empty boot or ordinary import behavior. Census read-site delta: +registry:SeedSource, +whole:Route.;rev3=census-ruling-region-ha-g2-fixes;basis=Bound recovery Acquire by its attempt deadline; existing acquire/restore/start ordering remains; no new read.;rev3=census-ruling-g6-fence;basis=G6 F-C Task 3, the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): right after retainDatabase returns, attaches the write-fence watcher under a.mu (watchWriteFenceLocked, in memory). retainDatabase is called through a retainDB test seam that is nil in production. No read added; no root call; existing acquire, restore, publisher and cleanup order unchanged.;rev3=census-ruling-sr-followups;basis=#1061 Task 1, the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): a refused plan now returns planRefusal(host, plan) instead of the inline fmt.Errorf, the text is unchanged, and when the planner marked the plan Installing the error also matches errBuildNotInstalled (installRefusal, in memory). Same refusal at the same point before the lease, read sites unchanged, no read, file, store, bucket or root call added;rev3=census-ruling-replica-wake-gap;basis=Step 2c: before the seed and the spawn, asks the lease to ProtectStart(rt.DBPath), the route's own database path already used by Restore and retainDatabase; a refusal gives the lease back and starts nothing. Agent code (user carlos); no root call, no new store or file read here.;rev3=census-ruling-replica-wake-gap-ch;basis=Step 2c's body moved unchanged into protectBeforeStart (replicatebeforestart.go); doWakeOnce passes the whole Route it already holds and returns the error. No read added; the DBPath read moved with the body.
New dispositions, which census-propose wrote and the reviewer checks against the unit's reads and the diff:
@@ -26,8 +26,8 @@ New dispositions, which census-propose wrote and the reviewer checks against the
- new `internal/appconfig/syncexec.go:ExecSpawned`: reads +whole:Route ×2; written legacy, accepted-legacy, frozen
- new `internal/appconfig/syncexec.go:syncExecHostMaking`: reads +registry:Host, +whole:Route ×3; written legacy, accepted-legacy, frozen
- new `internal/host/configbeforewake.go:configBeforeWake`: reads +whole:Route; written legacy, accepted-legacy, frozen
-- new `internal/host/configbeforewake.go:deliverConfigBeforeWake`: reads +file:Lstat, +registry:Host ×5, +whole:Route ×2; written legacy, accepted-legacy, frozen
+- new `internal/host/configbeforewake.go:deliverConfigBeforeWake`: reads +file:Lstat, +registry:Host ×6, +whole:Route ×2; written legacy, accepted-legacy, frozen
-Seal: `c25a6eac6ece70098b052b6451deff684c29ff8cfcd24ba37625f01028dedf88` → `87a5324119bd7dc0bdba8f6a0cc483adfc0a327d96b51aa2e82852527681c279`.
+Seal: `f273b5cb7bbf37b6dca4bb964a9293cbec15b14c1c0a19b9010c177f20789a86` → `aa953b1a43009c8208e44c67f5b8127ae1914b15d8b8822bcf16b19a6abdf121`.
Overlay: `internal/provision/testdata/plan14-root-reads-instance-ready-before-wake.tsv`, appended to `internal/provision/testdata/plan14-root-reads-chain.tsv`.
diff --git a/internal/appconfig/syncexec.go b/internal/appconfig/syncexec.go
index de91d71c9..c24134aed 100644
--- a/internal/appconfig/syncexec.go
+++ b/internal/appconfig/syncexec.go
@@ -823,10 +823,13 @@ func WhenInstanceDirAbsent(dirAbsent func(host, dir string)) SyncOption {
// the pass a wake runs before it plans (the agent's configBeforeWake): that
// wake's prepare would make the same directory, with the same mode, a
// moment later, and by then its first process has started without the
-// bundle. The directory is made only when there are bytes to put in it: a
-// row whose bundle renders nothing leaves no directory behind. Every other
-// pass leaves the directory to the activator, as before. Not under host
-// writes: there the row is named and left, as before.
+// bundle. The directory is made only when the pass has a file to write: a
+// row with no instance overlay whose bundle renders nothing gets no file
+// and leaves no directory behind. A row that has an instance overlay gets
+// its file even when the render is empty (renderExecConfigBefore's
+// keepAbsent is off for it), so its directory is made for an empty file.
+// Every other pass leaves the directory to the activator, as before. Not
+// under host writes: there the row is named and left, as before.
func MakeInstanceDir() SyncOption {
return func(o *syncOptions) { o.makeDir = true }
}
diff --git a/internal/host/configbeforewake.go b/internal/host/configbeforewake.go
index 78df940f4..9500cbac6 100644
--- a/internal/host/configbeforewake.go
+++ b/internal/host/configbeforewake.go
@@ -102,6 +102,13 @@ const configBeforeWakeBudget = 5 * time.Second
// writes one for a file that is by then up to date, and so an ack cut off
// by a budget the lock wait had spent would be lost for good. The config
// loops write theirs under no deadline at all.
+//
+// So the two budgets add up. With the scheduler armed the ack is written
+// later, when the revision is active, and the hook holds a wake for
+// configBeforeWakeBudget at most. Without it the pass writes the ack
+// in line, and the most a wake can be held is the two together: about ten
+// seconds, when the lock wait or the reads use up the first and the ack
+// then runs to the end of its own.
const configBeforeWakeAckBudget = 5 * time.Second
// configBeforeWakeRetry is how long a wake's pass that left a host
@@ -109,6 +116,16 @@ const configBeforeWakeAckBudget = 5 * time.Second
// which the config guard refuses, is asked for again by every retried
// request, and each pass is a set of bucket reads. The config guard's own
// refusals are remembered for as long (configGuardRefuseTTL).
+//
+// Only an attempt that ran starts the window: one that reached the store
+// and could not open it, or one that took the config lock. A wake that
+// gave up waiting for the lock read nothing and found nothing out, so it
+// starts none, and the next wake of that host asks again. Creating an
+// instance starts a config pass of its own at about the time of the first
+// wake, so the first wake is the likeliest to find the lock held; had it
+// started the window, the wake that follows seconds later (eighteen, in
+// the production trace above) would not have asked, and the first
+// generation would have started without its config after all.
const configBeforeWakeRetry = configGuardRefuseTTL
// wakeConfigLegs are the restart legs of a wake's own config pass. The
@@ -144,6 +161,16 @@ type settledHosts struct {
// configBeforeWakeRetry. Entries older than that are dropped as it goes,
// so the map holds only the hosts asked about in the last window.
func (s *settledHosts) due(host string) bool {
+ return s.dueAt(host, true)
+}
+
+// askedLately is due's answer turned round, with nothing recorded: the
+// check a wake makes before it has an attempt to record.
+func (s *settledHosts) askedLately(host string) bool {
+ return !s.dueAt(host, false)
+}
+
+func (s *settledHosts) dueAt(host string, record bool) bool {
s.mu.Lock()
defer s.mu.Unlock()
now := time.Now()
@@ -158,6 +185,9 @@ func (s *settledHosts) due(host string) bool {
if _, recent := s.asked[host]; recent {
return false
}
+ if !record {
+ return true
+ }
if s.asked == nil {
s.asked = map[string]time.Time{}
}
@@ -250,13 +280,15 @@ func configBeforeWake(reg *registry.Registry, dd string, writes hostwrite.Config
// there, and one a pass has settled with no file (configSettled) are left
// alone: the config loops own every later change to them. So is one a
// wake's pass was run for inside the last configBeforeWakeRetry and left
-// unsettled. Lstat only: a nested row's file is on ground its tenant can
-// write, and nothing here follows or opens it.
+// unsettled. That window starts only once an attempt has run: at a store
+// that will not open, or with the config lock in hand, never at a wait for
+// the lock that timed out. Lstat only: a nested row's file is on ground its
+// tenant can write, and nothing here follows or opens it.
func deliverConfigBeforeWake(wake context.Context, rt registry.Route, reg *registry.Registry, openStore func(context.Context) (release.Store, error), priv *ecdh.PrivateKey, dd string, writes hostwrite.Config) {
if !appconfig.ExecSpawned(rt) {
return
}
- if _, err := os.Lstat(appconfig.ConfigEnvPath(dd, rt)); err == nil || configSettled.has(rt.Host) || !configSettled.due(rt.Host) {
+ if _, err := os.Lstat(appconfig.ConfigEnvPath(dd, rt)); err == nil || configSettled.has(rt.Host) || configSettled.askedLately(rt.Host) {
return
}
ctx, cancel := context.WithTimeout(wake, configBeforeWakeBudget)
@@ -268,7 +300,9 @@ func deliverConfigBeforeWake(wake context.Context, rt registry.Route, reg *regis
store, err := openStore(ctx)
if err != nil {
// The config guard refuses this wake at the lease if the store
- // stays unreadable, and says so; nothing to add here.
+ // stays unreadable, and says so; nothing to add here. The store
+ // was asked, so this attempt starts the retry window.
+ configSettled.due(rt.Host)
return
}
if err := configSyncMu.lockContext(ctx); err != nil {
@@ -277,6 +311,13 @@ func deliverConfigBeforeWake(wake context.Context, rt registry.Route, reg *regis
}
defer configSyncMu.Unlock()
host := rt.Host
+ // The lock is this wake's, so its attempt runs and the retry window
+ // starts here. The pass it waited behind may have settled the host, and
+ // another wake of it may have run this pass in the meantime: either
+ // leaves nothing to ask.
+ if configSettled.has(host) || !configSettled.due(host) {
+ return
+ }
only := func(r registry.Route) bool { return r.Host == host }
if err := syncExecLocked(ctx, ackCtx, only, reg, store, priv, dd, wakeConfigLegs, []appconfig.SyncOption{appconfig.MakeInstanceDir()}, writes); err != nil {
log.Printf("agent: %s: config before its wake: %v; config sync delivers it", host, err)
diff --git a/internal/host/configbeforewake_test.go b/internal/host/configbeforewake_test.go
index acd3934df..d23f519ec 100644
--- a/internal/host/configbeforewake_test.go
+++ b/internal/host/configbeforewake_test.go
@@ -306,6 +306,36 @@ func TestConfigBeforeWakeGivesUpWhenAPassHoldsTheLock(t *testing.T) {
}
}
+// Production, 2026-11-24: creating an instance starts a config pass at about
+// the time of its first wake, and the wake that went on to start came
+// eighteen seconds after the first one. A first wake that gives up waiting
+// for that pass's lock has read nothing and found nothing out, so it does
+// not start the retry window: the next wake asks again and delivers. Had
+// the timed-out wait started the window, the later wake would have been
+// kept from asking for thirty seconds, and the first generation would have
+// started without its config after all.
+func TestConfigBeforeWakeALockTimeoutDoesNotStartTheRetryWindow(t *testing.T) {
+ k := newWakeConfigKit(t, map[string]string{"WOODSTAR_WORLD": "https://woodstar.app"})
+ now := time.Unix(1_800_000_000, 0)
+ configSettled.now = func() time.Time { return now }
+
+ configSyncMu.Lock() // the config pass the instance's creation started
+ gone, cancel := context.WithCancel(k.ctx)
+ cancel() // the first wake's budget, spent
+ k.deliver(gone, k.rt)
+ configSyncMu.Unlock()
+ if _, err := os.Lstat(k.cfgPath()); !os.IsNotExist(err) {
+ t.Fatalf("the wake that never had the lock wrote the file (err %v)", err)
+ }
+
+ // The wake that follows, inside what would have been the window.
+ now = now.Add(18 * time.Second)
+ k.deliver(k.ctx, k.rt)
+ if b, err := os.ReadFile(k.cfgPath()); err != nil || string(b) != "WOODSTAR_WORLD=https://woodstar.app\n" {
+ t.Fatalf("after a wake that timed out on the config lock, the next wake's bundle = %q, %v: the timeout kept it from asking, and the first process would start without its config", b, err)
+ }
+}
+
// With no armed guard, or a guard with no usable key, the agent's hook does
// nothing: such a box has no config to deliver.
func TestConfigBeforeWakeNeedsTheArmedGuardsKey(t *testing.T) {
diff --git a/internal/provision/testdata/plan14-root-reads-chain.tsv b/internal/provision/testdata/plan14-root-reads-chain.tsv
index 4ad1e7d6b..90ce7d6d8 100644
--- a/internal/provision/testdata/plan14-root-reads-chain.tsv
+++ b/internal/provision/testdata/plan14-root-reads-chain.tsv
@@ -288,4 +288,4 @@ plan14-root-reads-parent-delegation-1383.tsv 841361b89e20c3763149e8784cdebb037dc
plan14-root-reads-alias-publish-precert-1293.tsv c25a6eac6ece70098b052b6451deff684c29ff8cfcd24ba37625f01028dedf88
plan14-root-reads-domain-transfers.tsv c25a6eac6ece70098b052b6451deff684c29ff8cfcd24ba37625f01028dedf88
plan14-root-reads-console-addr-from-install.tsv f273b5cb7bbf37b6dca4bb964a9293cbec15b14c1c0a19b9010c177f20789a86
-plan14-root-reads-instance-ready-before-wake.tsv 87a5324119bd7dc0bdba8f6a0cc483adfc0a327d96b51aa2e82852527681c279
+plan14-root-reads-instance-ready-before-wake.tsv aa953b1a43009c8208e44c67f5b8127ae1914b15d8b8822bcf16b19a6abdf121
diff --git a/internal/provision/testdata/plan14-root-reads-instance-ready-before-wake.tsv b/internal/provision/testdata/plan14-root-reads-instance-ready-before-wake.tsv
index 96cba52e8..d6e72c112 100644
--- a/internal/provision/testdata/plan14-root-reads-instance-ready-before-wake.tsv
+++ b/internal/provision/testdata/plan14-root-reads-instance-ready-before-wake.tsv
@@ -6,17 +6,17 @@
@legacy 63e058cea5b592631e05edc06c2f9ee6a78e179a59de3dc0b29996c5c5e572e3 internal/appconfig/syncexec.go ExecSpawned legacy accepted-legacy accepted-legacy;rev3=census-ruling-instance-ready-before-wake;basis=new, pure: execSyncable or execSidecarCandidate over the route handed in, the sweep own scope test exported for the agent pass before a wake. Reads only that route. whole:Route@64,whole:Route@92 88a6489c054186890d32d32d53da14c222fa2588fc7413e550924bd7417e0396
@legacy 2c39ad99c9e89191d44291ffbc3f8bdfd0d2849f6aaaea089eb56900f2ade531 internal/appconfig/syncexec.go syncExecHostMaking legacy accepted-legacy accepted-legacy;rev3=census-ruling-instance-ready-before-wake;basis=new, the agent as carlos: syncExecHostClaimed, and when the pass asked for it (MakeInstanceDir, set only by the agent own pass before a wake) and the write found no instance directory, os.MkdirAll of provision.InstanceDir(dataDir, host) at 0700, the same call and mode the activator prepare makes at that wake, then the same write once more. A write under /data by the agent, never root. The registry Host and Route reads are the row the pass already holds. registry:Host@607,whole:Route@309,whole:Route@494,whole:Route@683 7aed70f5c1f2cfbf428e1cea4a0f19bd9f5b315bdfb9b2854741b6b56575d60b
@legacy 63832e4201c26a585011e3be94e893685adaea7313302f1d66c135f11862fb42 internal/host/configbeforewake.go configBeforeWake legacy accepted-legacy accepted-legacy;rev3=census-ruling-instance-ready-before-wake;basis=new, the agent as carlos: the hook runAgent sets. Takes the key and the deploy store from the armed config guard (the same key the config loops parse from CARLOS_SECRETS_KEY) and calls deliverConfigBeforeWake. Does nothing without a guard or a usable key. whole:Route@286 f8f7bf9e9f39049554cffab1069675efffd18f27968bdfad9d582f5f0753528f
-@legacy 6ea0ffcb850a2f9e9780150fedc6fd92bea1203a90f6a23ec767233938fd9fbe internal/host/configbeforewake.go deliverConfigBeforeWake legacy accepted-legacy accepted-legacy;rev3=census-ruling-instance-ready-before-wake;basis=new, the agent as carlos: for a route config sync delivers a file to (appconfig.ExecSpawned), one os.Lstat of its own config path under /data (appconfig.ConfigEnvPath, never followed or opened). When the file is absent, no pass has settled the host and none was run for it in the last 30s, one SyncExec pass narrowed to that host under configSyncMu, its lock wait and reads bounded by a 5s budget and its config ack by 5s more, with MakeInstanceDir and no restart leg. The registry Host reads are the route the activator handed in. Not reachable from root: only the agent wake path calls it. file:Lstat@270,registry:Host@1129,registry:Host@1212,registry:Host@1266,registry:Host@345,registry:Host@376,whole:Route@238,whole:Route@307 ddf49194e5462476974093322bb4083b3ce646701918a89ba2ba276c69a8c459
+@legacy 03aa016aacd19744dda0ac77249f8b07304c5ce2fde1d3a25be1211e3f432365 internal/host/configbeforewake.go deliverConfigBeforeWake legacy accepted-legacy accepted-legacy;rev3=census-ruling-instance-ready-before-wake;basis=new, the agent as carlos: for a route config sync delivers a file to (appconfig.ExecSpawned), one os.Lstat of its own config path under /data (appconfig.ConfigEnvPath, never followed or opened). When the file is absent, no pass has settled the host and no attempt ran for it in the last 30s, one SyncExec pass narrowed to that host under configSyncMu, its lock wait and reads bounded by a 5s budget and its config ack by 5s more (so up to about 10s on a box that acks in line), with MakeInstanceDir and no restart leg. The 30s window starts only when an attempt ran: at a store that would not open, or once the lock is held, where the settled and window checks are made again (in-memory, configSettled); a wait for the lock that timed out starts none, so the next wake asks again (census review P3, #280). That change adds one registry Host site (rt.Host handed to the window at the store failure), the route the activator handed in; no file or bucket read is added: the same one Lstat, before the lock. The registry Host reads are the route the activator handed in. Not reachable from root: only the agent wake path calls it. file:Lstat@270,registry:Host@1002,registry:Host@1232,registry:Host@1315,registry:Host@1680,registry:Host@345,registry:Host@383,whole:Route@238,whole:Route@307 63bcbc5945dafd3263864d7b616c36b89d71a401163733fd1cc81b3b10eca206
@legacy 5b0b3da8648fed2cc1fd2323209a1d2aadad19cc7bb60da32fc83150e86495a8 internal/activator/activator.go Service.doWakeOnce legacy accepted-legacy accepted-legacy;rev3=census-ruling-stateless-replicas-1;basis=Task 3a: The former doWake body, not deleted logic: refresh/admit/fence/layout checks remain. Select and verify the actual staged identity before serving Acquire; use canonical mode to call doStatelessWake. Keep SQLite acquire/restore/seed/marker/replicate only in the stateful arm, with the post-acquisition selection recheck and existing cleanup proofs. Fix 3a round 1 I1/I3a: admit config directly only for stateless and mark runtime ownership refusals. Stateful Acquire/Restore precede selection and pending publication; canonical mode inspection is separate, replan precedes settlement. Fix round 2 N2/N3: retain the original route/pin projection for post-lease declaration checks; reuse the unplanned capture so a live-link repoint cannot change the selected build. Stateful capture and changed-copy errors remain start failures after Acquire/Restore. A failed preliminary verification supplies no cached mode observation. No new file path or database authority. Final review C1/R26: unprojected stateful wakes capture and materialize the live link only after Acquire and Restore. Retain original route/generation/pin stateless evidence on the context across fallback, so missing stateless evidence cannot take stateful recovery inference. Known good stateful identity skips canonical declaration lookup. Existing pre-exec verification remains. R28 final fix 2: carry whether this wake has a plan in attempt-local context; no new read here; route, generation and pin stateless projection remains intact.;rev3=census-ruling-agent-start-demo-1;basis=Reads IsDemo and demo admission/capability state; chooses local lease retention, skips seed upload and sidecar selection. Existing stop and under-lease ordering retained.;rev3=census-ruling-region-ha-p3a;basis=P3a Task 3: refuse tenant starts under the existing service lock before main's demoWakeRefusal, and recheck before backend Acquire. Retain main's demo refusal and all lease, restore and serialization checks. Two added whole Route uses feed the in-memory admission predicate; no new filesystem or store read.;rev3=census-ruling-stateless-replicas-2;basis=P14: after verified storage-mode selection, before clearing the projected hint or acquiring a database lease, a set row still on the stateful branch returns ErrFenced. Reads the existing route FleetBoxes field only. Verified stateless wakes take their existing branch; legacy rows remain unchanged. No new file, registry query or bucket read. merge of origin/main 9b8b2c50: retain wake-slot and HA duty logic alongside the replica stateful-start refusal; no gate removed. merge of origin/main 6be08467: Keep main demo lease, local database and KeepLocal path; never equate replication-disabled demos with stateless generations. Merge-only body/read-site change. merge of origin/main 7920cccf: Retain main tenant admission and startOwnedLocked gates alongside the replica stateful-start refusal; whole Route passed to main admission checks, no new path or store read.;rev3=census-ruling-agent-start-demo-3;basis=Route claim seeds through seed restore/admission; do not fall back to empty boot or ordinary import behavior. Census read-site delta: +registry:SeedSource, +whole:Route.;rev3=census-ruling-region-ha-g2-fixes;basis=Bound recovery Acquire by its attempt deadline; existing acquire/restore/start ordering remains; no new read.;rev3=census-ruling-g6-fence;basis=G6 F-C Task 3, the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): right after retainDatabase returns, attaches the write-fence watcher under a.mu (watchWriteFenceLocked, in memory). retainDatabase is called through a retainDB test seam that is nil in production. No read added; no root call; existing acquire, restore, publisher and cleanup order unchanged.;rev3=census-ruling-sr-followups;basis=#1061 Task 1, the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): a refused plan now returns planRefusal(host, plan) instead of the inline fmt.Errorf, the text is unchanged, and when the planner marked the plan Installing the error also matches errBuildNotInstalled (installRefusal, in memory). Same refusal at the same point before the lease, read sites unchanged, no read, file, store, bucket or root call added;rev3=census-ruling-replica-wake-gap;basis=Step 2c: before the seed and the spawn, asks the lease to ProtectStart(rt.DBPath), the route's own database path already used by Restore and retainDatabase; a refusal gives the lease back and starts nothing. Agent code (user carlos); no root call, no new store or file read here.;rev3=census-ruling-replica-wake-gap-ch;basis=Step 2c's body moved unchanged into protectBeforeStart (replicatebeforestart.go); doWakeOnce passes the whole Route it already holds and returns the error. No read added; the DBPath read moved with the body.;rev3=census-ruling-instance-ready-before-wake;basis=the agent as carlos: one call, step 0.69, a.configBeforeWake(ctx, e, rt), after the held wake check and before the planner. It hands the hook the route this wake already holds (the added whole Route site). It returns nothing, so no refusal, lease, restore or spawn ordering changes. registry:DBPath@2071,registry:DBPath@2087,registry:DBPath@2214,registry:DBPath@2225,registry:FleetBoxes@12276,registry:GoodVersion@18566,registry:Host@1900,registry:Host@1975,registry:Host@2053,registry:Host@2205,registry:Host@2539,registry:Host@4556,registry:Host@6813,registry:Host@949,registry:Replication@17193,registry:Replication@17322,registry:Replication@17341,registry:Replication@17422,registry:Replication@33794,registry:Seed@22478,registry:SeedSource@35254,registry:Socket@2100,registry:Socket@2116,registry:Socket@2239,registry:Socket@2250,registry:Stateless@10336,registry:Stateless@10622,registry:Stateless@11994,registry:Stateless@12324,registry:Stateless@20975,registry:Stateless@9879,registry:Stateless@9970,whole:Route@10408,whole:Route@10567,whole:Route@10946,whole:Route@11044,whole:Route@11135,whole:Route@11267,whole:Route@11390,whole:Route@11444,whole:Route@11716,whole:Route@11892,whole:Route@11896,whole:Route@12683,whole:Route@12958,whole:Route@13276,whole:Route@142,whole:Route@14737,whole:Route@15414,whole:Route@16295,whole:Route@17173,whole:Route@17424,whole:Route@18769,whole:Route@19360,whole:Route@19525,whole:Route@1998,whole:Route@20461,whole:Route@21257,whole:Route@21532,whole:Route@21728,whole:Route@22579,whole:Route@22650,whole:Route@2434,whole:Route@2439,whole:Route@2493,whole:Route@2499,whole:Route@25144,whole:Route@2565,whole:Route@2573,whole:Route@2629,whole:Route@27002,whole:Route@27648,whole:Route@28955,whole:Route@29109,whole:Route@29608,whole:Route@29678,whole:Route@30265,whole:Route@31350,whole:Route@31781,whole:Route@31989,whole:Route@32043,whole:Route@32972,whole:Route@33157,whole:Route@333,whole:Route@33957,whole:Route@34028,whole:Route@34746,whole:Route@34795,whole:Route@35189,whole:Route@35371,whole:Route@3591,whole:Route@36623,whole:Route@36718,whole:Route@3685,whole:Route@3752,whole:Route@37559,whole:Route@4446,whole:Route@6182,whole:Route@6441,whole:Route@6703,whole:Route@6708,whole:Route@6765,whole:Route@6771,whole:Route@6840,whole:Route@6848,whole:Route@7164,whole:Route@7225,whole:Route@729,whole:Route@7323,whole:Route@7633,whole:Route@8534,whole:Route@934,whole:Route@9483,whole:Route@9707,whole:Route@9771,whole:Route@9815 72ca438f2e11c7a6eb14e09c895b481898b0162c786180e1c3fc61272b3392ce
internal/activator/activator.go type Service authority B,C,D,F,J4 rev3=PROPOSED-seed; existing activator lifecycle and due-wake state plus owned seed exclusion and incarnation-keyed diagnostics; normal refusal and preparation ordering remain authoritative; PROPOSED-plans-2-box-limits adds the idleFor hook field, which only narrows idle windows;rev3=census-ruling-plans-4c-box-throttle;basis=gains the maxRunFor hook field beside idleFor (plans 4c). No read added.;rev3=census-ruling-plans-4d-lapse;basis=gains the disabledFor hook field beside maxRunFor (plans 4d). No read added.;rev3=census-ruling-remote-instance-metrics;basis=gains tenancySeq, hostTenants and hostMixed, in-memory fields for Tenancies; no read added;rev3=census-ruling-region-ha-p1a;basis=the agent as carlos: one more field, markers (markerRetry: an atomic running flag and the last log time) for retryOwedMarkers; no read added; merge of origin/main d7ae1d76: main's fields are kept as main has them (census-ruling-remote-instance-metrics: tenancySeq, hostTenants, hostMixed); this branch's change is the same as above;rev3=census-ruling-rootfs-apps-3;basis=rootfs Plan 3 Tasks 7 and 8: new fields for rootfs admission (rootfsArmed, rootfsSwept), the per-host gate ask and refusal memo, and residency state (lister, backoff, start ceiling, cursor, test seam); no read;rev3=census-ruling-rootfs-apps-3-release;basis=rootfs Plan 3 Group R: one new field, releaseOps (host to the in-memory release record, under a.mu); no read;rev3=census-ruling-rootfs-apps-3-workers;basis=rootfs Plan 3 Group W: one new field, leaseNow (a clock seam for a worker start's headroom against the lease deadline, nil is the real clock); no read;rev3=census-ruling-region-ha-p1b2;basis=region HA P1b-2: gains the holder cache and its single-flight state; no read;rev3=census-ruling-managed-fleets-1b;basis=managed fleets 1b (controller ruling after branch review R1, and Paul's R2 ruling): one field, Fleet (activator.FleetWake: the box's fleet state, not on a fleet by default, on a fleet with a known label and a record reader, or on a fleet with an invalid identity), set by the agent before Start and read only by routeCurrentUnderLease. No read in the declaration. Agent, not root.;rev3=census-ruling-rootfs-apps-6;basis=rootfs Plan 6 Task 7a fix round 1: one field, drainBudget (time.Duration), which New copies from residentDrainBudget and a rootfs entry's lease watch reads in its place, so a test's change of the package var never races a watch goroutine; declaration only, reads nothing; merge of origin/main 6f1f6ca6: main's one field, Fleet (activator.FleetWake), is kept as main has it (census-ruling-managed-fleets-1b); this branch's change is the same as above;rev3=census-ruling-region-ha-p1b3a;basis=Add bounded placement peer and diagnostic state and the over-capacity callback; no read in this declaration and no new root authority.;rev3=census-ruling-stateless-replicas-1;basis=Add coordinator, existing-record observation callback and per-host preparation locks; no read in the declaration. Task 3a: Add optional canonical storage-selection and durable deploy-ID callbacks; declaration only, no read or authority in these fields.;rev3=census-ruling-edge-held-streams;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): adds the heldLegs map to actEntry (legs by id, under a.mu) and heldWakeHook (atomic pointer to a callback) and heldLegSeq (atomic counter) to Service. State only, in memory; no read of tenant, app or box-agent-writable input.;rev3=census-ruling-wake-storm-cap;basis=the agent as carlos: one field, wakeSlots (chan struct{}, the wake semaphore made by New from Config.WakeSlots, default 4); declaration only, no read.;rev3=census-ruling-region-ha-p1b3b-t;basis=Add the B2 DutyStore interface field and process-local duty view, suppression and invalidation state. No read added. B2 adds the verified-successor identity callback; no read in the declaration. B3b adds a nonblocking departure-suspicion callback, invoked only after an accepted holder-forward failure and after cache locks release; it cannot authorize a take.;rev3=census-ruling-region-ha-p3a;basis=P3a Task 3: immutable callbacks installed before Start for tenant admission, local start permission, fixed route exemptions and shutdown closure; nil callbacks preserve switch-off behavior; no new reads. Fix R1: add an immutable startup-phase callback for response copy, set before service startup. No new read or execution authority.;rev3=census-ruling-region-ha-g2-fixes;basis=Add in-memory HA loss state and pool withdrawal jobs; no new read.;rev3=census-ruling-region-ha-held-build;basis=region HA held-requests Task 1: one new field, drain (drainSources: two atomic func pointers for this box's and peers' drain state); no read added. region HA held-requests Task 2: one new field, moves (moveTable: per-host move state, hold counts and admission tickets in memory, under mu); no read added;rev3=census-ruling-held-move-speed;basis=the agent as carlos: one new field, moveStreams (per-host in-memory set of edge.StreamEnd for requests in flight, own mutex), for the move's early stream cut; actEntry gains drainRelease (bool, under a.mu), set by DrainStop; declarations only, no read added;rev3=census-ruling-fix-silent-start-kill-861;basis=#861: two fields, wakeFailMu and wakeFailLogged (per-host in-memory note of the last journalled wake failure); declaration only, no read;rev3=census-ruling-w6-ingress-drain;basis=new field TenantStartsClosed func() bool; when it answers true tenantStartRefusal refuses every start, exempt routes included. Wired only by fixedAdmission.bind to the ingress drain's closed flag. Struct field only; no read added.;rev3=census-ruling-stateless-replicas-4-task2;basis=Task 2: one field, replicaPolicies (host to the newest observed replica deploy and this box label, under mu), set only by SetReplicaDeploy; declaration only, no read.;rev3=census-ruling-stateless-replicas-4-task2-fix1;basis=Task 2 fix round 1: one more in-memory field, replicaFailed (host to the permit whose successor failed here, under mu), so that step only proves what it kept; declaration only, no read.;rev3=census-ruling-stateless-replicas-4-task3f;basis=Task 3F fix round 3 (#511 F11): two hook fields, MarkReplicaRelease and ReplicaReleaseMark (the failure book's per-host release mark on this box's disk). No read site.;rev3=census-ruling-stateless-replicas-4-task5;basis=Task 5 first commit (#511 F11): one in-memory field, heldSeen (host to the last held release attempt, error class and when it was met), under the existing wakeFailMu. Declaration only, no read.;rev3=census-ruling-stateless-replicas-4-merge-main;basis=Merge of main 5fac2ff1: both sides changed it. Main (27d3f501) adds the background atomic.Int64 field that tests wait on; this branch keeps its replica fields. Both kept as-is; no read added.;rev3=census-ruling-stateless-replicas-4-final;basis=#511 final wave item 3: adds replicaSwitched, an in-memory map of the permit each set row switched under (host -> permit key, time, resident flag); no read added; #511 micro-fix P1b: adds replicaNoGen, an in-memory map (host -> permit key and when first seen) that is only the bound's clock for a restarted permit holder with no generation; no read added;rev3=census-ruling-stateless-replicas-4-drill1;basis=#511 drill 1 R20 bound (round 1: clock with start and last seen): one in-memory field, releaseConfigWaits (per host, a stateless release's config wait), under mu; no read;rev3=census-ruling-stateless-replicas-4-r28;basis=R28 review round 2 (#511): one field, retiringCopy, an atomic pointer to the edge's in-memory retired-copy check, handed over by edge.New (SetRetiringCopy); no read, no root decision;rev3=census-ruling-g6-fence;basis=G6 F-C Task 3, the agent as carlos: four fields, fenceWatchers (sync.WaitGroup of running write-fence watchers) and three test seams nil in production (fenceWatchStarted, retainDB, wakeReturned). Declaration only, no read.;rev3=census-ruling-fleet-record-labels-m1;basis=fleet record labels R1/R2: actEntry gains checkpoint state (busy while CloseProven runs, unproven, named-once flag for C45), in-memory under a.mu; the worker gains fence pacing apart from crash backoff; Service gains test seams nil in production; declarations only, no read;rev3=census-ruling-race-activator-1249;basis=adds two test-only fields: leaseWork (a WaitGroup counting lease watches and the one-shot stops a short lease starts) and leaseWatchStop (a channel, nil in production, that a test closes to end every lease watch); no read added and production never waits on or closes either;rev3=census-ruling-fleet-restart-wake;basis=Fleet restart wake Task 1: the per-host journal note maps (wakeFailLogged, heldSeen) move into the embedded wakeNotes struct in wakefaillog.go, which adds fenceSeen. In-memory only; no read added.;rev3=census-ruling-stateless-scale-2-fleet-sizes;basis=the agent (carlos-edge.service, user carlos), not root: one embedded field (#892 S2), fleetSizeService (fleetreserve.go), which holds BoxLabel (string, the rollout's own box label, set by armRollout) and fleetReserve (fleetReservations, ready as its zero value; it reads /proc/meminfo through memAvailable only when a fleet-size overlap reserves), the box's in-memory overlap reservation for fleet sizes. Declaration only; no read added;rev3=census-ruling-instance-ready-before-wake;basis=the agent as carlos: gains the ConfigBeforeWake hook field beside Planner, a func the agent sets before Start. No read added. e7ccecb623a17e4997d4522352721273aec318985704dd2d20827b2d615a04bc
internal/appconfig/syncexec.go SyncExecWithCallbacks legacy accepted-legacy accepted-legacy;rev3=census-ruling-moves-offline-fixes;basis=route-and-input (J1,J4, main's disposition); the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos), through syncExecSerialized: main's body, with a nested row whose write found no instance directory named and skipped (errInstanceDirAbsent, WhenInstanceDirAbsent) instead of failing the pass, and each in-scope host reported done or not done (WithHostOutcome) once the pass has gone through every route; no new read site;rev3=PROPOSED-s3-change-index;identity=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos);basis=the scoped pass's route filter (WithRouteFilter, syncOptions.kept) is checked in its three route loops, so a route the filter leaves out is out of scope before anything is read for it; three whole-Route sites added, each passing rt to kept; no bucket or file read added;rev3=census-ruling-team-scoped-credentials;basis=team-scoped credentials (#449 §3): checkOptedIn's default-bundle thunk answers no default bundle for an OWNED environment bundle, so its exec_delivery is its own and never inherited; the same bundle reads as before, no read site added;rev3=census-ruling-named-unit-delivery-114;basis=the stale-file notice loop gains the stamped case: os.Stat of ConfigEnvPath(dataDir, rt), the path the exec-addr case already stats, and a notice line; no write, no new path;rev3=census-ruling-design-console-secrets;basis=the <host>.config collision set is built by routeHostSet (shared with the classifier) instead of inline; same rows read, same skip; no read site added;rev3=census-ruling-instance-ready-before-wake;basis=the agent as carlos, through syncExecLocked (root never calls SyncExec): the per-host call is now syncExecHostMaking with the pass MakeInstanceDir option (false under host writes). With the option off, as every config loop pass leaves it, the body is as before. No new read site. file:Stat@28864,file:Stat@30093,registry:App@10524,registry:App@10739,registry:App@16285,registry:App@28744,registry:Environment@10532,registry:Environment@10747,registry:Environment@16293,registry:Environment@28752,registry:Host@1031,registry:Host@1066,registry:Host@15793,registry:Host@16120,registry:Host@16218,registry:Host@17050,registry:Host@17401,registry:Host@18336,registry:Host@18877,registry:Host@21804,registry:Host@22021,registry:Host@22599,registry:Host@22779,registry:Host@22788,registry:Host@22807,registry:Host@25741,registry:Host@26358,registry:Host@26410,registry:Host@26566,registry:Host@29261,registry:Host@30411,registry:Host@866,registry:Host@937,whole:Route@10294,whole:Route@10352,whole:Route@10417,whole:Route@10478,whole:Route@10519,whole:Route@10636,whole:Route@10670,whole:Route@10734,whole:Route@1434,whole:Route@15705,whole:Route@15755,whole:Route@16280,whole:Route@25304,whole:Route@25751,whole:Route@26455,whole:Route@28612,whole:Route@28634,whole:Route@28692,whole:Route@28739,whole:Route@28844,whole:Route@29302,whole:Route@30073,whole:Route@30652,whole:Route@30725,whole:Route@693,whole:Route@721,whole:Route@750,whole:Route@776,whole:Route@811 fd973880272eb949a799ff2b447290ba922c3a70f6fc691ae41405232507deb7
-internal/host/agent.go runAgent authority B,C,D,F rev3=census-ruling-self-serve-moves-1;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): builds the box's lifetime judge once (newBoxJudge, nil with host claims on) and hands it to the seed placement, the moves and runs workers and every loop it starts; read sites unchanged, offsets moved; B,C,D,F authority retained; self-serve moves 1 Task 8: derives the box's lifetimes switch from the judge once (lifetimes := boxJudge != nil) and hands it to the edges file loop; read sites unchanged, offsets moved;rev3=census-ruling-plans-4d-lapse;basis=arms two more plans hooks from the same snapshot: e.SetPlanDisabledFor(planDisabledFor) beside SetPlanGovernedFor, and svc.SetDisabledFor(planDisabledRoute) beside SetMaxRunFor (plans 4d); the reads live in those units (plans-4d-units decision); read sites unchanged, offsets moved;rev3=census-ruling-rootfs-apps-2;basis=main's body as of the merge of origin/main 9b81d97b (with main's plan rate ceiling, edge request records, regional box names, self-serve moves plan 1, plans 4d-1 lapse and its other later changes under main's own census rulings) plus the rootfs placement wiring in the activator start: an agentRootfs built from eb.NestedOK, CARLOS_DEPLOYMENT_SINGLE_TENANT, CARLOS_POOLS, the claim flag, swapArming's answer, the control client's /ready/rootfs and, on a fleet box whose identity resolved, fleetOwnerCheck over the deploy store main already opens for the fleet label (fleetStore), then arm and armedRootfs.Store; this body reads nothing new itself; the closures it wires read later, at a rootfs wake and each status tick: GET /ready/rootfs over the control socket, NestedOK's checks, and release.FleetOwnerKey for the judged row's own account and this box's fleet from the deploy store;rev3=census-ruling-instance-egress-sizes-328-329;basis=#328 plan 2 Tasks 7 and 11, #329 plan 3 Task 7 and plan 1 Task 7's policy cache: the control client is built once and handed to eb.Control, to the status tick (egressStatus) and to a new egressNudgeLoop goroutine; armSizeSource(svc, "/sys/fs/cgroup") after the activator Service; armPolicyCache() after armChangeIndex; statusLoop takes egressStatus. The reads are those units' own (decision rows); this body reads nothing new: the same five sites, offsets moved, in the agent; B,C,D,F authority retained.;rev3=census-ruling-remote-instance-metrics;basis=builds the metrics loop's owners closure (metricsOwners over the agent's registry, the activator and cgm.Leftover) when an activator exists and hands it to metricsLoop; reads nothing new itself;rev3=census-ruling-edge-asset-cache-3;basis=adds file:Statfs. runAgent keeps its authority (B,C,D,F). The new site is assetcache.Statfs, an exported assetcache.FS interface value (var Statfs FS = statfsFS{}), not a function value and not a call in runAgent: the ready hook passes it to armEdgeAssetCache as the store's filesystem, and armEdgeAssetCache calls its Space method on the configured data directory (dataDir(): $CARLOS_DATA_DIR, else /data), which calls unix.Statfs there (statfsFS.Space, accepted legacy at census-ruling-edge-asset-cache-2). No request-supplied pathname reaches it.;rev3=census-ruling-remote-metrics-nested;basis=main's body (merged origin/main acfa4f80, under main's own census rulings) plus: snapshots the nested layout (snapshotNestedUnits over /sys/fs/cgroup/carlos.slice/carlos-instances.slice) once at start, before the activator, and hands the metrics loop a unitSources struct (stamped units, routeHostNames, that root and the snapshot); reads nothing new itself;rev3=census-ruling-region-ha-p1a;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): wires region HA P1a into the activator: cfg.Record = haRecordFacts(openDeployStore, boxJudge) (the box's lifetime judge this body already builds with newBoxJudge, nil with host claims on; CI fix) and cfg.Self = lease.CurrentSelf; eb.Lifetimes (the process's lifetime index), eb.Registry, eb.StartupSwept (seedSweptAtStart.Load), eb.FilesStore from newProductionFilesStore (now lease.NewFilesStore, rootaws-loaded, a log line on failure) and lease.SetObligationDir(<data>/.ha-owed) (logged on failure; HA acquires then refuse); this body reads nothing new itself, the same five sites; the reads are those units' own (haRecordFacts and lease's SetObligationDir are new rows on this card); merge of origin/main d7ae1d76: main's own later changes to this body are kept as main has them, under main's rulings (census-ruling-remote-instance-metrics: the metricsOwners closure for metricsLoop; census-ruling-edge-asset-cache-3: the +file:Statfs site, assetcache.Statfs handed to the asset ready hook); this branch's change is the same as above;rev3=census-ruling-region-ha-p1b1;basis=region HA P1b-1: builds one termfence.Confirmer (Self from lease.CurrentSelf at each call, EC2 DescribeInstances method only, client from rootaws.LoadDefaultConfig with retries off, built lazily on first use) and sets eb.OwnerTerminated; this body reads nothing new itself, the same six sites;rev3=census-ruling-rootfs-apps-3;basis=rootfs Plan 3 Task 7: the startup Sweep literal hands its answer to startupSwept, which logs as before and, only on a clean sweep, marks rootfs admission swept (MarkRootfsSwept); same Sweep call, no read added;rev3=census-ruling-managed-fleets-1b;basis=managed fleets 1b (controller ruling after branch review R1, and Paul's R2 ruling): sets svc.Fleet = fleetWakeFor(os.Getenv, identity, identErr, fleetStore) from the identity it already resolves once and the deployment store the fleet loops already opened, and logs an ERROR naming the identity error when the box is on a fleet with an invalid identity. fleetWakeFor reads CARLOS_REGION and CARLOS_FLEET from the same environment. Read sites unchanged (6). Agent, not root; a platform box is unchanged.;rev3=census-ruling-rootfs-apps-6;basis=rootfs Plan 6 Task 12: one call more beside armRunsPass, armInteractivePass(svc, reg, rolloutSink, boxJudge), in the same activator Configure hook, handing it the same box judge; fix round 1 (Astra P2, shutdown): after svc.Shutdown(ctx), shutdownInteractive(ctx) ends and joins every interactive session under the same shutdown budget; the worker's own reads are its units' (interactive.go); this body reads nothing new, the same six sites; merge of origin/main 6f1f6ca6: main's svc.Fleet = fleetWakeFor(...) and its invalid-identity ERROR line are kept as main has them (census-ruling-managed-fleets-1b); this branch's change is the same as above; read sites unchanged (6);rev3=census-ruling-fix-set-aside-exdev;basis=set-aside EXDEV fix: one field more on the agent ExecBackend literal, RawInstanceDir: layout.RawInstanceDir (a pure path join: <dataDir>/.instances/<InstanceID(host)>), so the start rule set-aside moves a copy out through the raw directory instead of through the nosymfollow bind; this body reads nothing new, the same six sites;rev3=census-ruling-durability-3a-escrow;basis=durability 3a Task 3: one more assignment beside eb.FilesStore: eb.EscrowKey = haEscrowKey(os.Getenv("CARLOS_SECRETS_KEY")), the agent's own environment parsed by appconfig.ParsePrivateKey as the moves pass parses it (unset or unparseable: a log line and nil, and HA publication refuses on the box). No path is opened or read, no read site added; the same six sites, offsets moved; B,C,D,F authority retained. Durability 3a Task 4: one more goroutine beside configSyncLoop: go escrowLoop(agentCtx, reg, svc), the escrow sweep every 30 s over the same registry and Service. This body reads nothing new itself; the same six sites, offsets moved; B,C,D,F authority retained. Durability 3a Task 5: one more call beside eb.EscrowKey: wireRawSecretPages(eb, PageOperator, metricsBoxLabel(os.Getenv, readMachineID())), which sets eb.OnRawSecret to page an operator (alerting.Page through PageOperator, LevelIncident) on its own goroutine with a 20 s timeout; metricsBoxLabel and readMachineID are the reads this body already makes for the moves refusal log; no new read site; the same six sites, offsets moved; B,C,D,F authority retained. Merge of origin/main 90c4d3aa: main's own later changes to this body are kept as main has them, under main's rulings; this branch's change is the same as above. Merge of origin/main 00bf5b8c (fleet set-aside EXDEV fix): main's change to this body is kept as main has it, under its own census ruling; this branch's change is unchanged.;rev3=census-ruling-probe-burst-limit;basis=two more sink wirings beside setAnalyticsSink: setProtectionSink(e.SetProtectionRecordOnly) and setAssetOwnersSource(e.AssetOwners), function values the telemetry pass calls; this body reads nothing new, the same six sites; authority B,C,D,F retained; no new root read or write kind;rev3=census-ruling-region-ha-p1b3a;basis=Arm HA placement exactly once on the existing Service before activatorStart and edges publication, wiring AwakeApps and the PageOperator callback; existing six read sites unchanged, no new root authority.;rev3=census-ruling-stateless-replicas-1;basis=Final review I3: start the concrete coordinator's renewal worker with agent setup; existing closeReplicaCoordinator shutdown cancels and joins it before release. No new read sites or credentials. Merge origin/main c59715e7: retain main's armHAPlacement(svc, PageOperator) wiring beside the existing activator setup; stateless coordinator and shutdown wiring remain. Same read sites; no new root read or credential.;rev3=census-ruling-edge-held-streams;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): in the edge-ready callback, calls act.SetHeldWakeHook(e.HeldWake) when act is non-nil (installing the non-blocking wake callback) and stores e.HeldStreamsForStatus in heldStreamsSource. Wiring of in-memory callbacks only; no read added.;rev3=census-ruling-region-ha-p1b3b-t;basis=Wire Service.SetDutyView to the live edge DutySnapshot in the ready callback. No new read; no new loop or cloud operation. B2 wires the registry as the persistent DutyStore before service startup; no new cloud or filesystem path. B3b: arm one journal-backed termination consumer before service startup using agentCtx and the shared confirmer; expose edge tick and join at edge shutdown. No new direct read sites.;rev3=census-ruling-agent-start-demo-1;basis=Passes the existing registry, data store and hibernation prefix into the demo worker, and the existing instance-control client into the demo before-exec hook. No alternate data store or polling loop. Merge resolution against origin/main 9bd45488 retains main's HA departure controller, lifecycle and duty wiring alongside the demo data store and worker; no read site added by the resolution.;rev3=census-ruling-region-ha-p3a;basis=P3a Task 3: install closed fixed admission before every launch source, bind activator/backend and edge, wire the real termination Started lifecycle and role reader after the change index; close before cancellation/child shutdown. No new external reads or cloud authority. Fix R1: move bind/lifecycle/edge-option wiring into wireAgentAdmission and worker listing into runWorkerBootPassAfterAdmission. Worker boot waits for admission before listing then uses unchanged bounded wakes and per-host serialization; whole Route read moves to the helper. No new storage, cloud, or root execution authority. Preserve merged main's agent wiring and census basis; the branch removes one whole Route use by moving worker iteration to the helper, with no added read kind.;rev3=census-ruling-stateless-replicas-2;basis=Slice 3b: arms a fleet-only worker using the existing registry, activator, backend and authenticated console transport. Owned worker stops and joins at shutdown. No new bucket reader. merge of origin/main 9b8b2c50: retain HA duty/departure lifecycle, wake-slot and existing agent wiring alongside the replica placement worker; no new read introduced by resolution. merge of origin/main 6be08467: Retain main demo configuration, admission, build and expiry wiring alongside the replica worker; merge-only body change, no additional read. merge of origin/main 7920cccf: Retain main box-role/group admission wiring and boot publication beside the owned replica worker and shutdown; main moves the boot registry List into runWorkerBootPassAfterAdmission, removing its inline whole Route site. No new read introduced by conflict resolution.;rev3=census-ruling-stateless-replicas-3;basis=Task 1 fix round 1 M3: retain the private snapshot source and cancel/join ownership, but use the replica-health-specific retry loop. It logs its first failure only and retains the existing exponential backoff capped at 30 seconds; unsupported builds return nil. Existing five direct read sites unchanged; no new credentials, bucket reader or app lifecycle action. Fix round 1 Q20: publish Edge.ReplicaSnapshots as a separate in-memory status source, leaving the tenant-visible Upstreams source unchanged. No new external reader or authority.;rev3=census-ruling-region-ha-p3b;basis=Load root-written group marker/configuration, configure signed boot binding and agent receipt completer, wire cancellable admission into departure work and expose cached GroupReaderSnapshot. New indirect boot reads use protected root files; agent-owned receipt controls duplicate initial completion only, never root restart permission. Same five direct sites. Merge 45cebde4 retains the replica health socket lifecycle and setReplicaSource beside GroupReaderSnapshot; no extra read beyond main.;rev3=census-ruling-agent-start-demo-2;basis=agent.go:309-329 opens demo-traffic.db beside the operator-configured registry when a demo domain exists, closes it at shutdown and wires drain-before-purge; :1010-1019 shares the worker and write gate; :1164-1177 installs the fleet identity and closed-until-worker serving callback. One added whole Route pass; the new indirect filesystem/SQL reads are claimed in openDemoTraffic and worker/store units. No request chooses the database pathname.;rev3=census-ruling-region-ha-p1b3b-s;basis=Wire the service duty view to authoritative cached sidecar manifest placement in LifetimeIndex and the edge sidecar projection; missing policy denies duty. Existing instance duty wiring remains.;rev3=census-ruling-region-ha-g2-t3;basis=T3a: wire eb.Page = PageOperator beside OwnerTerminated before departures arm, so suspect-holder pages work if departure setup fails; no new read; existing nine sites and authority unchanged; pages through the existing sink. T3b: publish the same backend through an atomic pointer for the metrics observer, and clear it on return; no new external read or authority.;rev3=census-ruling-agent-start-demo-3;basis=Wire the claim activator and root snapshot client into the demo worker; pass moved readiness to status reporting. Census read-site delta: unchanged (9).;rev3=census-ruling-region-ha-g2-fixes;basis=Wire local pool evidence, live withdrawal activator, startup ingress scan and alias publication, and edge lookup; no new direct sites; new indirect record/claim reads use existing store/judge paths described in ingress helpers.;rev3=census-ruling-region-ha-g2r-fixes;basis=W3: starts the existing record-view backstop loop with a departure-inventory listener (non-blocking, coalesced signal) even without an armed RecordView; it requests the existing full pass (backstopFullDue) there. Same nine read sites; no new read or authority.;rev3=census-ruling-region-ha-graceful-terminate-t2;basis=Derive one signal-time deadline with a 90-second budget; cap departure stop and startup/seed/service shutdown joins by it. No read added.;rev3=census-ruling-static-sweep-periodic;basis=in the edge-ready callback, publishes e.LargestStaticTree in staticTreeSource for the disk alert line (diskAlertFrac in the metrics loop); in-memory wiring only, no read added; read sites unchanged (9);rev3=census-ruling-edge-page-cache-1;basis=wires the exec backend's CurrentInputs into the edge cache (wireCurrentInputs) and, in the ready hook after armEdgeAssetCache (whose returned store it now keeps), calls armEdgePageCache, which does nothing unless CARLOS_PAGE_CACHE=1; read sites unchanged (9); no read added;rev3=census-ruling-gvisor-demos;basis=Capture sandbox resolution and refusal once; log errors once; gate route admission and BeforeExec before process launch. No new root read. Task 5: pass the once-captured sandbox effective mode/config error into ExecBackend, UnitBackend and the immutable Client expectation. Same startup environment/registry reads; swapArming declines gVisor before placement. Task 8: arm read-only status projection with the existing Client.SandboxStatus callback. Agent status now queries the existing root /ready endpoint; no new root authority or guest-file input. Merge2 e8a1ddde: retain main wireCurrentInputs and armEdgePageCache through the existing asset-store ready hook alongside branch once-captured sandbox mode, wake gates and root status wiring. No new direct read; main page-cache helpers retain their own census overlays.;rev3=census-ruling-region-ha-held-build;basis=wires the drain state: svc.SetDrainingSource(boxDrain.IsDraining), svc.SetPeerDrainView(e.PeerDraining), e.SetPeerDrainedHook(svc.DropHoldersNaming); in-memory only; no read added; region HA held-requests Task 5: on group members, starts the drain driver over the activator, the edge and boxDrain, and serves its root-only drain socket; no read added beyond the socket's own Branch review r1: the drain state follows the root start fence on group members (the fence reader is the existing fenceLocation.read, a root-owned fixed path); e.SetPeerUndrainedHook(svc.AllowHoldersNaming) beside the drained hook (memory only); the drain socket serves only the agent's own user. No read added.;rev3=census-ruling-security-review-mitigations;basis=Wire the cached operator flat-layout choice into the exec backend's new-resident refusal; no read source added, existing authority retained.;rev3=census-ruling-w6-ingress-drain;basis=agent (user carlos), not root. Builds the ingress drain (newIngressDrain) with arming read at ask time from os.Getenv (CARLOS_REGION_HA, CARLOS_INGRESS_TARGET_GROUPS, both from the root-owned host.env), the fixed admission and lease.CurrentSelf (existing IMDS identity); its reader is awstg.Load, the box role's credentials calling ELB DescribeTargetHealth/DescribeTargetGroupAttributes (new AWS reads, by the agent). Wires admission.closeStartsForIngressDrain, the lbhealth drain condition, ingress.setEdge, and ingress.shutdownStarted in WithShutdownStarted. The drain socket (/run/carlos/.ha-drain/drain.sock, agent-user only, existing) is now also served on a fixed box with the drain configured (was group members only), routing /v1/ingress/* to the ingress drain and the group drain verbs to 404 there. armHADepartures now takes fixtureDepartureGetenv() and MakeQueue fixtureDepartureQueue(), which in a production (non-rootrunner) build are os.Getenv and nil, as before. Read sites unchanged (9).;rev3=census-ruling-stateless-replicas-4-task1;basis=Arms the fleet-only replica swap worker next to the placement worker: same console URL and fleet token as the existing replicaCoordinatorAPI, the existing activator Service; stops and joins at shutdown. No new read site, credential or bucket reader.;rev3=census-ruling-stateless-replicas-4-task2;basis=Task 2: sets deployWorker.step to the rollout scheduler answer for the record permit (replicaStepOf over armedRollout), an in-memory callback; no read site, credential or bucket reader added.;rev3=census-ruling-stateless-replicas-4-task2-fix2;basis=Task 2 fix round 2: the swap worker step is armedReplicaStep, the same lazy scheduler lookup as before as a named function; no read site added.;rev3=census-ruling-stateless-replicas-4-merge-main;basis=Merge of main 5fac2ff1: both sides changed it. Main (01d6ca78, linked-deployments-slice1) starts linkLoop beside tunnelLoop; this branch keeps its replica coordinator wiring. Both kept as-is; no read added.;rev3=census-ruling-stateless-replicas-4-final;basis=#511 final wave item 2: wires the swap worker's drive (armedReplicaDrive, the armed rollout manager's DriveReplicaRelease); no read added;rev3=census-ruling-stateless-replicas-4-merge-main2;basis=Merge of main af871da0 (v0.34.49): both sides changed it. Main (178dcfe5, member-backups-2a) moves the inline duty-view closure into armDutyView/dutyView and starts verifyAssignLoop; its sites drop by registry:Host and whole:Route x2 as main recorded them. This branch keeps its replica coordinator, swap worker and drive wiring. Both kept as-is; no read added.;rev3=census-ruling-stateless-replicas-4-drill3;basis=drill 3 R24: makes one in-memory channel, closes it (once) inside the edge's existing shutdown-started callback after ingress.shutdownStarted, and passes it to tunnelLoop, which drains only a fleet channel name; no read added, same six sites; touches no admission, lease, ingress drain, listener or file; the agent process, no root decision;rev3=census-ruling-edge-ppv2;basis=Agent (uid carlos), not root. memwatchLoop now gets edgeProxyCounters(&demoEdge) (in-process counters, no read). The drain socket's driver is newAgentDrainSocket(ingress, e, os.Getenv), which attaches the edge trust handler only when CARLOS_INGRESS_PROXY_SOURCES in the agent's environment (from the root-owned host.env) parses to a non-empty list; the socket is served when drainSocketServed: a group member or a configured ingress drain (both as before), or a box armed for PROXY protocol (new). The socket's path and agent-user-only permissions are unchanged. Read sites unchanged (6).;rev3=census-ruling-same-box-edge-fence;basis=Agent (uid carlos), not root. One added line: armEdgeFenceStatus(ctl.EdgeFence), beside the existing armExecSandboxStatus, so the layout report can ask root's /ready for the edge fence state over the control socket client the agent already holds. No read added.;rev3=census-ruling-platform-mail-submission;basis=Task 4: sets eb.Mail = mailsubmit.SocketForwarder{} on every box, and eb.MailSwitch to a mailSwitchCache's On that opens the deploy store itself through openDeployStore, retried at most once a minute with an error line until it opens (review round 1, Task 4 P3), armed for the serial-move refresh (armedMailSwitch). Task 6: also sets the ExecBackend's ManifestOf, the same staged-manifest read as TierOf (rt.App and RouteAccount(rt), hence +registry:App and +whole:Route), for the spawn-time check of decision 10, which logs and emits an event and never refuses. Agent, not root. Fable final P2-2: eb.MailSwitch is the cache's State (three-valued: on, off, unknown) in place of On; an unreadable switch is unknown, never off. No read added.;rev3=census-ruling-fleet-drain-followups;basis=P3 (#1008 T9): one call after armChangeIndex, requestBootFullPass(v, &backstopFullDue), which stores true in the existing in-memory backstopFullDue flag only when no record view is armed, so the fast loop runs its existing full pass on its first tick instead of instancesLoop a minute later; armed boxes unchanged. No read added; read sites unchanged (8); agent, not root.;rev3=census-ruling-fleet-first-reconcile-speed;basis=Startup timing log lines only: runDuties builds a step logger (newStartupLog, which reads the in-memory agent start time) and logs one line after the wait on the activator startup latch and after each existing duty before go fastConvergeLoop. One newStartupLog().at line in the edge ready hook before go tunnelLoop. No read added; read sites unchanged (8). Agent, not root.;rev3=census-ruling-ha-1192;basis=sets the group drain driver's departed hook to armedPeerDeparted (the armed departure controller's PeerDeparted: local registry identity + departure journal); no new read;rev3=census-ruling-replica-wake-gap-r3;basis=Calls lease.SetContinuityDir(<data dir>/.continuity) beside the existing obligation store: the agent's own 0700 directory for clean records, outside every instance tree (#1290 round 3). No new read; failure is logged and every start then takes a full image.;rev3=census-ruling-fleet-restart-wake;basis=Fleet restart wake Task 2: cfg.ReplicaRecord = replicaRecordFacts(boxLifetimes, cfg.Record): hands the existing judged record read (haRecordFacts over openDeployStore and boxJudge) as the live read on a lifetime index miss. No read site added here; agent, not root.;rev3=census-ruling-alias-publish-precert-1293;basis=starts edgesFileLoop with one more argument, edgeAcmeDir(os.Getenv, peekAcmeCache(args)): the agent's own -acme-cache flag (already parsed for domainsLoop) or $CARLOS_DATA_DIR/acme; a string computed from the operator's command line and environment, no read. Same 8 read sites.;rev3=census-ruling-instance-ready-before-wake;basis=the agent as carlos: sets svc.ConfigBeforeWake = configBeforeWake(reg, dd, claims.Writes) beside BeforeExec, before Start. Read sites unchanged, offsets moved. file:Exec@22002,file:Open@2191,file:Statfs@58710,registry:App@13299,registry:App@13677,whole:Route@13291,whole:Route@13669,whole:Route@51925 f756b9a4787dec6d9866e6ff0809f3ee92b8536253a5b56c2ccf8f1923564073
+internal/host/agent.go runAgent authority B,C,D,F rev3=census-ruling-self-serve-moves-1;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): builds the box's lifetime judge once (newBoxJudge, nil with host claims on) and hands it to the seed placement, the moves and runs workers and every loop it starts; read sites unchanged, offsets moved; B,C,D,F authority retained; self-serve moves 1 Task 8: derives the box's lifetimes switch from the judge once (lifetimes := boxJudge != nil) and hands it to the edges file loop; read sites unchanged, offsets moved;rev3=census-ruling-plans-4d-lapse;basis=arms two more plans hooks from the same snapshot: e.SetPlanDisabledFor(planDisabledFor) beside SetPlanGovernedFor, and svc.SetDisabledFor(planDisabledRoute) beside SetMaxRunFor (plans 4d); the reads live in those units (plans-4d-units decision); read sites unchanged, offsets moved;rev3=census-ruling-rootfs-apps-2;basis=main's body as of the merge of origin/main 9b81d97b (with main's plan rate ceiling, edge request records, regional box names, self-serve moves plan 1, plans 4d-1 lapse and its other later changes under main's own census rulings) plus the rootfs placement wiring in the activator start: an agentRootfs built from eb.NestedOK, CARLOS_DEPLOYMENT_SINGLE_TENANT, CARLOS_POOLS, the claim flag, swapArming's answer, the control client's /ready/rootfs and, on a fleet box whose identity resolved, fleetOwnerCheck over the deploy store main already opens for the fleet label (fleetStore), then arm and armedRootfs.Store; this body reads nothing new itself; the closures it wires read later, at a rootfs wake and each status tick: GET /ready/rootfs over the control socket, NestedOK's checks, and release.FleetOwnerKey for the judged row's own account and this box's fleet from the deploy store;rev3=census-ruling-instance-egress-sizes-328-329;basis=#328 plan 2 Tasks 7 and 11, #329 plan 3 Task 7 and plan 1 Task 7's policy cache: the control client is built once and handed to eb.Control, to the status tick (egressStatus) and to a new egressNudgeLoop goroutine; armSizeSource(svc, "/sys/fs/cgroup") after the activator Service; armPolicyCache() after armChangeIndex; statusLoop takes egressStatus. The reads are those units' own (decision rows); this body reads nothing new: the same five sites, offsets moved, in the agent; B,C,D,F authority retained.;rev3=census-ruling-remote-instance-metrics;basis=builds the metrics loop's owners closure (metricsOwners over the agent's registry, the activator and cgm.Leftover) when an activator exists and hands it to metricsLoop; reads nothing new itself;rev3=census-ruling-edge-asset-cache-3;basis=adds file:Statfs. runAgent keeps its authority (B,C,D,F). The new site is assetcache.Statfs, an exported assetcache.FS interface value (var Statfs FS = statfsFS{}), not a function value and not a call in runAgent: the ready hook passes it to armEdgeAssetCache as the store's filesystem, and armEdgeAssetCache calls its Space method on the configured data directory (dataDir(): $CARLOS_DATA_DIR, else /data), which calls unix.Statfs there (statfsFS.Space, accepted legacy at census-ruling-edge-asset-cache-2). No request-supplied pathname reaches it.;rev3=census-ruling-remote-metrics-nested;basis=main's body (merged origin/main acfa4f80, under main's own census rulings) plus: snapshots the nested layout (snapshotNestedUnits over /sys/fs/cgroup/carlos.slice/carlos-instances.slice) once at start, before the activator, and hands the metrics loop a unitSources struct (stamped units, routeHostNames, that root and the snapshot); reads nothing new itself;rev3=census-ruling-region-ha-p1a;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): wires region HA P1a into the activator: cfg.Record = haRecordFacts(openDeployStore, boxJudge) (the box's lifetime judge this body already builds with newBoxJudge, nil with host claims on; CI fix) and cfg.Self = lease.CurrentSelf; eb.Lifetimes (the process's lifetime index), eb.Registry, eb.StartupSwept (seedSweptAtStart.Load), eb.FilesStore from newProductionFilesStore (now lease.NewFilesStore, rootaws-loaded, a log line on failure) and lease.SetObligationDir(<data>/.ha-owed) (logged on failure; HA acquires then refuse); this body reads nothing new itself, the same five sites; the reads are those units' own (haRecordFacts and lease's SetObligationDir are new rows on this card); merge of origin/main d7ae1d76: main's own later changes to this body are kept as main has them, under main's rulings (census-ruling-remote-instance-metrics: the metricsOwners closure for metricsLoop; census-ruling-edge-asset-cache-3: the +file:Statfs site, assetcache.Statfs handed to the asset ready hook); this branch's change is the same as above;rev3=census-ruling-region-ha-p1b1;basis=region HA P1b-1: builds one termfence.Confirmer (Self from lease.CurrentSelf at each call, EC2 DescribeInstances method only, client from rootaws.LoadDefaultConfig with retries off, built lazily on first use) and sets eb.OwnerTerminated; this body reads nothing new itself, the same six sites;rev3=census-ruling-rootfs-apps-3;basis=rootfs Plan 3 Task 7: the startup Sweep literal hands its answer to startupSwept, which logs as before and, only on a clean sweep, marks rootfs admission swept (MarkRootfsSwept); same Sweep call, no read added;rev3=census-ruling-managed-fleets-1b;basis=managed fleets 1b (controller ruling after branch review R1, and Paul's R2 ruling): sets svc.Fleet = fleetWakeFor(os.Getenv, identity, identErr, fleetStore) from the identity it already resolves once and the deployment store the fleet loops already opened, and logs an ERROR naming the identity error when the box is on a fleet with an invalid identity. fleetWakeFor reads CARLOS_REGION and CARLOS_FLEET from the same environment. Read sites unchanged (6). Agent, not root; a platform box is unchanged.;rev3=census-ruling-rootfs-apps-6;basis=rootfs Plan 6 Task 12: one call more beside armRunsPass, armInteractivePass(svc, reg, rolloutSink, boxJudge), in the same activator Configure hook, handing it the same box judge; fix round 1 (Astra P2, shutdown): after svc.Shutdown(ctx), shutdownInteractive(ctx) ends and joins every interactive session under the same shutdown budget; the worker's own reads are its units' (interactive.go); this body reads nothing new, the same six sites; merge of origin/main 6f1f6ca6: main's svc.Fleet = fleetWakeFor(...) and its invalid-identity ERROR line are kept as main has them (census-ruling-managed-fleets-1b); this branch's change is the same as above; read sites unchanged (6);rev3=census-ruling-fix-set-aside-exdev;basis=set-aside EXDEV fix: one field more on the agent ExecBackend literal, RawInstanceDir: layout.RawInstanceDir (a pure path join: <dataDir>/.instances/<InstanceID(host)>), so the start rule set-aside moves a copy out through the raw directory instead of through the nosymfollow bind; this body reads nothing new, the same six sites;rev3=census-ruling-durability-3a-escrow;basis=durability 3a Task 3: one more assignment beside eb.FilesStore: eb.EscrowKey = haEscrowKey(os.Getenv("CARLOS_SECRETS_KEY")), the agent's own environment parsed by appconfig.ParsePrivateKey as the moves pass parses it (unset or unparseable: a log line and nil, and HA publication refuses on the box). No path is opened or read, no read site added; the same six sites, offsets moved; B,C,D,F authority retained. Durability 3a Task 4: one more goroutine beside configSyncLoop: go escrowLoop(agentCtx, reg, svc), the escrow sweep every 30 s over the same registry and Service. This body reads nothing new itself; the same six sites, offsets moved; B,C,D,F authority retained. Durability 3a Task 5: one more call beside eb.EscrowKey: wireRawSecretPages(eb, PageOperator, metricsBoxLabel(os.Getenv, readMachineID())), which sets eb.OnRawSecret to page an operator (alerting.Page through PageOperator, LevelIncident) on its own goroutine with a 20 s timeout; metricsBoxLabel and readMachineID are the reads this body already makes for the moves refusal log; no new read site; the same six sites, offsets moved; B,C,D,F authority retained. Merge of origin/main 90c4d3aa: main's own later changes to this body are kept as main has them, under main's rulings; this branch's change is the same as above. Merge of origin/main 00bf5b8c (fleet set-aside EXDEV fix): main's change to this body is kept as main has it, under its own census ruling; this branch's change is unchanged.;rev3=census-ruling-probe-burst-limit;basis=two more sink wirings beside setAnalyticsSink: setProtectionSink(e.SetProtectionRecordOnly) and setAssetOwnersSource(e.AssetOwners), function values the telemetry pass calls; this body reads nothing new, the same six sites; authority B,C,D,F retained; no new root read or write kind;rev3=census-ruling-region-ha-p1b3a;basis=Arm HA placement exactly once on the existing Service before activatorStart and edges publication, wiring AwakeApps and the PageOperator callback; existing six read sites unchanged, no new root authority.;rev3=census-ruling-stateless-replicas-1;basis=Final review I3: start the concrete coordinator's renewal worker with agent setup; existing closeReplicaCoordinator shutdown cancels and joins it before release. No new read sites or credentials. Merge origin/main c59715e7: retain main's armHAPlacement(svc, PageOperator) wiring beside the existing activator setup; stateless coordinator and shutdown wiring remain. Same read sites; no new root read or credential.;rev3=census-ruling-edge-held-streams;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): in the edge-ready callback, calls act.SetHeldWakeHook(e.HeldWake) when act is non-nil (installing the non-blocking wake callback) and stores e.HeldStreamsForStatus in heldStreamsSource. Wiring of in-memory callbacks only; no read added.;rev3=census-ruling-region-ha-p1b3b-t;basis=Wire Service.SetDutyView to the live edge DutySnapshot in the ready callback. No new read; no new loop or cloud operation. B2 wires the registry as the persistent DutyStore before service startup; no new cloud or filesystem path. B3b: arm one journal-backed termination consumer before service startup using agentCtx and the shared confirmer; expose edge tick and join at edge shutdown. No new direct read sites.;rev3=census-ruling-agent-start-demo-1;basis=Passes the existing registry, data store and hibernation prefix into the demo worker, and the existing instance-control client into the demo before-exec hook. No alternate data store or polling loop. Merge resolution against origin/main 9bd45488 retains main's HA departure controller, lifecycle and duty wiring alongside the demo data store and worker; no read site added by the resolution.;rev3=census-ruling-region-ha-p3a;basis=P3a Task 3: install closed fixed admission before every launch source, bind activator/backend and edge, wire the real termination Started lifecycle and role reader after the change index; close before cancellation/child shutdown. No new external reads or cloud authority. Fix R1: move bind/lifecycle/edge-option wiring into wireAgentAdmission and worker listing into runWorkerBootPassAfterAdmission. Worker boot waits for admission before listing then uses unchanged bounded wakes and per-host serialization; whole Route read moves to the helper. No new storage, cloud, or root execution authority. Preserve merged main's agent wiring and census basis; the branch removes one whole Route use by moving worker iteration to the helper, with no added read kind.;rev3=census-ruling-stateless-replicas-2;basis=Slice 3b: arms a fleet-only worker using the existing registry, activator, backend and authenticated console transport. Owned worker stops and joins at shutdown. No new bucket reader. merge of origin/main 9b8b2c50: retain HA duty/departure lifecycle, wake-slot and existing agent wiring alongside the replica placement worker; no new read introduced by resolution. merge of origin/main 6be08467: Retain main demo configuration, admission, build and expiry wiring alongside the replica worker; merge-only body change, no additional read. merge of origin/main 7920cccf: Retain main box-role/group admission wiring and boot publication beside the owned replica worker and shutdown; main moves the boot registry List into runWorkerBootPassAfterAdmission, removing its inline whole Route site. No new read introduced by conflict resolution.;rev3=census-ruling-stateless-replicas-3;basis=Task 1 fix round 1 M3: retain the private snapshot source and cancel/join ownership, but use the replica-health-specific retry loop. It logs its first failure only and retains the existing exponential backoff capped at 30 seconds; unsupported builds return nil. Existing five direct read sites unchanged; no new credentials, bucket reader or app lifecycle action. Fix round 1 Q20: publish Edge.ReplicaSnapshots as a separate in-memory status source, leaving the tenant-visible Upstreams source unchanged. No new external reader or authority.;rev3=census-ruling-region-ha-p3b;basis=Load root-written group marker/configuration, configure signed boot binding and agent receipt completer, wire cancellable admission into departure work and expose cached GroupReaderSnapshot. New indirect boot reads use protected root files; agent-owned receipt controls duplicate initial completion only, never root restart permission. Same five direct sites. Merge 45cebde4 retains the replica health socket lifecycle and setReplicaSource beside GroupReaderSnapshot; no extra read beyond main.;rev3=census-ruling-agent-start-demo-2;basis=agent.go:309-329 opens demo-traffic.db beside the operator-configured registry when a demo domain exists, closes it at shutdown and wires drain-before-purge; :1010-1019 shares the worker and write gate; :1164-1177 installs the fleet identity and closed-until-worker serving callback. One added whole Route pass; the new indirect filesystem/SQL reads are claimed in openDemoTraffic and worker/store units. No request chooses the database pathname.;rev3=census-ruling-region-ha-p1b3b-s;basis=Wire the service duty view to authoritative cached sidecar manifest placement in LifetimeIndex and the edge sidecar projection; missing policy denies duty. Existing instance duty wiring remains.;rev3=census-ruling-region-ha-g2-t3;basis=T3a: wire eb.Page = PageOperator beside OwnerTerminated before departures arm, so suspect-holder pages work if departure setup fails; no new read; existing nine sites and authority unchanged; pages through the existing sink. T3b: publish the same backend through an atomic pointer for the metrics observer, and clear it on return; no new external read or authority.;rev3=census-ruling-agent-start-demo-3;basis=Wire the claim activator and root snapshot client into the demo worker; pass moved readiness to status reporting. Census read-site delta: unchanged (9).;rev3=census-ruling-region-ha-g2-fixes;basis=Wire local pool evidence, live withdrawal activator, startup ingress scan and alias publication, and edge lookup; no new direct sites; new indirect record/claim reads use existing store/judge paths described in ingress helpers.;rev3=census-ruling-region-ha-g2r-fixes;basis=W3: starts the existing record-view backstop loop with a departure-inventory listener (non-blocking, coalesced signal) even without an armed RecordView; it requests the existing full pass (backstopFullDue) there. Same nine read sites; no new read or authority.;rev3=census-ruling-region-ha-graceful-terminate-t2;basis=Derive one signal-time deadline with a 90-second budget; cap departure stop and startup/seed/service shutdown joins by it. No read added.;rev3=census-ruling-static-sweep-periodic;basis=in the edge-ready callback, publishes e.LargestStaticTree in staticTreeSource for the disk alert line (diskAlertFrac in the metrics loop); in-memory wiring only, no read added; read sites unchanged (9);rev3=census-ruling-edge-page-cache-1;basis=wires the exec backend's CurrentInputs into the edge cache (wireCurrentInputs) and, in the ready hook after armEdgeAssetCache (whose returned store it now keeps), calls armEdgePageCache, which does nothing unless CARLOS_PAGE_CACHE=1; read sites unchanged (9); no read added;rev3=census-ruling-gvisor-demos;basis=Capture sandbox resolution and refusal once; log errors once; gate route admission and BeforeExec before process launch. No new root read. Task 5: pass the once-captured sandbox effective mode/config error into ExecBackend, UnitBackend and the immutable Client expectation. Same startup environment/registry reads; swapArming declines gVisor before placement. Task 8: arm read-only status projection with the existing Client.SandboxStatus callback. Agent status now queries the existing root /ready endpoint; no new root authority or guest-file input. Merge2 e8a1ddde: retain main wireCurrentInputs and armEdgePageCache through the existing asset-store ready hook alongside branch once-captured sandbox mode, wake gates and root status wiring. No new direct read; main page-cache helpers retain their own census overlays.;rev3=census-ruling-region-ha-held-build;basis=wires the drain state: svc.SetDrainingSource(boxDrain.IsDraining), svc.SetPeerDrainView(e.PeerDraining), e.SetPeerDrainedHook(svc.DropHoldersNaming); in-memory only; no read added; region HA held-requests Task 5: on group members, starts the drain driver over the activator, the edge and boxDrain, and serves its root-only drain socket; no read added beyond the socket's own Branch review r1: the drain state follows the root start fence on group members (the fence reader is the existing fenceLocation.read, a root-owned fixed path); e.SetPeerUndrainedHook(svc.AllowHoldersNaming) beside the drained hook (memory only); the drain socket serves only the agent's own user. No read added.;rev3=census-ruling-security-review-mitigations;basis=Wire the cached operator flat-layout choice into the exec backend's new-resident refusal; no read source added, existing authority retained.;rev3=census-ruling-w6-ingress-drain;basis=agent (user carlos), not root. Builds the ingress drain (newIngressDrain) with arming read at ask time from os.Getenv (CARLOS_REGION_HA, CARLOS_INGRESS_TARGET_GROUPS, both from the root-owned host.env), the fixed admission and lease.CurrentSelf (existing IMDS identity); its reader is awstg.Load, the box role's credentials calling ELB DescribeTargetHealth/DescribeTargetGroupAttributes (new AWS reads, by the agent). Wires admission.closeStartsForIngressDrain, the lbhealth drain condition, ingress.setEdge, and ingress.shutdownStarted in WithShutdownStarted. The drain socket (/run/carlos/.ha-drain/drain.sock, agent-user only, existing) is now also served on a fixed box with the drain configured (was group members only), routing /v1/ingress/* to the ingress drain and the group drain verbs to 404 there. armHADepartures now takes fixtureDepartureGetenv() and MakeQueue fixtureDepartureQueue(), which in a production (non-rootrunner) build are os.Getenv and nil, as before. Read sites unchanged (9).;rev3=census-ruling-stateless-replicas-4-task1;basis=Arms the fleet-only replica swap worker next to the placement worker: same console URL and fleet token as the existing replicaCoordinatorAPI, the existing activator Service; stops and joins at shutdown. No new read site, credential or bucket reader.;rev3=census-ruling-stateless-replicas-4-task2;basis=Task 2: sets deployWorker.step to the rollout scheduler answer for the record permit (replicaStepOf over armedRollout), an in-memory callback; no read site, credential or bucket reader added.;rev3=census-ruling-stateless-replicas-4-task2-fix2;basis=Task 2 fix round 2: the swap worker step is armedReplicaStep, the same lazy scheduler lookup as before as a named function; no read site added.;rev3=census-ruling-stateless-replicas-4-merge-main;basis=Merge of main 5fac2ff1: both sides changed it. Main (01d6ca78, linked-deployments-slice1) starts linkLoop beside tunnelLoop; this branch keeps its replica coordinator wiring. Both kept as-is; no read added.;rev3=census-ruling-stateless-replicas-4-final;basis=#511 final wave item 2: wires the swap worker's drive (armedReplicaDrive, the armed rollout manager's DriveReplicaRelease); no read added;rev3=census-ruling-stateless-replicas-4-merge-main2;basis=Merge of main af871da0 (v0.34.49): both sides changed it. Main (178dcfe5, member-backups-2a) moves the inline duty-view closure into armDutyView/dutyView and starts verifyAssignLoop; its sites drop by registry:Host and whole:Route x2 as main recorded them. This branch keeps its replica coordinator, swap worker and drive wiring. Both kept as-is; no read added.;rev3=census-ruling-stateless-replicas-4-drill3;basis=drill 3 R24: makes one in-memory channel, closes it (once) inside the edge's existing shutdown-started callback after ingress.shutdownStarted, and passes it to tunnelLoop, which drains only a fleet channel name; no read added, same six sites; touches no admission, lease, ingress drain, listener or file; the agent process, no root decision;rev3=census-ruling-edge-ppv2;basis=Agent (uid carlos), not root. memwatchLoop now gets edgeProxyCounters(&demoEdge) (in-process counters, no read). The drain socket's driver is newAgentDrainSocket(ingress, e, os.Getenv), which attaches the edge trust handler only when CARLOS_INGRESS_PROXY_SOURCES in the agent's environment (from the root-owned host.env) parses to a non-empty list; the socket is served when drainSocketServed: a group member or a configured ingress drain (both as before), or a box armed for PROXY protocol (new). The socket's path and agent-user-only permissions are unchanged. Read sites unchanged (6).;rev3=census-ruling-same-box-edge-fence;basis=Agent (uid carlos), not root. One added line: armEdgeFenceStatus(ctl.EdgeFence), beside the existing armExecSandboxStatus, so the layout report can ask root's /ready for the edge fence state over the control socket client the agent already holds. No read added.;rev3=census-ruling-platform-mail-submission;basis=Task 4: sets eb.Mail = mailsubmit.SocketForwarder{} on every box, and eb.MailSwitch to a mailSwitchCache's On that opens the deploy store itself through openDeployStore, retried at most once a minute with an error line until it opens (review round 1, Task 4 P3), armed for the serial-move refresh (armedMailSwitch). Task 6: also sets the ExecBackend's ManifestOf, the same staged-manifest read as TierOf (rt.App and RouteAccount(rt), hence +registry:App and +whole:Route), for the spawn-time check of decision 10, which logs and emits an event and never refuses. Agent, not root. Fable final P2-2: eb.MailSwitch is the cache's State (three-valued: on, off, unknown) in place of On; an unreadable switch is unknown, never off. No read added.;rev3=census-ruling-fleet-drain-followups;basis=P3 (#1008 T9): one call after armChangeIndex, requestBootFullPass(v, &backstopFullDue), which stores true in the existing in-memory backstopFullDue flag only when no record view is armed, so the fast loop runs its existing full pass on its first tick instead of instancesLoop a minute later; armed boxes unchanged. No read added; read sites unchanged (8); agent, not root.;rev3=census-ruling-fleet-first-reconcile-speed;basis=Startup timing log lines only: runDuties builds a step logger (newStartupLog, which reads the in-memory agent start time) and logs one line after the wait on the activator startup latch and after each existing duty before go fastConvergeLoop. One newStartupLog().at line in the edge ready hook before go tunnelLoop. No read added; read sites unchanged (8). Agent, not root.;rev3=census-ruling-ha-1192;basis=sets the group drain driver's departed hook to armedPeerDeparted (the armed departure controller's PeerDeparted: local registry identity + departure journal); no new read;rev3=census-ruling-replica-wake-gap-r3;basis=Calls lease.SetContinuityDir(<data dir>/.continuity) beside the existing obligation store: the agent's own 0700 directory for clean records, outside every instance tree (#1290 round 3). No new read; failure is logged and every start then takes a full image.;rev3=census-ruling-fleet-restart-wake;basis=Fleet restart wake Task 2: cfg.ReplicaRecord = replicaRecordFacts(boxLifetimes, cfg.Record): hands the existing judged record read (haRecordFacts over openDeployStore and boxJudge) as the live read on a lifetime index miss. No read site added here; agent, not root.;rev3=census-ruling-alias-publish-precert-1293;basis=starts edgesFileLoop with one more argument, edgeAcmeDir(os.Getenv, peekAcmeCache(args)): the agent's own -acme-cache flag (already parsed for domainsLoop) or $CARLOS_DATA_DIR/acme; a string computed from the operator's command line and environment, no read. Same 8 read sites.;rev3=census-ruling-console-addr-from-install;basis=publishes the running edge to consoleFleetEdgeSource for the heartbeat; no read added;rev3=census-ruling-instance-ready-before-wake;basis=the agent as carlos: sets svc.ConfigBeforeWake = configBeforeWake(reg, dd, claims.Writes) beside BeforeExec, before Start. Read sites unchanged, offsets moved. file:Exec@22002,file:Open@2191,file:Statfs@58829,registry:App@13299,registry:App@13677,whole:Route@13291,whole:Route@13669,whole:Route@51925 9e8b2a5a0b91360dbcca3d90817b55349b1f5287bf444bbfff3ed7a1a33ca213
internal/activator/configbeforewake.go Service.configBeforeWake legacy accepted-legacy accepted-legacy;rev3=census-ruling-instance-ready-before-wake;basis=new, the agent as carlos: calls the ConfigBeforeWake hook with the wake route, unless the hook is nil, the wake is a hold swap pinned wake (e.pin) or a fallback second pass (wakeFallbackKey). Reads only in-memory state and the route already in hand. whole:Route@258 6399df728bf3a5703f46d56e0bcda13a3b2490f39b6d9d57637658ef7136e3ec
internal/appconfig/syncexec.go ExecSpawned legacy accepted-legacy accepted-legacy;rev3=census-ruling-instance-ready-before-wake;basis=new, pure: execSyncable or execSidecarCandidate over the route handed in, the sweep own scope test exported for the agent pass before a wake. Reads only that route. whole:Route@64,whole:Route@92 88a6489c054186890d32d32d53da14c222fa2588fc7413e550924bd7417e0396
internal/appconfig/syncexec.go syncExecHostMaking legacy accepted-legacy accepted-legacy;rev3=census-ruling-instance-ready-before-wake;basis=new, the agent as carlos: syncExecHostClaimed, and when the pass asked for it (MakeInstanceDir, set only by the agent own pass before a wake) and the write found no instance directory, os.MkdirAll of provision.InstanceDir(dataDir, host) at 0700, the same call and mode the activator prepare makes at that wake, then the same write once more. A write under /data by the agent, never root. The registry Host and Route reads are the row the pass already holds. registry:Host@607,whole:Route@309,whole:Route@494,whole:Route@683 7aed70f5c1f2cfbf428e1cea4a0f19bd9f5b315bdfb9b2854741b6b56575d60b
internal/host/configbeforewake.go configBeforeWake legacy accepted-legacy accepted-legacy;rev3=census-ruling-instance-ready-before-wake;basis=new, the agent as carlos: the hook runAgent sets. Takes the key and the deploy store from the armed config guard (the same key the config loops parse from CARLOS_SECRETS_KEY) and calls deliverConfigBeforeWake. Does nothing without a guard or a usable key. whole:Route@286 f8f7bf9e9f39049554cffab1069675efffd18f27968bdfad9d582f5f0753528f
-internal/host/configbeforewake.go deliverConfigBeforeWake legacy accepted-legacy accepted-legacy;rev3=census-ruling-instance-ready-before-wake;basis=new, the agent as carlos: for a route config sync delivers a file to (appconfig.ExecSpawned), one os.Lstat of its own config path under /data (appconfig.ConfigEnvPath, never followed or opened). When the file is absent, no pass has settled the host and none was run for it in the last 30s, one SyncExec pass narrowed to that host under configSyncMu, its lock wait and reads bounded by a 5s budget and its config ack by 5s more, with MakeInstanceDir and no restart leg. The registry Host reads are the route the activator handed in. Not reachable from root: only the agent wake path calls it. file:Lstat@270,registry:Host@1129,registry:Host@1212,registry:Host@1266,registry:Host@345,registry:Host@376,whole:Route@238,whole:Route@307 ddf49194e5462476974093322bb4083b3ce646701918a89ba2ba276c69a8c459
+internal/host/configbeforewake.go deliverConfigBeforeWake legacy accepted-legacy accepted-legacy;rev3=census-ruling-instance-ready-before-wake;basis=new, the agent as carlos: for a route config sync delivers a file to (appconfig.ExecSpawned), one os.Lstat of its own config path under /data (appconfig.ConfigEnvPath, never followed or opened). When the file is absent, no pass has settled the host and no attempt ran for it in the last 30s, one SyncExec pass narrowed to that host under configSyncMu, its lock wait and reads bounded by a 5s budget and its config ack by 5s more (so up to about 10s on a box that acks in line), with MakeInstanceDir and no restart leg. The 30s window starts only when an attempt ran: at a store that would not open, or once the lock is held, where the settled and window checks are made again (in-memory, configSettled); a wait for the lock that timed out starts none, so the next wake asks again (census review P3, #280). That change adds one registry Host site (rt.Host handed to the window at the store failure), the route the activator handed in; no file or bucket read is added: the same one Lstat, before the lock. The registry Host reads are the route the activator handed in. Not reachable from root: only the agent wake path calls it. file:Lstat@270,registry:Host@1002,registry:Host@1232,registry:Host@1315,registry:Host@1680,registry:Host@345,registry:Host@383,whole:Route@238,whole:Route@307 63bcbc5945dafd3263864d7b616c36b89d71a401163733fd1cc81b3b10eca206
internal/activator/activator.go Service.doWakeOnce legacy accepted-legacy accepted-legacy;rev3=census-ruling-stateless-replicas-1;basis=Task 3a: The former doWake body, not deleted logic: refresh/admit/fence/layout checks remain. Select and verify the actual staged identity before serving Acquire; use canonical mode to call doStatelessWake. Keep SQLite acquire/restore/seed/marker/replicate only in the stateful arm, with the post-acquisition selection recheck and existing cleanup proofs. Fix 3a round 1 I1/I3a: admit config directly only for stateless and mark runtime ownership refusals. Stateful Acquire/Restore precede selection and pending publication; canonical mode inspection is separate, replan precedes settlement. Fix round 2 N2/N3: retain the original route/pin projection for post-lease declaration checks; reuse the unplanned capture so a live-link repoint cannot change the selected build. Stateful capture and changed-copy errors remain start failures after Acquire/Restore. A failed preliminary verification supplies no cached mode observation. No new file path or database authority. Final review C1/R26: unprojected stateful wakes capture and materialize the live link only after Acquire and Restore. Retain original route/generation/pin stateless evidence on the context across fallback, so missing stateless evidence cannot take stateful recovery inference. Known good stateful identity skips canonical declaration lookup. Existing pre-exec verification remains. R28 final fix 2: carry whether this wake has a plan in attempt-local context; no new read here; route, generation and pin stateless projection remains intact.;rev3=census-ruling-agent-start-demo-1;basis=Reads IsDemo and demo admission/capability state; chooses local lease retention, skips seed upload and sidecar selection. Existing stop and under-lease ordering retained.;rev3=census-ruling-region-ha-p3a;basis=P3a Task 3: refuse tenant starts under the existing service lock before main's demoWakeRefusal, and recheck before backend Acquire. Retain main's demo refusal and all lease, restore and serialization checks. Two added whole Route uses feed the in-memory admission predicate; no new filesystem or store read.;rev3=census-ruling-stateless-replicas-2;basis=P14: after verified storage-mode selection, before clearing the projected hint or acquiring a database lease, a set row still on the stateful branch returns ErrFenced. Reads the existing route FleetBoxes field only. Verified stateless wakes take their existing branch; legacy rows remain unchanged. No new file, registry query or bucket read. merge of origin/main 9b8b2c50: retain wake-slot and HA duty logic alongside the replica stateful-start refusal; no gate removed. merge of origin/main 6be08467: Keep main demo lease, local database and KeepLocal path; never equate replication-disabled demos with stateless generations. Merge-only body/read-site change. merge of origin/main 7920cccf: Retain main tenant admission and startOwnedLocked gates alongside the replica stateful-start refusal; whole Route passed to main admission checks, no new path or store read.;rev3=census-ruling-agent-start-demo-3;basis=Route claim seeds through seed restore/admission; do not fall back to empty boot or ordinary import behavior. Census read-site delta: +registry:SeedSource, +whole:Route.;rev3=census-ruling-region-ha-g2-fixes;basis=Bound recovery Acquire by its attempt deadline; existing acquire/restore/start ordering remains; no new read.;rev3=census-ruling-g6-fence;basis=G6 F-C Task 3, the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): right after retainDatabase returns, attaches the write-fence watcher under a.mu (watchWriteFenceLocked, in memory). retainDatabase is called through a retainDB test seam that is nil in production. No read added; no root call; existing acquire, restore, publisher and cleanup order unchanged.;rev3=census-ruling-sr-followups;basis=#1061 Task 1, the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): a refused plan now returns planRefusal(host, plan) instead of the inline fmt.Errorf, the text is unchanged, and when the planner marked the plan Installing the error also matches errBuildNotInstalled (installRefusal, in memory). Same refusal at the same point before the lease, read sites unchanged, no read, file, store, bucket or root call added;rev3=census-ruling-replica-wake-gap;basis=Step 2c: before the seed and the spawn, asks the lease to ProtectStart(rt.DBPath), the route's own database path already used by Restore and retainDatabase; a refusal gives the lease back and starts nothing. Agent code (user carlos); no root call, no new store or file read here.;rev3=census-ruling-replica-wake-gap-ch;basis=Step 2c's body moved unchanged into protectBeforeStart (replicatebeforestart.go); doWakeOnce passes the whole Route it already holds and returns the error. No read added; the DBPath read moved with the body.;rev3=census-ruling-instance-ready-before-wake;basis=the agent as carlos: one call, step 0.69, a.configBeforeWake(ctx, e, rt), after the held wake check and before the planner. It hands the hook the route this wake already holds (the added whole Route site). It returns nothing, so no refusal, lease, restore or spawn ordering changes. registry:DBPath@2071,registry:DBPath@2087,registry:DBPath@2214,registry:DBPath@2225,registry:FleetBoxes@12276,registry:GoodVersion@18566,registry:Host@1900,registry:Host@1975,registry:Host@2053,registry:Host@2205,registry:Host@2539,registry:Host@4556,registry:Host@6813,registry:Host@949,registry:Replication@17193,registry:Replication@17322,registry:Replication@17341,registry:Replication@17422,registry:Replication@33794,registry:Seed@22478,registry:SeedSource@35254,registry:Socket@2100,registry:Socket@2116,registry:Socket@2239,registry:Socket@2250,registry:Stateless@10336,registry:Stateless@10622,registry:Stateless@11994,registry:Stateless@12324,registry:Stateless@20975,registry:Stateless@9879,registry:Stateless@9970,whole:Route@10408,whole:Route@10567,whole:Route@10946,whole:Route@11044,whole:Route@11135,whole:Route@11267,whole:Route@11390,whole:Route@11444,whole:Route@11716,whole:Route@11892,whole:Route@11896,whole:Route@12683,whole:Route@12958,whole:Route@13276,whole:Route@142,whole:Route@14737,whole:Route@15414,whole:Route@16295,whole:Route@17173,whole:Route@17424,whole:Route@18769,whole:Route@19360,whole:Route@19525,whole:Route@1998,whole:Route@20461,whole:Route@21257,whole:Route@21532,whole:Route@21728,whole:Route@22579,whole:Route@22650,whole:Route@2434,whole:Route@2439,whole:Route@2493,whole:Route@2499,whole:Route@25144,whole:Route@2565,whole:Route@2573,whole:Route@2629,whole:Route@27002,whole:Route@27648,whole:Route@28955,whole:Route@29109,whole:Route@29608,whole:Route@29678,whole:Route@30265,whole:Route@31350,whole:Route@31781,whole:Route@31989,whole:Route@32043,whole:Route@32972,whole:Route@33157,whole:Route@333,whole:Route@33957,whole:Route@34028,whole:Route@34746,whole:Route@34795,whole:Route@35189,whole:Route@35371,whole:Route@3591,whole:Route@36623,whole:Route@36718,whole:Route@3685,whole:Route@3752,whole:Route@37559,whole:Route@4446,whole:Route@6182,whole:Route@6441,whole:Route@6703,whole:Route@6708,whole:Route@6765,whole:Route@6771,whole:Route@6840,whole:Route@6848,whole:Route@7164,whole:Route@7225,whole:Route@729,whole:Route@7323,whole:Route@7633,whole:Route@8534,whole:Route@934,whole:Route@9483,whole:Route@9707,whole:Route@9771,whole:Route@9815 72ca438f2e11c7a6eb14e09c895b481898b0162c786180e1c3fc61272b3392ce
@coverage internal/activator f57026b611e24808473a4f3a71707b727ea36f279716857d68f77288adb3310e
-@coverage internal/appconfig 5ac824d09961ef4a173db8017d74021da8a08d6d48051eb77f0a8aaac32c0638
-@coverage internal/host 82b4b1bbf9a9ff80c5f110f1f202d7fca32090d17656e6443983f127e1dc6cc1
+@coverage internal/appconfig 14dfd320d677064e2b5713d02e1282bb92cdf391bf928ef11947ec821a3c2cc3
+@coverage internal/host 0bddb2e2a64b7d28ac355dc09c2aa4804ca5e5faae0b385fb5ab7f0d52f1f555