Repository navigation
Description
Summary
spawn extend moves spawn:ttl-deadline but leaves spawn:ttl at the value it was launched with, in the same CreateTags call. The extension is real and correct — but it is invisible to anyone (or anything) that verifies by reading spawn:ttl, and afterwards the two tags describe different deadlines.
Distinct from #502 (IAM/baseline policy) and #505 (reload reporting success when the on-instance refresh failed). This one is purely about which tags extend writes.
Evidence
Seven c8g.48xlarge launched with --ttl 8h, then spawn extend <id> 8h twice per instance. CloudTrail CreateTags, us-east-1, account 942542972736:
# at launch (RunInstances tagSpecificationSet)
2026-08-17T22:25:59Z biosurf-dipfix-s0 {'spawn:ttl': '8h', 'spawn:ttl-deadline': '2026-08-18T06:25:57Z'}
# spawn extend i-03a29c216d46c3b86 8h (round 1)
2026-08-18T05:04:40Z i-03a29c216d46c3b86 {'spawn:ttl': '8h', 'spawn:ttl-deadline': '2026-08-18T14:25:57Z'}
# spawn extend i-03a29c216d46c3b86 8h (round 2)
2026-08-18T05:59:21Z i-03a29c216d46c3b86 {'spawn:ttl': '8h', 'spawn:ttl-deadline': '2026-08-18T22:25:57Z'}
spawn:ttl-deadline advances 06:25 → 14:25 → 22:25 exactly as documented. spawn:ttl is rewritten to 8h each time — the launch value, not the effective one. All seven instances behave identically:
| Name | Instance | LaunchTime | spawn:ttl after 2 extends |
spawn:ttl-deadline |
|---|---|---|---|---|
| biosurf-dipfix-s0 | i-03a29c216d46c3b86 |
2026-08-17T22:25:58Z | 8h |
2026-08-18T22:25:57Z |
| biosurf-dipfix-s1 | i-08efa17ed1bb2f099 |
22:30:36Z | 8h |
22:30:35Z |
| biosurf-dipfix-s2 | i-08b9ad516db6dd2fe |
22:35:14Z | 8h |
22:35:13Z |
| biosurf-dipfix-s3 | i-03c73299d8b91b416 |
22:39:53Z | 8h |
22:39:51Z |
| biosurf-dipfix-s4 | i-0d79af36b80961170 |
22:44:31Z | 8h |
22:44:29Z |
| biosurf-dipfix-s5 | i-05c34d471ee84e2db |
22:49:09Z | 8h |
22:49:08Z |
| biosurf-dipfix-s6 | i-03ebed621d8799f31 |
22:53:46Z | 8h |
22:53:45Z |
There is also no breadcrumb that an extension happened: no spawn:ttl-extended-at, no spawn:stop-at.
Why it bit
A 7-node DFT fleet, ~$54/h, jobs needing another ~5h. spawn extend … 8h printed Configuration reloaded on instance ✓ on all seven, so I checked the effect rather than trusting the message — and checked spawn:ttl, spawn:stop-at, spawn:ttl-extended-at. All unchanged, none present. I concluded extend was a silent no-op, computed LaunchTime + spawn:ttl = 06:25–06:53Z, and believed I had ~20 minutes before four in-flight multi-hour runs were killed. The correct deadline was 16 hours away. The extension had worked twice; only the tag I checked hadn't moved.
LaunchTime + spawn:ttl is the obvious derivation for any external monitor, and after an extend it is wrong by exactly the amount extended.
Two further consequences:
- After fix: attach spored baseline policy unconditionally on every instance role #503 heals a role, an on-instance spored that resolves its deadline from
spawn:ttlgets the pre-extension deadline. If that deadline is already in the past — the ordinary case for a long-running instance whose TTL has been extended a few times — the first successful config load terminates an instance the user has explicitly extended. Worth checking which of the two keys spored treats as authoritative before fix: attach spored baseline policy unconditionally on every instance role #503 rolls out widely. spawn statusrenders the tag-derived deadline, so the CLI and the tags disagree with each other about the same instance (filed separately).
Suggested fix
Make one key authoritative and the other derived, and never let the pair disagree. Either:
- write the effective total to
spawn:ttlon extend (8h→16h→24h), soLaunchTime + spawn:ttl == spawn:ttl-deadlineis an invariant a monitor can rely on; or - drop
spawn:ttlafter launch and treatspawn:ttl-deadlineas the only deadline of record, so there is nothing stale to read.
Either way, a spawn:ttl-extended-at (and ideally spawn:ttl-extended-by) breadcrumb makes an extension visible to an operator auditing tags, which is what I was trying to do.
Environment
- spawn: v0.100.1 (Homebrew, macOS arm64); spored on the instances: v0.100.0
- Region us-east-1, account 942542972736,
c8g.48xlarge, launched viaspawn launch … --ttl 8h --iam-policy-file …
Activity
scttfrdmn commentedon Aug 18, 2026
Duplicate of #506, which has the same finding with source-level detail I didn't have (cmd/extend.go's own
instance.TTLfallback, and cmd/state.go's stop/start remaining-TTL computation reading the wrong tag — that second consequence is worse than anything I reported). Field evidence from this report moved to #506 as a comment. Closing in favour of #506.#508 (spawn status presenting
TTL: none — instance will not auto-terminateand aTermination deadlinein the same screen, from two unreconciled sources, plus Started/Elapsed describing the CLI invocation rather than the instance) is a separate rendering bug and stays open.