Commit dd1e72b
feat(resync): notify a live agent when a declared resource carrier changes (#345)
* feat(agent-spec): accept catalog-relative resource carrier URIs
A resource binding uri may now be a scheme-less relative path, resolved by
the consumer against the declaration directory. Absolute URIs keep the
existing validation. This is the carrier form declaratively managed goal
files need (docs/vrs/06-resync); it is an st2 extension pending canonical
Agent Spec adoption.
agent-identity: unknown
agent-persona: generalist
agent-supervisor: unavailable
agent-tool: OMP
agent-tool-version: 18.0.3
agent-runtime: OMP 18.0.3
tooling-profile: dotfiles@a80129b-dirty
* feat(resync): notify a live agent when a declared resource carrier changes
Implements #341. The supervisor watches each running agent's local resource
carriers (file:// and catalog-relative bindings plus its own declaration),
classifies them (immediate / silent / coalesced), and emits digest-keyed,
superseded events through a built-in reserved `resync` stream on the
unchanged event-stream ingress. Equal-byte rewrites never wake; bursts
coalesce per class window.
Design decisions: docs/vrs/.decisions/0008; subsystem VRS: docs/vrs/06-resync.
agent-identity: unknown
agent-persona: generalist
agent-supervisor: unavailable
agent-tool: OMP
agent-tool-version: 18.0.3
agent-runtime: OMP 18.0.3
tooling-profile: dotfiles@a80129b-dirty
* fix(resync): preserve in-flight carrier state across watch-set refreshes
A reconcile pass can land between a carrier mutation and its flush window
(agent.kdl changes wake reconcile immediately). Reseeding digests on every
watch-set application silently erased that pending event; carriers already on
record now keep their digest and dirty state, and only genuinely unknown
paths seed silently.
agent-identity: unknown
agent-persona: generalist
agent-supervisor: unavailable
agent-tool: OMP
agent-tool-version: 18.0.3
agent-runtime: OMP 18.0.3
tooling-profile: dotfiles@a80129b-dirty
* docs(vrs): record resync refresh-race discovery in the composition experiment
agent-identity: unknown
agent-persona: generalist
agent-supervisor: unavailable
agent-tool: OMP
agent-tool-version: 18.0.3
agent-runtime: OMP 18.0.3
tooling-profile: dotfiles@a80129b-dirty
* fix(resync): address Codex review findings
- run: restore unpark report merging and the crash-loop dedup reset in the
supervisor loop, lost when the resync wiring landed
- resync: derive the event identity from the whole transition
(previous digest -> new digest), so an A->B->A oscillation re-notifies on
the rollback leg instead of colliding with B's original identity
- resync: resolve bus ids with the supervisor's logical host, so hostless
declarations supervised under `st2 up --host <alias>` produce recipients
the ingress can actually resolve
- resync: retain every subscriber of a shared carrier path; several agents
binding one file each get their own event
- resync: carriers whose parent directory cannot be registered fall back to
digest polling at refresh cadence instead of being watched by nobody
agent-identity: unknown
agent-persona: generalist
agent-supervisor: unavailable
agent-tool: OMP
agent-tool-version: 18.0.3
agent-runtime: OMP 18.0.3
tooling-profile: dotfiles@a80129b-dirty
* test(codex): wait for parsable pidfile content in process-group cleanup test
The shell's > redirection creates an empty pidfile before printf writes,
so polling is_file() can observe an empty file under CI load and panic
with ParseIntError::Empty. Poll for parseable content instead.
agent-identity: unknown
agent-persona: generalist
agent-supervisor: unavailable
agent-tool: OMP
agent-tool-version: 18.0.3
agent-runtime: OMP 18.0.3
tooling-profile: dotfiles@a80129b-dirty
* fix(resync): preserve subscriber event identity
* docs(resync): align event identity contract
* fix(resync): retry publication and tighten carriers
* fix(resync): close watch and carrier gaps
* fix(resync): watch only proven live seats
* fix(resync): preserve live watch state atomically
* fix(resync): replay exact transitions with bounded hashing
* fix(resync): preserve fallback lifecycle semantics
* fix: normalize and refresh resync subscriptions
* fix(resync): preserve transitions across metadata refresh
* fix(resync): namespace transition occurrences
* fix: retain resync occurrence state across suspension
* fix(resync): stabilize subscriptions across relocation
* fix: restrict resync event ingress to supervisor
* fix: seed resync watches at live-seat transitions
* fix: isolate generated task compile failures
* fix resync carrier validation and live watches
* fix(resync): close review lifecycle gaps
---------
Co-authored-by: Johannes Schickling <schickling.j@gmail.com>1 parent 2167ef3 commit dd1e72b
16 files changed
Lines changed: 4268 additions & 52 deletions
File tree
- crates/agent-spec
- src
- tests
- docs/vrs
- .decisions
- 06-resync
- .experiments
- src
- tests
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
256 | 256 | | |
257 | 257 | | |
258 | 258 | | |
259 | | - | |
260 | | - | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
261 | 271 | | |
262 | | - | |
263 | | - | |
| 272 | + | |
| 273 | + | |
264 | 274 | | |
265 | 275 | | |
266 | 276 | | |
| |||
585 | 595 | | |
586 | 596 | | |
587 | 597 | | |
| 598 | + | |
| 599 | + | |
| 600 | + | |
| 601 | + | |
588 | 602 | | |
589 | 603 | | |
590 | 604 | | |
| |||
764 | 778 | | |
765 | 779 | | |
766 | 780 | | |
| 781 | + | |
| 782 | + | |
| 783 | + | |
| 784 | + | |
| 785 | + | |
| 786 | + | |
| 787 | + | |
| 788 | + | |
| 789 | + | |
| 790 | + | |
| 791 | + | |
| 792 | + | |
| 793 | + | |
| 794 | + | |
| 795 | + | |
| 796 | + | |
| 797 | + | |
| 798 | + | |
| 799 | + | |
| 800 | + | |
| 801 | + | |
| 802 | + | |
| 803 | + | |
| 804 | + | |
| 805 | + | |
| 806 | + | |
| 807 | + | |
| 808 | + | |
| 809 | + | |
| 810 | + | |
| 811 | + | |
| 812 | + | |
| 813 | + | |
| 814 | + | |
| 815 | + | |
| 816 | + | |
| 817 | + | |
| 818 | + | |
| 819 | + | |
| 820 | + | |
| 821 | + | |
| 822 | + | |
| 823 | + | |
| 824 | + | |
| 825 | + | |
| 826 | + | |
| 827 | + | |
| 828 | + | |
| 829 | + | |
| 830 | + | |
| 831 | + | |
| 832 | + | |
| 833 | + | |
| 834 | + | |
| 835 | + | |
| 836 | + | |
| 837 | + | |
| 838 | + | |
| 839 | + | |
| 840 | + | |
| 841 | + | |
| 842 | + | |
| 843 | + | |
| 844 | + | |
| 845 | + | |
| 846 | + | |
| 847 | + | |
| 848 | + | |
| 849 | + | |
| 850 | + | |
| 851 | + | |
| 852 | + | |
| 853 | + | |
| 854 | + | |
| 855 | + | |
| 856 | + | |
| 857 | + | |
| 858 | + | |
| 859 | + | |
| 860 | + | |
| 861 | + | |
767 | 862 | | |
768 | 863 | | |
769 | 864 | | |
| |||
1360 | 1455 | | |
1361 | 1456 | | |
1362 | 1457 | | |
| 1458 | + | |
| 1459 | + | |
| 1460 | + | |
| 1461 | + | |
| 1462 | + | |
| 1463 | + | |
| 1464 | + | |
| 1465 | + | |
| 1466 | + | |
| 1467 | + | |
| 1468 | + | |
| 1469 | + | |
| 1470 | + | |
| 1471 | + | |
| 1472 | + | |
| 1473 | + | |
| 1474 | + | |
| 1475 | + | |
| 1476 | + | |
| 1477 | + | |
| 1478 | + | |
| 1479 | + | |
| 1480 | + | |
| 1481 | + | |
| 1482 | + | |
| 1483 | + | |
| 1484 | + | |
| 1485 | + | |
| 1486 | + | |
1363 | 1487 | | |
1364 | 1488 | | |
1365 | 1489 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1134 | 1134 | | |
1135 | 1135 | | |
1136 | 1136 | | |
| 1137 | + | |
| 1138 | + | |
| 1139 | + | |
| 1140 | + | |
| 1141 | + | |
| 1142 | + | |
| 1143 | + | |
| 1144 | + | |
| 1145 | + | |
| 1146 | + | |
| 1147 | + | |
| 1148 | + | |
| 1149 | + | |
| 1150 | + | |
| 1151 | + | |
| 1152 | + | |
| 1153 | + | |
| 1154 | + | |
| 1155 | + | |
| 1156 | + | |
| 1157 | + | |
| 1158 | + | |
| 1159 | + | |
| 1160 | + | |
1137 | 1161 | | |
1138 | 1162 | | |
1139 | 1163 | | |
| |||
1148 | 1172 | | |
1149 | 1173 | | |
1150 | 1174 | | |
1151 | | - | |
1152 | | - | |
1153 | | - | |
1154 | | - | |
1155 | 1175 | | |
1156 | 1176 | | |
1157 | 1177 | | |
| |||
1170 | 1190 | | |
1171 | 1191 | | |
1172 | 1192 | | |
1173 | | - | |
| 1193 | + | |
1174 | 1194 | | |
1175 | 1195 | | |
1176 | 1196 | | |
| |||
1186 | 1206 | | |
1187 | 1207 | | |
1188 | 1208 | | |
1189 | | - | |
1190 | | - | |
1191 | | - | |
1192 | | - | |
1193 | | - | |
1194 | | - | |
1195 | 1209 | | |
1196 | 1210 | | |
1197 | 1211 | | |
| |||
1204 | 1218 | | |
1205 | 1219 | | |
1206 | 1220 | | |
| 1221 | + | |
| 1222 | + | |
| 1223 | + | |
| 1224 | + | |
| 1225 | + | |
| 1226 | + | |
| 1227 | + | |
| 1228 | + | |
| 1229 | + | |
| 1230 | + | |
| 1231 | + | |
| 1232 | + | |
| 1233 | + | |
| 1234 | + | |
| 1235 | + | |
| 1236 | + | |
| 1237 | + | |
| 1238 | + | |
| 1239 | + | |
| 1240 | + | |
| 1241 | + | |
| 1242 | + | |
| 1243 | + | |
| 1244 | + | |
| 1245 | + | |
| 1246 | + | |
| 1247 | + | |
| 1248 | + | |
| 1249 | + | |
| 1250 | + | |
| 1251 | + | |
| 1252 | + | |
| 1253 | + | |
| 1254 | + | |
| 1255 | + | |
| 1256 | + | |
| 1257 | + | |
| 1258 | + | |
| 1259 | + | |
| 1260 | + | |
| 1261 | + | |
| 1262 | + | |
| 1263 | + | |
| 1264 | + | |
| 1265 | + | |
| 1266 | + | |
| 1267 | + | |
| 1268 | + | |
| 1269 | + | |
| 1270 | + | |
| 1271 | + | |
| 1272 | + | |
| 1273 | + | |
| 1274 | + | |
| 1275 | + | |
| 1276 | + | |
| 1277 | + | |
| 1278 | + | |
| 1279 | + | |
| 1280 | + | |
| 1281 | + | |
| 1282 | + | |
| 1283 | + | |
| 1284 | + | |
| 1285 | + | |
| 1286 | + | |
| 1287 | + | |
| 1288 | + | |
| 1289 | + | |
| 1290 | + | |
| 1291 | + | |
| 1292 | + | |
| 1293 | + | |
| 1294 | + | |
| 1295 | + | |
| 1296 | + | |
| 1297 | + | |
| 1298 | + | |
| 1299 | + | |
| 1300 | + | |
| 1301 | + | |
| 1302 | + | |
| 1303 | + | |
| 1304 | + | |
| 1305 | + | |
| 1306 | + | |
| 1307 | + | |
| 1308 | + | |
| 1309 | + | |
| 1310 | + | |
| 1311 | + | |
| 1312 | + | |
| 1313 | + | |
| 1314 | + | |
| 1315 | + | |
| 1316 | + | |
| 1317 | + | |
| 1318 | + | |
| 1319 | + | |
| 1320 | + | |
| 1321 | + | |
| 1322 | + | |
| 1323 | + | |
| 1324 | + | |
| 1325 | + | |
| 1326 | + | |
| 1327 | + | |
| 1328 | + | |
| 1329 | + | |
| 1330 | + | |
| 1331 | + | |
| 1332 | + | |
| 1333 | + | |
| 1334 | + | |
| 1335 | + | |
| 1336 | + | |
| 1337 | + | |
| 1338 | + | |
| 1339 | + | |
| 1340 | + | |
| 1341 | + | |
| 1342 | + | |
| 1343 | + | |
| 1344 | + | |
| 1345 | + | |
| 1346 | + | |
| 1347 | + | |
| 1348 | + | |
| 1349 | + | |
| 1350 | + | |
| 1351 | + | |
| 1352 | + | |
| 1353 | + | |
| 1354 | + | |
| 1355 | + | |
| 1356 | + | |
| 1357 | + | |
| 1358 | + | |
| 1359 | + | |
| 1360 | + | |
1207 | 1361 | | |
1208 | 1362 | | |
1209 | 1363 | | |
| |||
1233 | 1387 | | |
1234 | 1388 | | |
1235 | 1389 | | |
1236 | | - | |
| 1390 | + | |
1237 | 1391 | | |
1238 | 1392 | | |
1239 | 1393 | | |
| |||
0 commit comments