@claudexor/daemon 3.25.1 → 4.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (453) hide show
  1. package/dist/account-resets.d.ts +2 -2
  2. package/dist/account-resets.d.ts.map +1 -1
  3. package/dist/account-resets.js +15 -0
  4. package/dist/account-resets.js.map +1 -1
  5. package/dist/client.d.ts +25 -6
  6. package/dist/client.d.ts.map +1 -1
  7. package/dist/client.js +55 -51
  8. package/dist/client.js.map +1 -1
  9. package/dist/command-authority.d.ts +11 -8
  10. package/dist/command-authority.d.ts.map +1 -1
  11. package/dist/command-authority.js +5 -6
  12. package/dist/command-authority.js.map +1 -1
  13. package/dist/command-list-projection.d.ts +0 -1
  14. package/dist/command-list-projection.d.ts.map +1 -1
  15. package/dist/command-list-projection.js +0 -6
  16. package/dist/command-list-projection.js.map +1 -1
  17. package/dist/command-list-select.d.ts +0 -4
  18. package/dist/command-list-select.d.ts.map +1 -1
  19. package/dist/command-list-select.js +1 -115
  20. package/dist/command-list-select.js.map +1 -1
  21. package/dist/command-retention.d.ts +7 -19
  22. package/dist/command-retention.d.ts.map +1 -1
  23. package/dist/command-retention.js +1 -120
  24. package/dist/command-retention.js.map +1 -1
  25. package/dist/command-rpc.d.ts +4 -1
  26. package/dist/command-rpc.d.ts.map +1 -1
  27. package/dist/command-rpc.js +12 -1
  28. package/dist/command-rpc.js.map +1 -1
  29. package/dist/command-store.d.ts +15 -52
  30. package/dist/command-store.d.ts.map +1 -1
  31. package/dist/command-store.js +5 -493
  32. package/dist/command-store.js.map +1 -1
  33. package/dist/daemon-health.d.ts +56 -8
  34. package/dist/daemon-health.d.ts.map +1 -1
  35. package/dist/daemon-health.js +44 -9
  36. package/dist/daemon-health.js.map +1 -1
  37. package/dist/daemon-local-client.d.ts +28 -0
  38. package/dist/daemon-local-client.d.ts.map +1 -0
  39. package/dist/daemon-local-client.js +55 -0
  40. package/dist/daemon-local-client.js.map +1 -0
  41. package/dist/delivery-command.d.ts +4 -4
  42. package/dist/delivery-command.d.ts.map +1 -1
  43. package/dist/delivery-command.js.map +1 -1
  44. package/dist/index.d.ts +23 -8
  45. package/dist/index.d.ts.map +1 -1
  46. package/dist/index.js +25 -8
  47. package/dist/index.js.map +1 -1
  48. package/dist/interactions.d.ts +12 -28
  49. package/dist/interactions.d.ts.map +1 -1
  50. package/dist/interactions.js +22 -123
  51. package/dist/interactions.js.map +1 -1
  52. package/dist/job-admission.d.ts +26 -0
  53. package/dist/job-admission.d.ts.map +1 -0
  54. package/dist/job-admission.js +67 -0
  55. package/dist/job-admission.js.map +1 -0
  56. package/dist/journal-fold-policy.d.ts +1 -1
  57. package/dist/journal-fold-policy.d.ts.map +1 -1
  58. package/dist/journal-recovery-files.d.ts +1 -41
  59. package/dist/journal-recovery-files.d.ts.map +1 -1
  60. package/dist/journal-recovery-files.js +2 -340
  61. package/dist/journal-recovery-files.js.map +1 -1
  62. package/dist/loop-facts.d.ts +28 -0
  63. package/dist/loop-facts.d.ts.map +1 -0
  64. package/dist/loop-facts.js +97 -0
  65. package/dist/loop-facts.js.map +1 -0
  66. package/dist/memory-facts.d.ts +2 -0
  67. package/dist/memory-facts.d.ts.map +1 -1
  68. package/dist/memory-facts.js +5 -0
  69. package/dist/memory-facts.js.map +1 -1
  70. package/dist/model-operations.d.ts +11 -4
  71. package/dist/model-operations.d.ts.map +1 -1
  72. package/dist/model-operations.js +68 -38
  73. package/dist/model-operations.js.map +1 -1
  74. package/dist/operator-decisions.d.ts +15 -25
  75. package/dist/operator-decisions.d.ts.map +1 -1
  76. package/dist/operator-decisions.js +5 -84
  77. package/dist/operator-decisions.js.map +1 -1
  78. package/dist/projects.d.ts +42 -41
  79. package/dist/projects.d.ts.map +1 -1
  80. package/dist/projects.js +46 -184
  81. package/dist/projects.js.map +1 -1
  82. package/dist/quota-registry-replay.d.ts +2 -2
  83. package/dist/quota-registry-replay.d.ts.map +1 -1
  84. package/dist/quota-registry-replay.js.map +1 -1
  85. package/dist/quota-registry-support.d.ts +4 -1
  86. package/dist/quota-registry-support.d.ts.map +1 -1
  87. package/dist/quota-registry-support.js +15 -2
  88. package/dist/quota-registry-support.js.map +1 -1
  89. package/dist/quota-registry.d.ts +64 -2
  90. package/dist/quota-registry.d.ts.map +1 -1
  91. package/dist/quota-registry.js +10 -3
  92. package/dist/quota-registry.js.map +1 -1
  93. package/dist/quota-resources.d.ts +6 -3
  94. package/dist/quota-resources.d.ts.map +1 -1
  95. package/dist/quota-resources.js +25 -8
  96. package/dist/quota-resources.js.map +1 -1
  97. package/dist/runless-turn-recovery.d.ts +2 -9
  98. package/dist/runless-turn-recovery.d.ts.map +1 -1
  99. package/dist/runless-turn-recovery.js +0 -14
  100. package/dist/runless-turn-recovery.js.map +1 -1
  101. package/dist/server.d.ts +23 -22
  102. package/dist/server.d.ts.map +1 -1
  103. package/dist/server.js +74 -84
  104. package/dist/server.js.map +1 -1
  105. package/dist/store/blob-files.d.ts +71 -0
  106. package/dist/store/blob-files.d.ts.map +1 -0
  107. package/dist/store/blob-files.js +160 -0
  108. package/dist/store/blob-files.js.map +1 -0
  109. package/dist/store/command-prune.d.ts +37 -0
  110. package/dist/store/command-prune.d.ts.map +1 -0
  111. package/dist/store/command-prune.js +123 -0
  112. package/dist/store/command-prune.js.map +1 -0
  113. package/dist/store/command-queries.d.ts +41 -0
  114. package/dist/store/command-queries.d.ts.map +1 -0
  115. package/dist/store/command-queries.js +186 -0
  116. package/dist/store/command-queries.js.map +1 -0
  117. package/dist/store/command-rows.d.ts +66 -0
  118. package/dist/store/command-rows.d.ts.map +1 -0
  119. package/dist/store/command-rows.js +141 -0
  120. package/dist/store/command-rows.js.map +1 -0
  121. package/dist/store/commands.d.ts +49 -0
  122. package/dist/store/commands.d.ts.map +1 -0
  123. package/dist/store/commands.js +247 -0
  124. package/dist/store/commands.js.map +1 -0
  125. package/dist/store/cursors.d.ts +33 -0
  126. package/dist/store/cursors.d.ts.map +1 -0
  127. package/dist/store/cursors.js +82 -0
  128. package/dist/store/cursors.js.map +1 -0
  129. package/dist/store/engine-recovery-files.d.ts +14 -0
  130. package/dist/store/engine-recovery-files.d.ts.map +1 -0
  131. package/dist/store/engine-recovery-files.js +53 -0
  132. package/dist/store/engine-recovery-files.js.map +1 -0
  133. package/dist/store/engine-state-recovery.d.ts +71 -0
  134. package/dist/store/engine-state-recovery.d.ts.map +1 -0
  135. package/dist/store/engine-state-recovery.js +318 -0
  136. package/dist/store/engine-state-recovery.js.map +1 -0
  137. package/dist/store/errors.d.ts +80 -0
  138. package/dist/store/errors.d.ts.map +1 -0
  139. package/dist/store/errors.js +130 -0
  140. package/dist/store/errors.js.map +1 -0
  141. package/dist/store/event-store.d.ts +52 -0
  142. package/dist/store/event-store.d.ts.map +1 -0
  143. package/dist/store/event-store.js +117 -0
  144. package/dist/store/event-store.js.map +1 -0
  145. package/dist/store/external-files.d.ts +40 -0
  146. package/dist/store/external-files.d.ts.map +1 -0
  147. package/dist/store/external-files.js +90 -0
  148. package/dist/store/external-files.js.map +1 -0
  149. package/dist/store/flusher-protocol.d.ts +82 -0
  150. package/dist/store/flusher-protocol.d.ts.map +1 -0
  151. package/dist/store/flusher-protocol.js +23 -0
  152. package/dist/store/flusher-protocol.js.map +1 -0
  153. package/dist/store/flusher-worker.d.ts +24 -0
  154. package/dist/store/flusher-worker.d.ts.map +1 -0
  155. package/dist/store/flusher-worker.js +185 -0
  156. package/dist/store/flusher-worker.js.map +1 -0
  157. package/dist/store/flusher.d.ts +87 -0
  158. package/dist/store/flusher.d.ts.map +1 -0
  159. package/dist/store/flusher.js +264 -0
  160. package/dist/store/flusher.js.map +1 -0
  161. package/dist/store/generations.d.ts +43 -0
  162. package/dist/store/generations.d.ts.map +1 -0
  163. package/dist/store/generations.js +143 -0
  164. package/dist/store/generations.js.map +1 -0
  165. package/dist/store/idempotency.d.ts +25 -0
  166. package/dist/store/idempotency.d.ts.map +1 -0
  167. package/dist/store/idempotency.js +53 -0
  168. package/dist/store/idempotency.js.map +1 -0
  169. package/dist/store/import-context.d.ts +22 -0
  170. package/dist/store/import-context.d.ts.map +1 -0
  171. package/dist/store/import-context.js +87 -0
  172. package/dist/store/import-context.js.map +1 -0
  173. package/dist/store/import-discovery.d.ts +6 -0
  174. package/dist/store/import-discovery.d.ts.map +1 -0
  175. package/dist/store/import-discovery.js +66 -0
  176. package/dist/store/import-discovery.js.map +1 -0
  177. package/dist/store/import-records.d.ts +6 -0
  178. package/dist/store/import-records.d.ts.map +1 -0
  179. package/dist/store/import-records.js +191 -0
  180. package/dist/store/import-records.js.map +1 -0
  181. package/dist/store/import-resources.d.ts +14 -0
  182. package/dist/store/import-resources.d.ts.map +1 -0
  183. package/dist/store/import-resources.js +197 -0
  184. package/dist/store/import-resources.js.map +1 -0
  185. package/dist/store/import-source.d.ts +24 -0
  186. package/dist/store/import-source.d.ts.map +1 -0
  187. package/dist/store/import-source.js +65 -0
  188. package/dist/store/import-source.js.map +1 -0
  189. package/dist/store/import-verify.d.ts +6 -0
  190. package/dist/store/import-verify.d.ts.map +1 -0
  191. package/dist/store/import-verify.js +97 -0
  192. package/dist/store/import-verify.js.map +1 -0
  193. package/dist/store/import-worker.d.ts +18 -0
  194. package/dist/store/import-worker.d.ts.map +1 -0
  195. package/dist/store/import-worker.js +69 -0
  196. package/dist/store/import-worker.js.map +1 -0
  197. package/dist/store/importer.d.ts +42 -0
  198. package/dist/store/importer.d.ts.map +1 -0
  199. package/dist/store/importer.js +239 -0
  200. package/dist/store/importer.js.map +1 -0
  201. package/dist/store/interactions.d.ts +22 -0
  202. package/dist/store/interactions.d.ts.map +1 -0
  203. package/dist/store/interactions.js +82 -0
  204. package/dist/store/interactions.js.map +1 -0
  205. package/dist/store/legacy-journal/frame-codec.d.ts +94 -0
  206. package/dist/store/legacy-journal/frame-codec.d.ts.map +1 -0
  207. package/dist/store/legacy-journal/frame-codec.js +352 -0
  208. package/dist/store/legacy-journal/frame-codec.js.map +1 -0
  209. package/dist/store/legacy-journal/frame-reader.d.ts +30 -0
  210. package/dist/store/legacy-journal/frame-reader.d.ts.map +1 -0
  211. package/dist/store/legacy-journal/frame-reader.js +97 -0
  212. package/dist/store/legacy-journal/frame-reader.js.map +1 -0
  213. package/dist/store/legacy-journal/journal-fold.d.ts +47 -0
  214. package/dist/store/legacy-journal/journal-fold.d.ts.map +1 -0
  215. package/dist/store/legacy-journal/journal-fold.js +81 -0
  216. package/dist/store/legacy-journal/journal-fold.js.map +1 -0
  217. package/dist/store/legacy-journal/journal-partition.d.ts +2 -0
  218. package/dist/store/legacy-journal/journal-partition.d.ts.map +1 -0
  219. package/dist/store/legacy-journal/journal-partition.js +10 -0
  220. package/dist/store/legacy-journal/journal-partition.js.map +1 -0
  221. package/dist/store/legacy-journal/read-only-preparation.d.ts +48 -0
  222. package/dist/store/legacy-journal/read-only-preparation.d.ts.map +1 -0
  223. package/dist/store/legacy-journal/read-only-preparation.js +430 -0
  224. package/dist/store/legacy-journal/read-only-preparation.js.map +1 -0
  225. package/dist/store/maintenance-worker.d.ts +5 -0
  226. package/dist/store/maintenance-worker.d.ts.map +1 -0
  227. package/dist/store/maintenance-worker.js +175 -0
  228. package/dist/store/maintenance-worker.js.map +1 -0
  229. package/dist/store/maintenance.d.ts +124 -0
  230. package/dist/store/maintenance.d.ts.map +1 -0
  231. package/dist/store/maintenance.js +197 -0
  232. package/dist/store/maintenance.js.map +1 -0
  233. package/dist/store/mutation.d.ts +34 -0
  234. package/dist/store/mutation.d.ts.map +1 -0
  235. package/dist/store/mutation.js +85 -0
  236. package/dist/store/mutation.js.map +1 -0
  237. package/dist/store/obligations.d.ts +101 -0
  238. package/dist/store/obligations.d.ts.map +1 -0
  239. package/dist/store/obligations.js +226 -0
  240. package/dist/store/obligations.js.map +1 -0
  241. package/dist/store/operator-decisions.d.ts +23 -0
  242. package/dist/store/operator-decisions.d.ts.map +1 -0
  243. package/dist/store/operator-decisions.js +68 -0
  244. package/dist/store/operator-decisions.js.map +1 -0
  245. package/dist/store/owner-generations.d.ts +33 -0
  246. package/dist/store/owner-generations.d.ts.map +1 -0
  247. package/dist/store/owner-generations.js +63 -0
  248. package/dist/store/owner-generations.js.map +1 -0
  249. package/dist/store/partitions.d.ts +37 -0
  250. package/dist/store/partitions.d.ts.map +1 -0
  251. package/dist/store/partitions.js +68 -0
  252. package/dist/store/partitions.js.map +1 -0
  253. package/dist/store/pragmas.d.ts +32 -0
  254. package/dist/store/pragmas.d.ts.map +1 -0
  255. package/dist/store/pragmas.js +65 -0
  256. package/dist/store/pragmas.js.map +1 -0
  257. package/dist/store/project-router.d.ts +325 -0
  258. package/dist/store/project-router.d.ts.map +1 -0
  259. package/dist/store/project-router.js +298 -0
  260. package/dist/store/project-router.js.map +1 -0
  261. package/dist/store/projects.d.ts +36 -0
  262. package/dist/store/projects.d.ts.map +1 -0
  263. package/dist/store/projects.js +238 -0
  264. package/dist/store/projects.js.map +1 -0
  265. package/dist/store/publish-blob.d.ts +20 -0
  266. package/dist/store/publish-blob.d.ts.map +1 -0
  267. package/dist/store/publish-blob.js +158 -0
  268. package/dist/store/publish-blob.js.map +1 -0
  269. package/dist/store/purge-files.d.ts +30 -0
  270. package/dist/store/purge-files.d.ts.map +1 -0
  271. package/dist/store/purge-files.js +79 -0
  272. package/dist/store/purge-files.js.map +1 -0
  273. package/dist/store/resource-rows.d.ts +40 -0
  274. package/dist/store/resource-rows.d.ts.map +1 -0
  275. package/dist/store/resource-rows.js +103 -0
  276. package/dist/store/resource-rows.js.map +1 -0
  277. package/dist/store/resources.d.ts +67 -0
  278. package/dist/store/resources.d.ts.map +1 -0
  279. package/dist/store/resources.js +147 -0
  280. package/dist/store/resources.js.map +1 -0
  281. package/dist/store/retention.d.ts +95 -0
  282. package/dist/store/retention.d.ts.map +1 -0
  283. package/dist/store/retention.js +173 -0
  284. package/dist/store/retention.js.map +1 -0
  285. package/dist/store/run-events.d.ts +14 -0
  286. package/dist/store/run-events.d.ts.map +1 -0
  287. package/dist/store/run-events.js +35 -0
  288. package/dist/store/run-events.js.map +1 -0
  289. package/dist/store/runtime.d.ts +24 -0
  290. package/dist/store/runtime.d.ts.map +1 -0
  291. package/dist/store/runtime.js +67 -0
  292. package/dist/store/runtime.js.map +1 -0
  293. package/dist/store/schema.d.ts +33 -0
  294. package/dist/store/schema.d.ts.map +1 -0
  295. package/dist/store/schema.js +187 -0
  296. package/dist/store/schema.js.map +1 -0
  297. package/dist/store/setup-bindings.d.ts +20 -0
  298. package/dist/store/setup-bindings.d.ts.map +1 -0
  299. package/dist/store/setup-bindings.js +52 -0
  300. package/dist/store/setup-bindings.js.map +1 -0
  301. package/dist/store/sql-command-router.d.ts +79 -0
  302. package/dist/store/sql-command-router.d.ts.map +1 -0
  303. package/dist/store/sql-command-router.js +92 -0
  304. package/dist/store/sql-command-router.js.map +1 -0
  305. package/dist/store/sql-daemon-services.d.ts +61 -0
  306. package/dist/store/sql-daemon-services.d.ts.map +1 -0
  307. package/dist/store/sql-daemon-services.js +124 -0
  308. package/dist/store/sql-daemon-services.js.map +1 -0
  309. package/dist/store/sql-recovery-export.d.ts +8 -0
  310. package/dist/store/sql-recovery-export.d.ts.map +1 -0
  311. package/dist/store/sql-recovery-export.js +110 -0
  312. package/dist/store/sql-recovery-export.js.map +1 -0
  313. package/dist/store/sql-recovery-inspection.d.ts +22 -0
  314. package/dist/store/sql-recovery-inspection.d.ts.map +1 -0
  315. package/dist/store/sql-recovery-inspection.js +88 -0
  316. package/dist/store/sql-recovery-inspection.js.map +1 -0
  317. package/dist/store/sql-recovery.d.ts +69 -0
  318. package/dist/store/sql-recovery.d.ts.map +1 -0
  319. package/dist/store/sql-recovery.js +169 -0
  320. package/dist/store/sql-recovery.js.map +1 -0
  321. package/dist/store/sql-validation.d.ts +9 -0
  322. package/dist/store/sql-validation.d.ts.map +1 -0
  323. package/dist/store/sql-validation.js +103 -0
  324. package/dist/store/sql-validation.js.map +1 -0
  325. package/dist/store/statement-observer.d.ts +7 -0
  326. package/dist/store/statement-observer.d.ts.map +1 -0
  327. package/dist/store/statement-observer.js +44 -0
  328. package/dist/store/statement-observer.js.map +1 -0
  329. package/dist/store/store.d.ts +110 -0
  330. package/dist/store/store.d.ts.map +1 -0
  331. package/dist/store/store.js +296 -0
  332. package/dist/store/store.js.map +1 -0
  333. package/dist/store/terminal-files.d.ts +21 -0
  334. package/dist/store/terminal-files.d.ts.map +1 -0
  335. package/dist/store/terminal-files.js +115 -0
  336. package/dist/store/terminal-files.js.map +1 -0
  337. package/dist/store/thread-replay.d.ts +12 -0
  338. package/dist/store/thread-replay.d.ts.map +1 -0
  339. package/dist/store/thread-replay.js +49 -0
  340. package/dist/store/thread-replay.js.map +1 -0
  341. package/dist/store/thread-rows.d.ts +25 -0
  342. package/dist/store/thread-rows.d.ts.map +1 -0
  343. package/dist/store/thread-rows.js +141 -0
  344. package/dist/store/thread-rows.js.map +1 -0
  345. package/dist/store/threads.d.ts +105 -0
  346. package/dist/store/threads.d.ts.map +1 -0
  347. package/dist/store/threads.js +423 -0
  348. package/dist/store/threads.js.map +1 -0
  349. package/dist/store/upload-binding-retention.d.ts +26 -0
  350. package/dist/store/upload-binding-retention.d.ts.map +1 -0
  351. package/dist/store/upload-binding-retention.js +142 -0
  352. package/dist/store/upload-binding-retention.js.map +1 -0
  353. package/dist/store/uploads.d.ts +30 -0
  354. package/dist/store/uploads.d.ts.map +1 -0
  355. package/dist/store/uploads.js +238 -0
  356. package/dist/store/uploads.js.map +1 -0
  357. package/dist/store-contracts.d.ts +181 -0
  358. package/dist/store-contracts.d.ts.map +1 -0
  359. package/dist/store-contracts.js +2 -0
  360. package/dist/store-contracts.js.map +1 -0
  361. package/dist/terminal-authority.d.ts +9 -0
  362. package/dist/terminal-authority.d.ts.map +1 -1
  363. package/dist/terminal-authority.js +103 -1
  364. package/dist/terminal-authority.js.map +1 -1
  365. package/dist/thread-lane-checkpoints.d.ts +0 -2
  366. package/dist/thread-lane-checkpoints.d.ts.map +1 -1
  367. package/dist/thread-lane-checkpoints.js +0 -4
  368. package/dist/thread-lane-checkpoints.js.map +1 -1
  369. package/dist/thread-store-support.d.ts +1 -27
  370. package/dist/thread-store-support.d.ts.map +1 -1
  371. package/dist/thread-store-support.js +0 -63
  372. package/dist/thread-store-support.js.map +1 -1
  373. package/dist/threads.d.ts +1 -113
  374. package/dist/threads.d.ts.map +1 -1
  375. package/dist/threads.js +1 -379
  376. package/dist/threads.js.map +1 -1
  377. package/package.json +9 -7
  378. package/dist/command-activity.d.ts +0 -14
  379. package/dist/command-activity.d.ts.map +0 -1
  380. package/dist/command-activity.js +0 -16
  381. package/dist/command-activity.js.map +0 -1
  382. package/dist/journal-events.d.ts +0 -4
  383. package/dist/journal-events.d.ts.map +0 -1
  384. package/dist/journal-events.js +0 -23
  385. package/dist/journal-events.js.map +0 -1
  386. package/dist/journal-maintenance.d.ts +0 -50
  387. package/dist/journal-maintenance.d.ts.map +0 -1
  388. package/dist/journal-maintenance.js +0 -162
  389. package/dist/journal-maintenance.js.map +0 -1
  390. package/dist/journal-manager-journal.d.ts +0 -18
  391. package/dist/journal-manager-journal.d.ts.map +0 -1
  392. package/dist/journal-manager-journal.js +0 -25
  393. package/dist/journal-manager-journal.js.map +0 -1
  394. package/dist/journal-manager-lifecycle.d.ts +0 -11
  395. package/dist/journal-manager-lifecycle.d.ts.map +0 -1
  396. package/dist/journal-manager-lifecycle.js +0 -2
  397. package/dist/journal-manager-lifecycle.js.map +0 -1
  398. package/dist/journal-manager.d.ts +0 -99
  399. package/dist/journal-manager.d.ts.map +0 -1
  400. package/dist/journal-manager.js +0 -559
  401. package/dist/journal-manager.js.map +0 -1
  402. package/dist/journal-prepared-operation.d.ts +0 -53
  403. package/dist/journal-prepared-operation.d.ts.map +0 -1
  404. package/dist/journal-prepared-operation.js +0 -158
  405. package/dist/journal-prepared-operation.js.map +0 -1
  406. package/dist/journal-projection-slot.d.ts +0 -28
  407. package/dist/journal-projection-slot.d.ts.map +0 -1
  408. package/dist/journal-projection-slot.js +0 -71
  409. package/dist/journal-projection-slot.js.map +0 -1
  410. package/dist/journal-projection.d.ts +0 -13
  411. package/dist/journal-projection.d.ts.map +0 -1
  412. package/dist/journal-projection.js +0 -2
  413. package/dist/journal-projection.js.map +0 -1
  414. package/dist/partition-accounts.d.ts +0 -27
  415. package/dist/partition-accounts.d.ts.map +0 -1
  416. package/dist/partition-accounts.js +0 -21
  417. package/dist/partition-accounts.js.map +0 -1
  418. package/dist/project-partition-preparation.d.ts +0 -87
  419. package/dist/project-partition-preparation.d.ts.map +0 -1
  420. package/dist/project-partition-preparation.js +0 -273
  421. package/dist/project-partition-preparation.js.map +0 -1
  422. package/dist/project-partitions.d.ts +0 -214
  423. package/dist/project-partitions.d.ts.map +0 -1
  424. package/dist/project-partitions.js +0 -486
  425. package/dist/project-partitions.js.map +0 -1
  426. package/dist/project-remove.d.ts +0 -11
  427. package/dist/project-remove.d.ts.map +0 -1
  428. package/dist/project-remove.js +0 -65
  429. package/dist/project-remove.js.map +0 -1
  430. package/dist/project-thread-listing.d.ts +0 -14
  431. package/dist/project-thread-listing.d.ts.map +0 -1
  432. package/dist/project-thread-listing.js +0 -37
  433. package/dist/project-thread-listing.js.map +0 -1
  434. package/dist/quota-projection.d.ts +0 -11
  435. package/dist/quota-projection.d.ts.map +0 -1
  436. package/dist/quota-projection.js +0 -10
  437. package/dist/quota-projection.js.map +0 -1
  438. package/dist/resource-store.d.ts +0 -39
  439. package/dist/resource-store.d.ts.map +0 -1
  440. package/dist/resource-store.js +0 -464
  441. package/dist/resource-store.js.map +0 -1
  442. package/dist/run-event-terminal-index.d.ts +0 -13
  443. package/dist/run-event-terminal-index.d.ts.map +0 -1
  444. package/dist/run-event-terminal-index.js +0 -38
  445. package/dist/run-event-terminal-index.js.map +0 -1
  446. package/dist/run-events.d.ts +0 -17
  447. package/dist/run-events.d.ts.map +0 -1
  448. package/dist/run-events.js +0 -31
  449. package/dist/run-events.js.map +0 -1
  450. package/dist/thread-head-ping.d.ts +0 -35
  451. package/dist/thread-head-ping.d.ts.map +0 -1
  452. package/dist/thread-head-ping.js +0 -67
  453. package/dist/thread-head-ping.js.map +0 -1
@@ -1,158 +0,0 @@
1
- import { createHash } from "node:crypto";
2
- import { existsSync, readdirSync } from "node:fs";
3
- import { dirname, join } from "node:path";
4
- import { fingerprintPartition, requireStableFingerprint, requireStablePreparationIdentity, writeAtomicPrivateJson, } from "./journal-recovery-files.js";
5
- import { matchingReceipt, readOperation, typedError, } from "./journal-recovery-operation.js";
6
- export function inspectPreparedOperation(input) {
7
- const operations = fingerprintPartition(input.operationsDir, input.rootDir);
8
- const operationsIdentity = requireStablePreparationIdentity(operations, "journal recovery operations are unavailable");
9
- if (!operations.exists) {
10
- return { kind: "none", fingerprint: operationFingerprint(operationsIdentity, null) };
11
- }
12
- const prepared = readdirSync(input.operationsDir)
13
- .filter((name) => /^[a-f0-9]{64}\.json$/.test(name))
14
- .map((name) => {
15
- const path = join(input.operationsDir, name);
16
- return {
17
- path,
18
- operation: readOperation(path, input.quarantineDir, input.partition, input.artifactPrefix),
19
- };
20
- })
21
- .filter((entry) => entry.operation?.status === "prepared");
22
- if (prepared.length === 0) {
23
- return { kind: "none", fingerprint: operationFingerprint(operationsIdentity, null) };
24
- }
25
- if (prepared.length !== 1)
26
- throw new Error("multiple prepared recovery operations");
27
- const pending = prepared[0];
28
- const source = fingerprintPartition(input.partitionDir, input.rootDir);
29
- const target = fingerprintPartition(pending.operation.quarantinePath, input.rootDir);
30
- requireStableFingerprint(source, "journal recovery source is unavailable");
31
- const stableTargetFingerprint = requireStableFingerprint(target, "journal recovery quarantine is unavailable");
32
- const sourceExists = source.exists;
33
- const targetExists = target.exists;
34
- const fingerprint = operationFingerprint(operationsIdentity, requireStablePreparationIdentity(target, "journal recovery quarantine is unavailable"));
35
- if (targetExists && stableTargetFingerprint !== pending.operation.expectedFingerprint) {
36
- throw typedError("recovery_quarantine_mismatch", 503, "quarantined bytes changed");
37
- }
38
- if (sourceExists && !targetExists) {
39
- return { kind: "source_intact", fingerprint, ...pending };
40
- }
41
- if (!sourceExists && targetExists) {
42
- if (input.journal?.state().status === "ready") {
43
- if (!input.journal.preparation().virtual || input.journal.records().length !== 0) {
44
- throw typedError("recovery_operation_ambiguous", 503, "fresh journal is not empty");
45
- }
46
- }
47
- return { kind: "resume_after_activation", fingerprint, ...pending };
48
- }
49
- if (sourceExists && targetExists) {
50
- assertExactReceipt(input.journal, pending.operation, input.partition, input.artifactPrefix);
51
- return { kind: "complete_after_activation", fingerprint, ...pending };
52
- }
53
- throw typedError("recovery_operation_missing", 503, "recovery source and target are missing");
54
- }
55
- export function preparationFingerprint(journalFingerprint, operationFingerprint) {
56
- return createHash("sha256")
57
- .update(`${journalFingerprint}\0${operationFingerprint}\0`)
58
- .digest("hex");
59
- }
60
- export function revalidatePreparedState(input) {
61
- if (!input.journal)
62
- throw new Error("journal is not prepared");
63
- input.journal.revalidatePreparation();
64
- const operation = inspectPreparedOperation(input);
65
- const actual = preparationFingerprint(input.journal.preparation().preparationIdentity, operation.fingerprint);
66
- if (actual !== input.expectedFingerprint) {
67
- throw new Error("journal manager changed since read-only preparation");
68
- }
69
- return operation;
70
- }
71
- export function applyPreparedOperation(input) {
72
- if (input.plan.kind === "none" || input.plan.kind === "source_intact")
73
- return;
74
- const currentFingerprint = operationFingerprint(requireStablePreparationIdentity(fingerprintPartition(dirname(input.plan.path), input.rootDir), "journal recovery operations changed"), requireStablePreparationIdentity(fingerprintPartition(input.plan.operation.quarantinePath, input.rootDir), "journal recovery quarantine changed"));
75
- if (currentFingerprint !== input.plan.fingerprint) {
76
- throw typedError("recovery_fingerprint_mismatch", 409, "prepared recovery input changed");
77
- }
78
- if (requireStableFingerprint(fingerprintPartition(input.plan.operation.quarantinePath, input.rootDir), "journal recovery quarantine changed") !== input.plan.operation.expectedFingerprint) {
79
- throw typedError("recovery_quarantine_mismatch", 503, "quarantined bytes changed");
80
- }
81
- let receipt;
82
- if (input.plan.kind === "resume_after_activation") {
83
- if (input.journal.records().length !== 0) {
84
- throw typedError("recovery_operation_ambiguous", 503, "fresh journal is not empty");
85
- }
86
- receipt = {
87
- schemaVersion: 1,
88
- operationId: input.plan.operation.operationId,
89
- partition: input.partition,
90
- previousFingerprint: input.plan.operation.expectedFingerprint,
91
- quarantineArtifactId: `${input.artifactPrefix}-${input.plan.operation.operationId}`,
92
- quarantinePath: input.plan.operation.quarantinePath,
93
- newEpoch: input.journal.currentEpoch(),
94
- completedAt: input.now().toISOString(),
95
- };
96
- input.journal.append("journal.partition_quarantined", receipt);
97
- input.afterReceipt?.();
98
- }
99
- else {
100
- receipt = assertExactReceipt(input.journal, input.plan.operation, input.partition, input.artifactPrefix);
101
- }
102
- writeAtomicPrivateJson(input.plan.path, { ...input.plan.operation, status: "completed", receipt }, false);
103
- }
104
- export function completePreparedReceipt(input) {
105
- if (requireStableFingerprint(fingerprintPartition(input.operation.quarantinePath, input.rootDir), "journal recovery quarantine changed") !== input.operation.expectedFingerprint) {
106
- throw typedError("recovery_quarantine_mismatch", 503, "quarantined bytes changed");
107
- }
108
- const receipt = assertExactReceipt(input.journal, input.operation, input.partition, input.artifactPrefix);
109
- writeAtomicPrivateJson(input.operationPath, { ...input.operation, status: "completed", receipt }, false);
110
- return receipt;
111
- }
112
- export function reconcilePreparedOperationOnStart(input) {
113
- if (!existsSync(input.operationsDir))
114
- return false;
115
- try {
116
- const prepared = readdirSync(input.operationsDir)
117
- .filter((name) => /^[a-f0-9]{64}\.json$/.test(name))
118
- .map((name) => {
119
- const path = join(input.operationsDir, name);
120
- return {
121
- path,
122
- operation: readOperation(path, input.quarantineDir, input.partition, input.artifactPrefix),
123
- };
124
- })
125
- .filter((entry) => entry.operation?.status === "prepared");
126
- if (prepared.length === 0)
127
- return false;
128
- if (prepared.length !== 1)
129
- throw new Error("multiple prepared recovery operations");
130
- const pending = prepared[0];
131
- if (existsSync(input.partitionDir) && !existsSync(pending.operation.quarantinePath)) {
132
- input.openGeneration();
133
- }
134
- else {
135
- input.resume(pending.operation, pending.path);
136
- }
137
- }
138
- catch (error) {
139
- input.failed(error);
140
- }
141
- return true;
142
- }
143
- function assertExactReceipt(journal, operation, partition, artifactPrefix) {
144
- if (!journal || journal.state().status === "recovery_required") {
145
- throw typedError("recovery_operation_ambiguous", 503, "fresh journal is unreadable");
146
- }
147
- const records = journal.records();
148
- if (records.length !== 1 || records[0]?.type !== "journal.partition_quarantined") {
149
- throw typedError("recovery_operation_ambiguous", 503, "fresh receipt is missing");
150
- }
151
- return matchingReceipt(operation, records[0].payload, partition, artifactPrefix);
152
- }
153
- function operationFingerprint(operations, quarantine) {
154
- return createHash("sha256")
155
- .update(`${operations}\0${quarantine ?? "missing"}\0`)
156
- .digest("hex");
157
- }
158
- //# sourceMappingURL=journal-prepared-operation.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"journal-prepared-operation.js","sourceRoot":"","sources":["../src/journal-prepared-operation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAClD,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAG1C,OAAO,EACL,oBAAoB,EACpB,wBAAwB,EACxB,gCAAgC,EAChC,sBAAsB,GACvB,MAAM,6BAA6B,CAAC;AACrC,OAAO,EACL,eAAe,EACf,aAAa,EACb,UAAU,GAEX,MAAM,iCAAiC,CAAC;AAWzC,MAAM,UAAU,wBAAwB,CAAC,KAQxC;IACC,MAAM,UAAU,GAAG,oBAAoB,CAAC,KAAK,CAAC,aAAa,EAAE,KAAK,CAAC,OAAO,CAAC,CAAC;IAC5E,MAAM,kBAAkB,GAAG,gCAAgC,CACzD,UAAU,EACV,6CAA6C,CAC9C,CAAC;IACF,IAAI,CAAC,UAAU,CAAC,MAAM,EAAE,CAAC;QACvB,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,WAAW,EAAE,oBAAoB,CAAC,kBAAkB,EAAE,IAAI,CAAC,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MAAM,KAAK,mBAAmB,EAAE,CAAC;QAC/D,MAAM,UAAU,CAAC,8BAA8B,EAAE,GAAG,EAAE,6BAA6B,CAAC,CAAC;IACvF,CAAC;IACD,MAAM,OAAO,GAAG,OAAO,CAAC,OAAO,EAAE,CAAC;IAClC,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC,IAAI,OAAO,CAAC,CAAC,CAAC,EAAE,IAAI,KAAK,+BAA+B,EAAE,CAAC;QACjF,MAAM,UAAU,CAAC,8BAA8B,EAAE,GAAG,EAAE,0BAA0B,CAAC,CAAC;IACpF,CAAC;IACD,OAAO,eAAe,CAAC,SAAS,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,OAAO,EAAE,SAAS,EAAE,cAAc,CAAC,CAAC;AACnF,CAAC;AAED,SAAS,oBAAoB,CAAC,UAAkB,EAAE,UAAyB;IACzE,OAAO,UAAU,CAAC,QAAQ,CAAC;SACxB,MAAM,CAAC,GAAG,UAAU,KAAK,UAAU,IAAI,SAAS,IAAI,CAAC;SACrD,MAAM,CAAC,KAAK,CAAC,CAAC;AACnB,CAAC"}
@@ -1,28 +0,0 @@
1
- import { type DurableJournal, type JournalRecoveryState } from "@claudexor/journal";
2
- import type { ControlJournalValidation } from "@claudexor/schema";
3
- import type { JournalProjectionDescriptor, JournalProjectionSlot } from "./journal-projection.js";
4
- export interface ProjectionRegistration<T = unknown> {
5
- descriptor: JournalProjectionDescriptor<T>;
6
- slot: ProjectionSlot<T>;
7
- }
8
- export declare function prepareProjectionSlots(registrations: Iterable<ProjectionRegistration>, journal: DurableJournal): {
9
- status: ControlJournalValidation["projectionStatus"];
10
- recovery: Extract<JournalRecoveryState, {
11
- status: "recovery_required";
12
- }> | null;
13
- };
14
- export declare class ProjectionSlot<T> implements JournalProjectionSlot<T> {
15
- private readonly recovery;
16
- private value;
17
- private preparedValue;
18
- private generationValue;
19
- constructor(recovery: () => JournalRecoveryState);
20
- current(): T;
21
- prepared(): T;
22
- generation(): number;
23
- bind(value: T, generation: number): void;
24
- bindPrepared(value: T): void;
25
- activate(generation: number): void;
26
- clear(): void;
27
- }
28
- //# sourceMappingURL=journal-projection-slot.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"journal-projection-slot.d.ts","sourceRoot":"","sources":["../src/journal-projection-slot.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,cAAc,EAEnB,KAAK,oBAAoB,EAC1B,MAAM,oBAAoB,CAAC;AAC5B,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,mBAAmB,CAAC;AAClE,OAAO,KAAK,EAAE,2BAA2B,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AAGlG,MAAM,WAAW,sBAAsB,CAAC,CAAC,GAAG,OAAO;IACjD,UAAU,EAAE,2BAA2B,CAAC,CAAC,CAAC,CAAC;IAC3C,IAAI,EAAE,cAAc,CAAC,CAAC,CAAC,CAAC;CACzB;AAED,wBAAgB,sBAAsB,CACpC,aAAa,EAAE,QAAQ,CAAC,sBAAsB,CAAC,EAC/C,OAAO,EAAE,cAAc,GACtB;IACD,MAAM,EAAE,wBAAwB,CAAC,kBAAkB,CAAC,CAAC;IACrD,QAAQ,EAAE,OAAO,CAAC,oBAAoB,EAAE;QAAE,MAAM,EAAE,mBAAmB,CAAA;KAAE,CAAC,GAAG,IAAI,CAAC;CACjF,CAqBA;AAED,qBAAa,cAAc,CAAC,CAAC,CAAE,YAAW,qBAAqB,CAAC,CAAC,CAAC;IAKpD,OAAO,CAAC,QAAQ,CAAC,QAAQ;IAJrC,OAAO,CAAC,KAAK,CAAkB;IAC/B,OAAO,CAAC,aAAa,CAAkB;IACvC,OAAO,CAAC,eAAe,CAAK;IAE5B,YAA6B,QAAQ,EAAE,MAAM,oBAAoB,EAAI;IAErE,OAAO,IAAI,CAAC,CAQX;IAED,QAAQ,IAAI,CAAC,CAGZ;IAED,UAAU,IAAI,MAAM,CAEnB;IAED,IAAI,CAAC,KAAK,EAAE,CAAC,EAAE,UAAU,EAAE,MAAM,GAAG,IAAI,CAGvC;IAED,YAAY,CAAC,KAAK,EAAE,CAAC,GAAG,IAAI,CAE3B;IAED,QAAQ,CAAC,UAAU,EAAE,MAAM,GAAG,IAAI,CAOjC;IAED,KAAK,IAAI,IAAI,CAGZ;CACF"}
@@ -1,71 +0,0 @@
1
- import { JournalRecoveryRequiredError, } from "@claudexor/journal";
2
- import { recoveryAt, recoveryFrom, safeMessage } from "./journal-recovery-files.js";
3
- export function prepareProjectionSlots(registrations, journal) {
4
- const status = [];
5
- for (const registration of registrations) {
6
- try {
7
- const projection = registration.descriptor.create(journal);
8
- registration.descriptor.validate(projection);
9
- registration.slot.bindPrepared(projection);
10
- status.push({ name: registration.descriptor.name, status: "valid", detail: null });
11
- }
12
- catch (error) {
13
- status.push({
14
- name: registration.descriptor.name,
15
- status: "invalid",
16
- detail: safeMessage(error),
17
- });
18
- return {
19
- status,
20
- recovery: recoveryFrom(error, `projection '${registration.descriptor.name}' failed`),
21
- };
22
- }
23
- }
24
- return { status, recovery: null };
25
- }
26
- export class ProjectionSlot {
27
- recovery;
28
- value = null;
29
- preparedValue = null;
30
- generationValue = 0;
31
- constructor(recovery) {
32
- this.recovery = recovery;
33
- }
34
- current() {
35
- if (this.value !== null)
36
- return this.value;
37
- const state = this.recovery();
38
- throw new JournalRecoveryRequiredError(state.status === "recovery_required"
39
- ? state
40
- : recoveryAt(0, "journal projection is unavailable"));
41
- }
42
- prepared() {
43
- if (this.preparedValue !== null)
44
- return this.preparedValue;
45
- return this.current();
46
- }
47
- generation() {
48
- return this.generationValue;
49
- }
50
- bind(value, generation) {
51
- this.value = value;
52
- this.generationValue = generation;
53
- }
54
- bindPrepared(value) {
55
- this.preparedValue = value;
56
- }
57
- activate(generation) {
58
- if (this.preparedValue === null) {
59
- if (this.value !== null)
60
- return;
61
- throw new Error("journal projection is not prepared");
62
- }
63
- this.bind(this.preparedValue, generation);
64
- this.preparedValue = null;
65
- }
66
- clear() {
67
- this.value = null;
68
- this.preparedValue = null;
69
- }
70
- }
71
- //# sourceMappingURL=journal-projection-slot.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"journal-projection-slot.js","sourceRoot":"","sources":["../src/journal-projection-slot.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,4BAA4B,GAE7B,MAAM,oBAAoB,CAAC;AAG5B,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,6BAA6B,CAAC;AAOpF,MAAM,UAAU,sBAAsB,CACpC,aAA+C,EAC/C,OAAuB;IAKvB,MAAM,MAAM,GAAiD,EAAE,CAAC;IAChE,KAAK,MAAM,YAAY,IAAI,aAAa,EAAE,CAAC;QACzC,IAAI,CAAC;YACH,MAAM,UAAU,GAAG,YAAY,CAAC,UAAU,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;YAC3D,YAAY,CAAC,UAAU,CAAC,QAAQ,CAAC,UAAU,CAAC,CAAC;YAC7C,YAAY,CAAC,IAAI,CAAC,YAAY,CAAC,UAAU,CAAC,CAAC;YAC3C,MAAM,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,YAAY,CAAC,UAAU,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC;QACrF,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,MAAM,CAAC,IAAI,CAAC;gBACV,IAAI,EAAE,YAAY,CAAC,UAAU,CAAC,IAAI;gBAClC,MAAM,EAAE,SAAS;gBACjB,MAAM,EAAE,WAAW,CAAC,KAAK,CAAC;aAC3B,CAAC,CAAC;YACH,OAAO;gBACL,MAAM;gBACN,QAAQ,EAAE,YAAY,CAAC,KAAK,EAAE,eAAe,YAAY,CAAC,UAAU,CAAC,IAAI,UAAU,CAAC;aACrF,CAAC;QACJ,CAAC;IACH,CAAC;IACD,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;AACpC,CAAC;AAED,MAAM,OAAO,cAA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IAAI,CAAC,KAAK,GAAG,IAAI,CAAC;QAClB,IAAI,CAAC,aAAa,GAAG,IAAI,CAAC;IAC5B,CAAC;CACF"}
@@ -1,13 +0,0 @@
1
- import type { DurableJournal } from "@claudexor/journal";
2
- export interface JournalProjectionDescriptor<T> {
3
- name: string;
4
- create(journal: DurableJournal): T;
5
- validate(projection: T): void;
6
- recover?(projection: T): void;
7
- }
8
- export interface JournalProjectionSlot<T> {
9
- current(): T;
10
- prepared(): T;
11
- generation(): number;
12
- }
13
- //# sourceMappingURL=journal-projection.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"journal-projection.d.ts","sourceRoot":"","sources":["../src/journal-projection.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAEzD,MAAM,WAAW,2BAA2B,CAAC,CAAC;IAC5C,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,OAAO,EAAE,cAAc,GAAG,CAAC,CAAC;IACnC,QAAQ,CAAC,UAAU,EAAE,CAAC,GAAG,IAAI,CAAC;IAC9B,OAAO,CAAC,CAAC,UAAU,EAAE,CAAC,GAAG,IAAI,CAAC;CAC/B;AAED,MAAM,WAAW,qBAAqB,CAAC,CAAC;IACtC,OAAO,IAAI,CAAC,CAAC;IACb,QAAQ,IAAI,CAAC,CAAC;IACd,UAAU,IAAI,MAAM,CAAC;CACtB"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=journal-projection.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"journal-projection.js","sourceRoot":"","sources":["../src/journal-projection.ts"],"names":[],"mappings":""}
@@ -1,27 +0,0 @@
1
- import type { ThreadStore } from "./threads.js";
2
- /**
3
- * Cross-partition account lifecycle helpers (INV-135/137), extracted from
4
- * project-partitions.ts (INV-124). The unified-accounts migration and its
5
- * rollback apply a continuity mutation across the global store and every
6
- * HEALTHY project partition; quarantined partitions are skipped and DISCLOSED
7
- * (their null-lane sessions migrate on a later start once recovered — a
8
- * bounded disclosed residual, never silent loss).
9
- */
10
- export interface ProfileContinuityResult {
11
- sessions: number;
12
- checkpoints: number;
13
- skippedPartitions: string[];
14
- }
15
- export declare function applyProfileContinuityAcross(hosts: {
16
- stores: ThreadStore[];
17
- skippedPartitions: string[];
18
- }, apply: (store: ThreadStore) => {
19
- sessions: number;
20
- checkpoints: number;
21
- }): ProfileContinuityResult;
22
- /** Credential-profile deletion invalidation summed across every store. */
23
- export declare function invalidateCredentialProfileAcross(stores: ThreadStore[], harnessId: string, profileId: string): {
24
- clearedThreads: number;
25
- invalidatedSessions: number;
26
- };
27
- //# sourceMappingURL=partition-accounts.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"partition-accounts.d.ts","sourceRoot":"","sources":["../src/partition-accounts.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAEhD;;;;;;;GAOG;AAEH,MAAM,WAAW,uBAAuB;IACtC,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,iBAAiB,EAAE,MAAM,EAAE,CAAC;CAC7B;AAED,wBAAgB,4BAA4B,CAC1C,KAAK,EAAE;IAAE,MAAM,EAAE,WAAW,EAAE,CAAC;IAAC,iBAAiB,EAAE,MAAM,EAAE,CAAA;CAAE,EAC7D,KAAK,EAAE,CAAC,KAAK,EAAE,WAAW,KAAK;IAAE,QAAQ,EAAE,MAAM,CAAC;IAAC,WAAW,EAAE,MAAM,CAAA;CAAE,GACvE,uBAAuB,CASzB;AAED,0EAA0E;AAC1E,wBAAgB,iCAAiC,CAC/C,MAAM,EAAE,WAAW,EAAE,EACrB,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,MAAM,GAChB;IAAE,cAAc,EAAE,MAAM,CAAC;IAAC,mBAAmB,EAAE,MAAM,CAAA;CAAE,CAWzD"}
@@ -1,21 +0,0 @@
1
- export function applyProfileContinuityAcross(hosts, apply) {
2
- let sessions = 0;
3
- let checkpoints = 0;
4
- for (const store of hosts.stores) {
5
- const result = apply(store);
6
- sessions += result.sessions;
7
- checkpoints += result.checkpoints;
8
- }
9
- return { sessions, checkpoints, skippedPartitions: hosts.skippedPartitions };
10
- }
11
- /** Credential-profile deletion invalidation summed across every store. */
12
- export function invalidateCredentialProfileAcross(stores, harnessId, profileId) {
13
- return stores.reduce((total, store) => {
14
- const result = store.invalidateCredentialProfile(harnessId, profileId);
15
- return {
16
- clearedThreads: total.clearedThreads + result.clearedThreads,
17
- invalidatedSessions: total.invalidatedSessions + result.invalidatedSessions,
18
- };
19
- }, { clearedThreads: 0, invalidatedSessions: 0 });
20
- }
21
- //# sourceMappingURL=partition-accounts.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"partition-accounts.js","sourceRoot":"","sources":["../src/partition-accounts.ts"],"names":[],"mappings":"AAiBA,MAAM,UAAU,4BAA4B,CAC1C,KAA6D,EAC7D,KAAwE;IAExE,IAAI,QAAQ,GAAG,CAAC,CAAC;IACjB,IAAI,WAAW,GAAG,CAAC,CAAC;IACpB,KAAK,MAAM,KAAK,IAAI,KAAK,CAAC,MAAM,EAAE,CAAC;QACjC,MAAM,MAAM,GAAG,KAAK,CAAC,KAAK,CAAC,CAAC;QAC5B,QAAQ,IAAI,MAAM,CAAC,QAAQ,CAAC;QAC5B,WAAW,IAAI,MAAM,CAAC,WAAW,CAAC;IACpC,CAAC;IACD,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,iBAAiB,EAAE,KAAK,CAAC,iBAAiB,EAAE,CAAC;AAC/E,CAAC;AAED,0EAA0E;AAC1E,MAAM,UAAU,iCAAiC,CAC/C,MAAqB,EACrB,SAAiB,EACjB,SAAiB;IAEjB,OAAO,MAAM,CAAC,MAAM,CAClB,CAAC,KAAK,EAAE,KAAK,EAAE,EAAE;QACf,MAAM,MAAM,GAAG,KAAK,CAAC,2BAA2B,CAAC,SAAS,EAAE,SAAS,CAAC,CAAC;QACvE,OAAO;YACL,cAAc,EAAE,KAAK,CAAC,cAAc,GAAG,MAAM,CAAC,cAAc;YAC5D,mBAAmB,EAAE,KAAK,CAAC,mBAAmB,GAAG,MAAM,CAAC,mBAAmB;SAC5E,CAAC;IACJ,CAAC,EACD,EAAE,cAAc,EAAE,CAAC,EAAE,mBAAmB,EAAE,CAAC,EAAE,CAC9C,CAAC;AACJ,CAAC"}
@@ -1,87 +0,0 @@
1
- import type { Thread } from "@claudexor/schema";
2
- import { type CommandStore } from "./command-store.js";
3
- import { type InteractionStore } from "./interactions.js";
4
- import { JournalManager, type JournalProjectionSlot } from "./journal-manager.js";
5
- import type { JournalManagerOptions } from "./journal-manager-lifecycle.js";
6
- import { type OperatorDecisionStore } from "./operator-decisions.js";
7
- import type { ProjectStore } from "./projects.js";
8
- import { type RunEventStore } from "./run-events.js";
9
- import { type CreateThreadInput, type ThreadHeadPingSink, type ThreadStore } from "./threads.js";
10
- export interface ProjectPartitionEntry {
11
- manager: JournalManager;
12
- commands: JournalProjectionSlot<CommandStore>;
13
- interactions: JournalProjectionSlot<InteractionStore>;
14
- decisions: JournalProjectionSlot<OperatorDecisionStore>;
15
- runEvents: JournalProjectionSlot<RunEventStore>;
16
- threads: JournalProjectionSlot<ThreadStore>;
17
- }
18
- export interface ProjectPartitionPreparationEntry {
19
- projectId: string;
20
- partition: string;
21
- status: "ready" | "recovery_required";
22
- virtual: boolean;
23
- fingerprint: string;
24
- manager: JournalManager;
25
- }
26
- export interface ProjectPartitionsPreparation {
27
- coverage: "complete" | "global_registry_unavailable";
28
- fingerprint: string | null;
29
- registeredProjectIds: string[];
30
- trustedProjectRoots: string[];
31
- partitions: ProjectPartitionPreparationEntry[];
32
- readyPartitions: string[];
33
- recoveryRequiredPartitions: string[];
34
- }
35
- export interface PreparedProjectPartitions {
36
- receipt: ProjectPartitionsPreparation;
37
- entries: Map<string, ProjectPartitionEntry>;
38
- }
39
- export declare class ProjectPartitionCollection extends Map<string, ProjectPartitionEntry> {
40
- private readonly rootDir;
41
- private readonly projects;
42
- private readonly headPing?;
43
- private readonly requestMaintenance?;
44
- constructor(rootDir: string, projects: JournalProjectionSlot<ProjectStore>, headPing?: ThreadHeadPingSink | undefined, requestMaintenance?: JournalManagerOptions["requestMaintenance"]);
45
- sync(): void;
46
- ensure(projectId: string): ProjectPartitionEntry;
47
- findThreadCreation(input: CreateThreadInput & {
48
- ephemeral?: boolean;
49
- }, globalThreads: ThreadStore): Thread | null;
50
- /** Caller-owned execution roots recorded by the prepared partition
51
- * commands, for crash GC (a partition not prepared contributes nothing). */
52
- preparedExecutionRoots(): string[];
53
- healthy(): ProjectPartitionEntry[];
54
- healthyRoots(): string[];
55
- }
56
- export declare function prepareProjectPartitions(input: {
57
- rootDir: string;
58
- projects: JournalProjectionSlot<ProjectStore>;
59
- headPing?: ThreadHeadPingSink;
60
- requestMaintenance?: JournalManagerOptions["requestMaintenance"];
61
- }): PreparedProjectPartitions;
62
- /**
63
- * Live re-verdict for the in-process reopen (C6): recompute the stage-2
64
- * receipt from CURRENT partition state. A partition the operator quarantined
65
- * over the recovery route was reopened by its manager (openGeneration) and
66
- * now inspects ready; a registry that became readable after a global reopen
67
- * restores coverage. Read-only for everything still prepared — a registered
68
- * project without an entry gets a read-only prepare, never a write.
69
- */
70
- export declare function refreshProjectPartitionsPreparation(input: {
71
- rootDir: string;
72
- projects: JournalProjectionSlot<ProjectStore>;
73
- headPing?: ThreadHeadPingSink;
74
- requestMaintenance?: JournalManagerOptions["requestMaintenance"];
75
- previous: ProjectPartitionsPreparation;
76
- entries: ProjectPartitionCollection;
77
- }): ProjectPartitionsPreparation;
78
- export declare function activatePreparedProjectPartitions(input: {
79
- rootDir: string;
80
- projects: JournalProjectionSlot<ProjectStore>;
81
- headPing?: ThreadHeadPingSink;
82
- requestMaintenance?: JournalManagerOptions["requestMaintenance"];
83
- receipt: ProjectPartitionsPreparation;
84
- entries: ProjectPartitionCollection;
85
- resetReceipt(receipt: ProjectPartitionsPreparation): void;
86
- }): void;
87
- //# sourceMappingURL=project-partition-preparation.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"project-partition-preparation.d.ts","sourceRoot":"","sources":["../src/project-partition-preparation.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAqB,KAAK,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAC1E,OAAO,EAAyB,KAAK,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AACjF,OAAO,EAAE,cAAc,EAAE,KAAK,qBAAqB,EAAE,MAAM,sBAAsB,CAAC;AAClF,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,gCAAgC,CAAC;AAE5E,OAAO,EAA8B,KAAK,qBAAqB,EAAE,MAAM,yBAAyB,CAAC;AACjG,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAClD,OAAO,EAAsB,KAAK,aAAa,EAAE,MAAM,iBAAiB,CAAC;AACzE,OAAO,EAEL,KAAK,iBAAiB,EACtB,KAAK,kBAAkB,EACvB,KAAK,WAAW,EACjB,MAAM,cAAc,CAAC;AAEtB,MAAM,WAAW,qBAAqB;IACpC,OAAO,EAAE,cAAc,CAAC;IACxB,QAAQ,EAAE,qBAAqB,CAAC,YAAY,CAAC,CAAC;IAC9C,YAAY,EAAE,qBAAqB,CAAC,gBAAgB,CAAC,CAAC;IACtD,SAAS,EAAE,qBAAqB,CAAC,qBAAqB,CAAC,CAAC;IACxD,SAAS,EAAE,qBAAqB,CAAC,aAAa,CAAC,CAAC;IAChD,OAAO,EAAE,qBAAqB,CAAC,WAAW,CAAC,CAAC;CAC7C;AAED,MAAM,WAAW,gCAAgC;IAC/C,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,OAAO,GAAG,mBAAmB,CAAC;IACtC,OAAO,EAAE,OAAO,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;I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