@noopolis/daimon 0.1.2 → 0.2.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.
- package/README.md +275 -51
- package/dist/contracts/attentionContract.d.ts +142 -0
- package/dist/contracts/attentionContract.d.ts.map +1 -0
- package/dist/contracts/attentionContract.js +21 -0
- package/dist/contracts/canonicalJson.d.ts +3 -0
- package/dist/contracts/canonicalJson.d.ts.map +1 -0
- package/dist/contracts/canonicalJson.js +54 -0
- package/dist/contracts/grokBrokerTaskClock.d.ts +18 -0
- package/dist/contracts/grokBrokerTaskClock.d.ts.map +1 -0
- package/dist/contracts/grokBrokerTaskClock.js +16 -0
- package/dist/contracts/grokWorkerContract.d.ts +74 -0
- package/dist/contracts/grokWorkerContract.d.ts.map +1 -0
- package/dist/contracts/grokWorkerContract.js +88 -0
- package/dist/contracts/organizationRuntimeContract.d.ts +841 -0
- package/dist/contracts/organizationRuntimeContract.d.ts.map +1 -0
- package/dist/contracts/organizationRuntimeContract.js +123 -0
- package/dist/contracts/runtimeContractManifest.d.ts +1822 -0
- package/dist/contracts/runtimeContractManifest.d.ts.map +1 -0
- package/dist/contracts/runtimeContractManifest.js +206 -0
- package/dist/contracts/shellEnvironmentPolicy.d.ts +3 -0
- package/dist/contracts/shellEnvironmentPolicy.d.ts.map +1 -0
- package/dist/contracts/shellEnvironmentPolicy.js +5 -0
- package/dist/contracts/wakeMomentContract.d.ts +61 -0
- package/dist/contracts/wakeMomentContract.d.ts.map +1 -0
- package/dist/contracts/wakeMomentContract.js +27 -0
- package/dist/core/credentialRedaction.d.ts +4 -0
- package/dist/core/credentialRedaction.d.ts.map +1 -0
- package/dist/core/credentialRedaction.js +28 -0
- package/dist/core/types.d.ts +2 -0
- package/dist/core/types.d.ts.map +1 -1
- package/dist/examples/jungianPlayAgent.d.ts +1 -0
- package/dist/examples/jungianPlayAgent.d.ts.map +1 -1
- package/dist/examples/jungianPlayAgent.js +6 -2
- package/dist/mcp/toolServer.d.ts +19 -2
- package/dist/mcp/toolServer.d.ts.map +1 -1
- package/dist/mcp/toolServer.js +57 -17
- package/dist/observability/causalEvents.d.ts +6 -6
- package/dist/observability/causalEvents.d.ts.map +1 -1
- package/dist/observability/causalEvents.js +107 -19
- package/dist/observability/orgObserver.d.ts.map +1 -1
- package/dist/observability/orgObserver.js +3 -3
- package/dist/pi/agyHeadlessResult.d.ts +60 -0
- package/dist/pi/agyHeadlessResult.d.ts.map +1 -0
- package/dist/pi/agyHeadlessResult.js +95 -0
- package/dist/pi/cliChildOutput.d.ts +67 -0
- package/dist/pi/cliChildOutput.d.ts.map +1 -0
- package/dist/pi/cliChildOutput.js +269 -0
- package/dist/pi/cliEngineRun.d.ts +16 -0
- package/dist/pi/cliEngineRun.d.ts.map +1 -0
- package/dist/pi/cliEngineRun.js +27 -0
- package/dist/pi/cliEngineSpawn.d.ts +55 -0
- package/dist/pi/cliEngineSpawn.d.ts.map +1 -0
- package/dist/pi/cliEngineSpawn.js +169 -0
- package/dist/pi/cliEnvironment.d.ts +12 -0
- package/dist/pi/cliEnvironment.d.ts.map +1 -0
- package/dist/pi/cliEnvironment.js +34 -0
- package/dist/pi/cliMcpRegistration.d.ts +61 -0
- package/dist/pi/cliMcpRegistration.d.ts.map +1 -0
- package/dist/pi/cliMcpRegistration.js +75 -0
- package/dist/pi/cliProcess.d.ts +7 -0
- package/dist/pi/cliProcess.d.ts.map +1 -0
- package/dist/pi/cliProcess.js +132 -0
- package/dist/pi/cliSession.d.ts +86 -24
- package/dist/pi/cliSession.d.ts.map +1 -1
- package/dist/pi/cliSession.js +251 -173
- package/dist/pi/cliSessionMcp.d.ts +9 -0
- package/dist/pi/cliSessionMcp.d.ts.map +1 -0
- package/dist/pi/cliSessionMcp.js +80 -0
- package/dist/pi/cliTurnMetering.d.ts +60 -0
- package/dist/pi/cliTurnMetering.d.ts.map +1 -0
- package/dist/pi/cliTurnMetering.js +60 -0
- package/dist/pi/codexFilesystemRules.d.ts +3 -0
- package/dist/pi/codexFilesystemRules.d.ts.map +1 -0
- package/dist/pi/codexFilesystemRules.js +28 -0
- package/dist/pi/codexHeadlessResult.d.ts +68 -0
- package/dist/pi/codexHeadlessResult.d.ts.map +1 -0
- package/dist/pi/codexHeadlessResult.js +122 -0
- package/dist/pi/codexRolloutUsage.d.ts +95 -0
- package/dist/pi/codexRolloutUsage.d.ts.map +1 -0
- package/dist/pi/codexRolloutUsage.js +221 -0
- package/dist/pi/engineTaskClock.d.ts +9 -0
- package/dist/pi/engineTaskClock.d.ts.map +1 -0
- package/dist/pi/engineTaskClock.js +28 -0
- package/dist/pi/engineWakeLimits.d.ts +39 -0
- package/dist/pi/engineWakeLimits.d.ts.map +1 -0
- package/dist/pi/engineWakeLimits.js +55 -0
- package/dist/pi/grokHeadlessResult.d.ts +36 -0
- package/dist/pi/grokHeadlessResult.d.ts.map +1 -0
- package/dist/pi/grokHeadlessResult.js +118 -0
- package/dist/pi/grokHomeMcpRegistration.d.ts +21 -0
- package/dist/pi/grokHomeMcpRegistration.d.ts.map +1 -0
- package/dist/pi/grokHomeMcpRegistration.js +58 -0
- package/dist/pi/grokSandbox.d.ts +11 -0
- package/dist/pi/grokSandbox.d.ts.map +1 -0
- package/dist/pi/grokSandbox.js +216 -0
- package/dist/pi/grokStreamUsage.d.ts +31 -0
- package/dist/pi/grokStreamUsage.d.ts.map +1 -0
- package/dist/pi/grokStreamUsage.js +51 -0
- package/dist/pi/memoryClock.d.ts +25 -0
- package/dist/pi/memoryClock.d.ts.map +1 -0
- package/dist/pi/memoryClock.js +18 -0
- package/dist/pi/piAgentHandle.d.ts +6 -3
- package/dist/pi/piAgentHandle.d.ts.map +1 -1
- package/dist/pi/piAgentHandle.js +42 -12
- package/dist/pi/piAgentWakeSupport.d.ts +35 -0
- package/dist/pi/piAgentWakeSupport.d.ts.map +1 -1
- package/dist/pi/piAgentWakeSupport.js +4 -0
- package/dist/pi/piHarness.d.ts +18 -3
- package/dist/pi/piHarness.d.ts.map +1 -1
- package/dist/pi/piHarness.js +83 -14
- package/dist/pi/prompts.d.ts +1 -0
- package/dist/pi/prompts.d.ts.map +1 -1
- package/dist/pi/prompts.js +24 -0
- package/dist/pi/taskClockProcess.d.ts +6 -0
- package/dist/pi/taskClockProcess.d.ts.map +1 -0
- package/dist/pi/taskClockProcess.js +8 -0
- package/dist/pi/turnCausal.d.ts +4 -2
- package/dist/pi/turnCausal.d.ts.map +1 -1
- package/dist/pi/turnCausal.js +4 -4
- package/dist/pi/turnTrace.d.ts.map +1 -1
- package/dist/pi/turnTrace.js +5 -8
- package/dist/pi/wakeAcceptance.d.ts +1 -1
- package/dist/pi/wakeAcceptance.d.ts.map +1 -1
- package/dist/pi/wakeAcceptance.js +2 -2
- package/dist/pi/worldTrajectory.d.ts +1 -1
- package/dist/pi/worldTrajectory.d.ts.map +1 -1
- package/dist/pi/worldTrajectory.js +3 -3
- package/dist/runtime/agySubscriptionBootstrap.d.ts +16 -0
- package/dist/runtime/agySubscriptionBootstrap.d.ts.map +1 -0
- package/dist/runtime/agySubscriptionBootstrap.js +80 -0
- package/dist/runtime/agySubscriptionRealm.d.ts +38 -0
- package/dist/runtime/agySubscriptionRealm.d.ts.map +1 -0
- package/dist/runtime/agySubscriptionRealm.js +242 -0
- package/dist/runtime/attention.d.ts +26 -0
- package/dist/runtime/attention.d.ts.map +1 -0
- package/dist/runtime/attention.js +49 -0
- package/dist/runtime/attentionDispatcher.d.ts +78 -0
- package/dist/runtime/attentionDispatcher.d.ts.map +1 -0
- package/dist/runtime/attentionDispatcher.js +365 -0
- package/dist/runtime/cli.d.ts +7 -0
- package/dist/runtime/cli.d.ts.map +1 -0
- package/dist/runtime/cli.js +256 -0
- package/dist/runtime/codexSandboxProjection.d.ts +17 -0
- package/dist/runtime/codexSandboxProjection.d.ts.map +1 -0
- package/dist/runtime/codexSandboxProjection.js +40 -0
- package/dist/runtime/contract-manifest.json +1 -0
- package/dist/runtime/contract-manifest.sha256 +1 -0
- package/dist/runtime/contractManifest.d.ts +8 -0
- package/dist/runtime/contractManifest.d.ts.map +1 -0
- package/dist/runtime/contractManifest.js +4 -0
- package/dist/runtime/engineBrokerCapabilities.d.ts +40 -0
- package/dist/runtime/engineBrokerCapabilities.d.ts.map +1 -0
- package/dist/runtime/engineBrokerCapabilities.js +69 -0
- package/dist/runtime/engineBrokerControlClient.d.ts +55 -0
- package/dist/runtime/engineBrokerControlClient.d.ts.map +1 -0
- package/dist/runtime/engineBrokerControlClient.js +228 -0
- package/dist/runtime/engineBrokerCredentialJournal.d.ts +12 -0
- package/dist/runtime/engineBrokerCredentialJournal.d.ts.map +1 -0
- package/dist/runtime/engineBrokerCredentialJournal.js +26 -0
- package/dist/runtime/engineBrokerInferenceProtocol.d.ts +53 -0
- package/dist/runtime/engineBrokerInferenceProtocol.d.ts.map +1 -0
- package/dist/runtime/engineBrokerInferenceProtocol.js +65 -0
- package/dist/runtime/engineBrokerMcpCallLog.d.ts +171 -0
- package/dist/runtime/engineBrokerMcpCallLog.d.ts.map +1 -0
- package/dist/runtime/engineBrokerMcpCallLog.js +231 -0
- package/dist/runtime/engineBrokerMcpFacade.d.ts +59 -0
- package/dist/runtime/engineBrokerMcpFacade.d.ts.map +1 -0
- package/dist/runtime/engineBrokerMcpFacade.js +346 -0
- package/dist/runtime/engineBrokerNativeClient.d.ts +52 -0
- package/dist/runtime/engineBrokerNativeClient.d.ts.map +1 -0
- package/dist/runtime/engineBrokerNativeClient.js +151 -0
- package/dist/runtime/engineBrokerProtocol.d.ts +167 -0
- package/dist/runtime/engineBrokerProtocol.d.ts.map +1 -0
- package/dist/runtime/engineBrokerProtocol.js +357 -0
- package/dist/runtime/engineBrokerSealLedger.d.ts +70 -0
- package/dist/runtime/engineBrokerSealLedger.d.ts.map +1 -0
- package/dist/runtime/engineBrokerSealLedger.js +132 -0
- package/dist/runtime/engineBrokerService.d.ts +43 -0
- package/dist/runtime/engineBrokerService.d.ts.map +1 -0
- package/dist/runtime/engineBrokerService.js +196 -0
- package/dist/runtime/engineBrokerServiceCli.d.ts +5 -0
- package/dist/runtime/engineBrokerServiceCli.d.ts.map +1 -0
- package/dist/runtime/engineBrokerServiceCli.js +32 -0
- package/dist/runtime/engineBrokerServiceConfig.d.ts +55 -0
- package/dist/runtime/engineBrokerServiceConfig.d.ts.map +1 -0
- package/dist/runtime/engineBrokerServiceConfig.js +130 -0
- package/dist/runtime/engineBrokerSingleflight.d.ts +13 -0
- package/dist/runtime/engineBrokerSingleflight.d.ts.map +1 -0
- package/dist/runtime/engineBrokerSingleflight.js +24 -0
- package/dist/runtime/engineBrokerTurnAccounting.d.ts +76 -0
- package/dist/runtime/engineBrokerTurnAccounting.d.ts.map +1 -0
- package/dist/runtime/engineBrokerTurnAccounting.js +108 -0
- package/dist/runtime/engineBrokerTurnRegistry.d.ts +57 -0
- package/dist/runtime/engineBrokerTurnRegistry.d.ts.map +1 -0
- package/dist/runtime/engineBrokerTurnRegistry.js +159 -0
- package/dist/runtime/engineDispatcher.d.ts +38 -0
- package/dist/runtime/engineDispatcher.d.ts.map +1 -0
- package/dist/runtime/engineDispatcher.js +228 -0
- package/dist/runtime/engineReadiness.d.ts +23 -0
- package/dist/runtime/engineReadiness.d.ts.map +1 -0
- package/dist/runtime/engineReadiness.js +222 -0
- package/dist/runtime/grokAuthenticationError.d.ts +8 -0
- package/dist/runtime/grokAuthenticationError.d.ts.map +1 -0
- package/dist/runtime/grokAuthenticationError.js +20 -0
- package/dist/runtime/grokBrokerCredentialAuthority.d.ts +23 -0
- package/dist/runtime/grokBrokerCredentialAuthority.d.ts.map +1 -0
- package/dist/runtime/grokBrokerCredentialAuthority.js +150 -0
- package/dist/runtime/grokBrokerCredentialReader.d.ts +6 -0
- package/dist/runtime/grokBrokerCredentialReader.d.ts.map +1 -0
- package/dist/runtime/grokBrokerCredentialReader.js +38 -0
- package/dist/runtime/grokBrokerModelPolicy.d.ts +23 -0
- package/dist/runtime/grokBrokerModelPolicy.d.ts.map +1 -0
- package/dist/runtime/grokBrokerModelPolicy.js +28 -0
- package/dist/runtime/grokBrokerProjection.d.ts +114 -0
- package/dist/runtime/grokBrokerProjection.d.ts.map +1 -0
- package/dist/runtime/grokBrokerProjection.js +101 -0
- package/dist/runtime/grokBrokerProviderClock.d.ts +26 -0
- package/dist/runtime/grokBrokerProviderClock.d.ts.map +1 -0
- package/dist/runtime/grokBrokerProviderClock.js +133 -0
- package/dist/runtime/grokBrokerProxy.d.ts +69 -0
- package/dist/runtime/grokBrokerProxy.d.ts.map +1 -0
- package/dist/runtime/grokBrokerProxy.js +326 -0
- package/dist/runtime/grokBrokerProxyJson.d.ts +10 -0
- package/dist/runtime/grokBrokerProxyJson.d.ts.map +1 -0
- package/dist/runtime/grokBrokerProxyJson.js +31 -0
- package/dist/runtime/grokBrokerProxyRequest.d.ts +30 -0
- package/dist/runtime/grokBrokerProxyRequest.d.ts.map +1 -0
- package/dist/runtime/grokBrokerProxyRequest.js +85 -0
- package/dist/runtime/grokBrokerRealmLease.d.ts +4 -0
- package/dist/runtime/grokBrokerRealmLease.d.ts.map +1 -0
- package/dist/runtime/grokBrokerRealmLease.js +33 -0
- package/dist/runtime/grokBrokerRefresh.d.ts +2 -0
- package/dist/runtime/grokBrokerRefresh.d.ts.map +1 -0
- package/dist/runtime/grokBrokerRefresh.js +15 -0
- package/dist/runtime/grokBrokerRunBudget.d.ts +20 -0
- package/dist/runtime/grokBrokerRunBudget.d.ts.map +1 -0
- package/dist/runtime/grokBrokerRunBudget.js +85 -0
- package/dist/runtime/grokBrokerSlot.d.ts +6 -0
- package/dist/runtime/grokBrokerSlot.d.ts.map +1 -0
- package/dist/runtime/grokBrokerSlot.js +21 -0
- package/dist/runtime/grokBrokerTaskClock.d.ts +32 -0
- package/dist/runtime/grokBrokerTaskClock.d.ts.map +1 -0
- package/dist/runtime/grokBrokerTaskClock.js +120 -0
- package/dist/runtime/grokBrokerTurnMeter.d.ts +180 -0
- package/dist/runtime/grokBrokerTurnMeter.d.ts.map +1 -0
- package/dist/runtime/grokBrokerTurnMeter.js +337 -0
- package/dist/runtime/grokBrokerWorkerConfig.d.ts +89 -0
- package/dist/runtime/grokBrokerWorkerConfig.d.ts.map +1 -0
- package/dist/runtime/grokBrokerWorkerConfig.js +154 -0
- package/dist/runtime/grokEngineBroker.d.ts +88 -0
- package/dist/runtime/grokEngineBroker.d.ts.map +1 -0
- package/dist/runtime/grokEngineBroker.js +202 -0
- package/dist/runtime/grokEngineBrokerLedger.d.ts +52 -0
- package/dist/runtime/grokEngineBrokerLedger.d.ts.map +1 -0
- package/dist/runtime/grokEngineBrokerLedger.js +114 -0
- package/dist/runtime/grokEngineBrokerMetering.d.ts +51 -0
- package/dist/runtime/grokEngineBrokerMetering.d.ts.map +1 -0
- package/dist/runtime/grokEngineBrokerMetering.js +34 -0
- package/dist/runtime/grokEngineBrokerTurn.d.ts +82 -0
- package/dist/runtime/grokEngineBrokerTurn.d.ts.map +1 -0
- package/dist/runtime/grokEngineBrokerTurn.js +348 -0
- package/dist/runtime/grokEngineBrokerTurnEnd.d.ts +88 -0
- package/dist/runtime/grokEngineBrokerTurnEnd.d.ts.map +1 -0
- package/dist/runtime/grokEngineBrokerTurnEnd.js +148 -0
- package/dist/runtime/grokInferenceClientConfig.d.ts +41 -0
- package/dist/runtime/grokInferenceClientConfig.d.ts.map +1 -0
- package/dist/runtime/grokInferenceClientConfig.js +62 -0
- package/dist/runtime/grokInferenceGrants.d.ts +77 -0
- package/dist/runtime/grokInferenceGrants.d.ts.map +1 -0
- package/dist/runtime/grokInferenceGrants.js +116 -0
- package/dist/runtime/grokInferenceProxy.d.ts +29 -0
- package/dist/runtime/grokInferenceProxy.d.ts.map +1 -0
- package/dist/runtime/grokInferenceProxy.js +85 -0
- package/dist/runtime/grokInferenceProxyRequest.d.ts +23 -0
- package/dist/runtime/grokInferenceProxyRequest.d.ts.map +1 -0
- package/dist/runtime/grokInferenceProxyRequest.js +63 -0
- package/dist/runtime/grokSlotPreflightReceipt.d.ts +70 -0
- package/dist/runtime/grokSlotPreflightReceipt.d.ts.map +1 -0
- package/dist/runtime/grokSlotPreflightReceipt.js +101 -0
- package/dist/runtime/grokSubscriptionRealm.d.ts +4 -0
- package/dist/runtime/grokSubscriptionRealm.d.ts.map +1 -0
- package/dist/runtime/grokSubscriptionRealm.js +435 -0
- package/dist/runtime/grokSubscriptionRealmTypes.d.ts +26 -0
- package/dist/runtime/grokSubscriptionRealmTypes.d.ts.map +1 -0
- package/dist/runtime/grokSubscriptionRealmTypes.js +1 -0
- package/dist/runtime/grokWorkerAttestation.d.ts +175 -0
- package/dist/runtime/grokWorkerAttestation.d.ts.map +1 -0
- package/dist/runtime/grokWorkerAttestation.js +266 -0
- package/dist/runtime/grokWorkerDenyPlacement.d.ts +80 -0
- package/dist/runtime/grokWorkerDenyPlacement.d.ts.map +1 -0
- package/dist/runtime/grokWorkerDenyPlacement.js +128 -0
- package/dist/runtime/grokWorkerHomeAttestation.d.ts +32 -0
- package/dist/runtime/grokWorkerHomeAttestation.d.ts.map +1 -0
- package/dist/runtime/grokWorkerHomeAttestation.js +75 -0
- package/dist/runtime/grokWorkerSandboxProfile.d.ts +27 -0
- package/dist/runtime/grokWorkerSandboxProfile.d.ts.map +1 -0
- package/dist/runtime/grokWorkerSandboxProfile.js +44 -0
- package/dist/runtime/grokWorkerTmpAttestation.d.ts +55 -0
- package/dist/runtime/grokWorkerTmpAttestation.d.ts.map +1 -0
- package/dist/runtime/grokWorkerTmpAttestation.js +63 -0
- package/dist/runtime/index.d.ts +31 -0
- package/dist/runtime/index.d.ts.map +1 -0
- package/dist/runtime/index.js +27 -0
- package/dist/runtime/inferenceUsageLedger.d.ts +38 -0
- package/dist/runtime/inferenceUsageLedger.d.ts.map +1 -0
- package/dist/runtime/inferenceUsageLedger.js +53 -0
- package/dist/runtime/mcpToolResult.d.ts +127 -0
- package/dist/runtime/mcpToolResult.d.ts.map +1 -0
- package/dist/runtime/mcpToolResult.js +214 -0
- package/dist/runtime/moltnetMachineRead.d.ts +97 -0
- package/dist/runtime/moltnetMachineRead.d.ts.map +1 -0
- package/dist/runtime/moltnetMachineRead.js +183 -0
- package/dist/runtime/native/daimon-engine-broker +0 -0
- package/dist/runtime/organizationRuntime.d.ts +168 -0
- package/dist/runtime/organizationRuntime.d.ts.map +1 -0
- package/dist/runtime/organizationRuntime.js +3 -0
- package/dist/runtime/organizationRuntimeAdmission.d.ts +6 -0
- package/dist/runtime/organizationRuntimeAdmission.d.ts.map +1 -0
- package/dist/runtime/organizationRuntimeAdmission.js +22 -0
- package/dist/runtime/organizationRuntimeControl.d.ts +51 -0
- package/dist/runtime/organizationRuntimeControl.d.ts.map +1 -0
- package/dist/runtime/organizationRuntimeControl.js +283 -0
- package/dist/runtime/organizationRuntimeHost.d.ts +19 -0
- package/dist/runtime/organizationRuntimeHost.d.ts.map +1 -0
- package/dist/runtime/organizationRuntimeHost.js +368 -0
- package/dist/runtime/organizationRuntimeParsing.d.ts +6 -0
- package/dist/runtime/organizationRuntimeParsing.d.ts.map +1 -0
- package/dist/runtime/organizationRuntimeParsing.js +373 -0
- package/dist/runtime/organizationRuntimeReadiness.d.ts +12 -0
- package/dist/runtime/organizationRuntimeReadiness.d.ts.map +1 -0
- package/dist/runtime/organizationRuntimeReadiness.js +67 -0
- package/dist/runtime/organizationRuntimeRecording.d.ts +7 -0
- package/dist/runtime/organizationRuntimeRecording.d.ts.map +1 -0
- package/dist/runtime/organizationRuntimeRecording.js +58 -0
- package/dist/runtime/physicalReadiness.d.ts +59 -0
- package/dist/runtime/physicalReadiness.d.ts.map +1 -0
- package/dist/runtime/physicalReadiness.js +176 -0
- package/dist/runtime/portableCredentialAuth.d.ts +6 -0
- package/dist/runtime/portableCredentialAuth.d.ts.map +1 -0
- package/dist/runtime/portableCredentialAuth.js +70 -0
- package/dist/runtime/portableCredentialMaterial.d.ts +8 -0
- package/dist/runtime/portableCredentialMaterial.d.ts.map +1 -0
- package/dist/runtime/portableCredentialMaterial.js +169 -0
- package/dist/runtime/productionAgentTools.d.ts +5 -0
- package/dist/runtime/productionAgentTools.d.ts.map +1 -0
- package/dist/runtime/productionAgentTools.js +336 -0
- package/dist/runtime/relocateRuntimeConfig.d.ts +14 -0
- package/dist/runtime/relocateRuntimeConfig.d.ts.map +1 -0
- package/dist/runtime/relocateRuntimeConfig.js +38 -0
- package/dist/runtime/runtimeHomeLayout.d.ts +48 -0
- package/dist/runtime/runtimeHomeLayout.d.ts.map +1 -0
- package/dist/runtime/runtimeHomeLayout.js +84 -0
- package/dist/runtime/schedule.d.ts +40 -0
- package/dist/runtime/schedule.d.ts.map +1 -0
- package/dist/runtime/schedule.js +376 -0
- package/dist/runtime/storeCoordination.d.ts +33 -0
- package/dist/runtime/storeCoordination.d.ts.map +1 -0
- package/dist/runtime/storeCoordination.js +117 -0
- package/dist/runtime/taskClock.d.ts +42 -0
- package/dist/runtime/taskClock.d.ts.map +1 -0
- package/dist/runtime/taskClock.js +102 -0
- package/dist/runtime/taskClockProcess.d.ts +17 -0
- package/dist/runtime/taskClockProcess.d.ts.map +1 -0
- package/dist/runtime/taskClockProcess.js +58 -0
- package/dist/runtime/toolResultSpill.d.ts +152 -0
- package/dist/runtime/toolResultSpill.d.ts.map +1 -0
- package/dist/runtime/toolResultSpill.js +351 -0
- package/dist/runtime/turnRequestLedger.d.ts +155 -0
- package/dist/runtime/turnRequestLedger.d.ts.map +1 -0
- package/dist/runtime/turnRequestLedger.js +251 -0
- package/dist/runtime/turnUsageLedger.d.ts +143 -0
- package/dist/runtime/turnUsageLedger.d.ts.map +1 -0
- package/dist/runtime/turnUsageLedger.js +203 -0
- package/dist/runtime/wakeAcceptanceClaimDiagnostics.d.ts +34 -0
- package/dist/runtime/wakeAcceptanceClaimDiagnostics.d.ts.map +1 -0
- package/dist/runtime/wakeAcceptanceClaimDiagnostics.js +79 -0
- package/dist/runtime/wakeAcceptanceIndex.d.ts +55 -0
- package/dist/runtime/wakeAcceptanceIndex.d.ts.map +1 -0
- package/dist/runtime/wakeAcceptanceIndex.js +158 -0
- package/dist/runtime/wakeAcceptanceProcessIdentity.d.ts +25 -0
- package/dist/runtime/wakeAcceptanceProcessIdentity.d.ts.map +1 -0
- package/dist/runtime/wakeAcceptanceProcessIdentity.js +54 -0
- package/dist/runtime/wakeAcceptanceReconciliation.d.ts +211 -0
- package/dist/runtime/wakeAcceptanceReconciliation.d.ts.map +1 -0
- package/dist/runtime/wakeAcceptanceReconciliation.js +289 -0
- package/dist/runtime/wakeAcceptanceRecord.d.ts +25 -0
- package/dist/runtime/wakeAcceptanceRecord.d.ts.map +1 -0
- package/dist/runtime/wakeAcceptanceRecord.js +58 -0
- package/dist/runtime/wakeAcceptanceRetention.d.ts +36 -0
- package/dist/runtime/wakeAcceptanceRetention.d.ts.map +1 -0
- package/dist/runtime/wakeAcceptanceRetention.js +38 -0
- package/dist/runtime/wakeAcceptanceStore.d.ts +113 -0
- package/dist/runtime/wakeAcceptanceStore.d.ts.map +1 -0
- package/dist/runtime/wakeAcceptanceStore.js +561 -0
- package/dist/runtime/wakeAcceptanceTypes.d.ts +179 -0
- package/dist/runtime/wakeAcceptanceTypes.d.ts.map +1 -0
- package/dist/runtime/wakeAcceptanceTypes.js +95 -0
- package/dist/runtime/wakeFuse.d.ts +124 -0
- package/dist/runtime/wakeFuse.d.ts.map +1 -0
- package/dist/runtime/wakeFuse.js +466 -0
- package/dist/runtime/wakeMomentFs.d.ts +27 -0
- package/dist/runtime/wakeMomentFs.d.ts.map +1 -0
- package/dist/runtime/wakeMomentFs.js +223 -0
- package/dist/runtime/wakeMomentHistory.d.ts +26 -0
- package/dist/runtime/wakeMomentHistory.d.ts.map +1 -0
- package/dist/runtime/wakeMomentHistory.js +109 -0
- package/dist/runtime/wakeMomentIo.d.ts +22 -0
- package/dist/runtime/wakeMomentIo.d.ts.map +1 -0
- package/dist/runtime/wakeMomentIo.js +114 -0
- package/dist/runtime/wakeMomentRecorder.d.ts +33 -0
- package/dist/runtime/wakeMomentRecorder.d.ts.map +1 -0
- package/dist/runtime/wakeMomentRecorder.js +81 -0
- package/dist/runtime/wakeMomentRetention.d.ts +7 -0
- package/dist/runtime/wakeMomentRetention.d.ts.map +1 -0
- package/dist/runtime/wakeMomentRetention.js +143 -0
- package/dist/runtime/wakeMomentRows.d.ts +8 -0
- package/dist/runtime/wakeMomentRows.d.ts.map +1 -0
- package/dist/runtime/wakeMomentRows.js +66 -0
- package/dist/runtime/wakeMomentSnapshot.d.ts +56 -0
- package/dist/runtime/wakeMomentSnapshot.d.ts.map +1 -0
- package/dist/runtime/wakeMomentSnapshot.js +248 -0
- package/package.json +22 -11
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import { setTimeout as delay } from "node:timers/promises";
|
|
2
|
+
import { performance } from "node:perf_hooks";
|
|
3
|
+
import { WakeTransitionLockBlockedError } from "./wakeAcceptanceProcessIdentity.js";
|
|
4
|
+
export class WakeExecutionClaimLostError extends Error {
|
|
5
|
+
detail;
|
|
6
|
+
constructor(detail, cause) {
|
|
7
|
+
super(`wake execution claim was lost${detail === undefined ? "" : `: step=${detail.step} assertion=${detail.assertion} ${JSON.stringify({ ...detail, expected: diagnosticIdentity(detail.expected), current: diagnosticIdentity(detail.current) })}`}`, { cause });
|
|
8
|
+
this.detail = detail;
|
|
9
|
+
this.name = "WakeExecutionClaimLostError";
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
export class WakeTransitionLockContentionError extends WakeExecutionClaimLostError {
|
|
13
|
+
constructor(detail) { super(detail); this.name = "WakeTransitionLockContentionError"; }
|
|
14
|
+
}
|
|
15
|
+
const lockWaitTiming = { now: () => performance.now(), sleep: async (ms) => { await delay(ms); } };
|
|
16
|
+
/**
|
|
17
|
+
* Only an occupied lock is retried; claim mismatches and I/O failures are not.
|
|
18
|
+
* The 250 ms budget bounds attempt starts and requested sleeps. Filesystem I/O
|
|
19
|
+
* is not cancellable, so an admitted acquisition can finish after the deadline.
|
|
20
|
+
* Keep that lock: callers revalidate the claim before writing and release the
|
|
21
|
+
* lock in finally, so late acquisition cannot authorize a stale claim.
|
|
22
|
+
*/
|
|
23
|
+
export async function waitForClaimTransitionLock(acquire, read, acceptanceId, claim, step, timing = lockWaitTiming) {
|
|
24
|
+
const deadline = timing.now() + 250;
|
|
25
|
+
for (let attempt = 0;; attempt++) {
|
|
26
|
+
if (attempt >= 26 || timing.now() >= deadline) {
|
|
27
|
+
let current;
|
|
28
|
+
try {
|
|
29
|
+
current = await read();
|
|
30
|
+
}
|
|
31
|
+
catch (cause) {
|
|
32
|
+
throw new WakeExecutionClaimLostError({ step, assertion: "transition_lock_read", acceptance_id: acceptanceId, expected: claim, current: null }, cause);
|
|
33
|
+
}
|
|
34
|
+
throw new WakeTransitionLockContentionError({ step, assertion: "transition_lock_contended", acceptance_id: acceptanceId, expected: claim, current: current ?? null, lock: current ?? null });
|
|
35
|
+
}
|
|
36
|
+
let lock;
|
|
37
|
+
try {
|
|
38
|
+
lock = await acquire();
|
|
39
|
+
}
|
|
40
|
+
catch (cause) {
|
|
41
|
+
if (cause instanceof WakeTransitionLockBlockedError)
|
|
42
|
+
throw cause;
|
|
43
|
+
throw new WakeExecutionClaimLostError({ step, assertion: "transition_lock_acquire", acceptance_id: acceptanceId, expected: claim, current: null }, cause);
|
|
44
|
+
}
|
|
45
|
+
if (lock !== undefined)
|
|
46
|
+
return lock;
|
|
47
|
+
const remaining = deadline - timing.now();
|
|
48
|
+
if (remaining > 0 && attempt < 25)
|
|
49
|
+
await timing.sleep(Math.min(10, remaining));
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
function diagnosticIdentity(value) {
|
|
53
|
+
if (value === null || typeof value === "string" || "pid" in value)
|
|
54
|
+
return value;
|
|
55
|
+
// Membership can contain 32 UUIDs. Keep both identities and the lock visible
|
|
56
|
+
// through the host's 2 KiB diagnostic bound; the typed detail keeps membership.
|
|
57
|
+
const { acceptance_ids: _members, ...identity } = value;
|
|
58
|
+
return identity;
|
|
59
|
+
}
|
|
60
|
+
/** Read errors retain their errno as cause; no record/event/credential data enters diagnostics. */
|
|
61
|
+
export async function readExpectedClaim(read, acceptanceId, expected, step, now, lock) {
|
|
62
|
+
let current;
|
|
63
|
+
try {
|
|
64
|
+
current = await read();
|
|
65
|
+
}
|
|
66
|
+
catch (cause) {
|
|
67
|
+
const assertion = cause?.code === "ENOENT" ? "claim_missing" : "claim_read";
|
|
68
|
+
throw new WakeExecutionClaimLostError({ step, assertion, acceptance_id: acceptanceId, expected, current: null, ...(lock === undefined ? {} : { lock }) }, cause);
|
|
69
|
+
}
|
|
70
|
+
const assertion = !(current.acceptance_id === acceptanceId || current.acceptance_ids?.includes(acceptanceId)) ? "claim_membership"
|
|
71
|
+
: current.acceptance_id !== expected.acceptance_id ? "claim_acceptance_id"
|
|
72
|
+
: current.owner_id !== expected.owner_id ? "claim_owner_id"
|
|
73
|
+
: current.generation !== expected.generation ? "claim_generation"
|
|
74
|
+
: current.expires_at !== expected.expires_at ? "claim_expires_at"
|
|
75
|
+
: Date.parse(current.expires_at) <= now() ? "claim_expired" : undefined;
|
|
76
|
+
if (assertion !== undefined)
|
|
77
|
+
throw new WakeExecutionClaimLostError({ step, assertion, acceptance_id: acceptanceId, expected, current, ...(lock === undefined ? {} : { lock }) });
|
|
78
|
+
return current;
|
|
79
|
+
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
export type WakeAcceptanceStat = Readonly<{
|
|
2
|
+
ino: bigint;
|
|
3
|
+
size: bigint;
|
|
4
|
+
mtimeNs: bigint;
|
|
5
|
+
ctimeNs: bigint;
|
|
6
|
+
}>;
|
|
7
|
+
export type WakeAcceptanceIndexSource = Readonly<{
|
|
8
|
+
/** Opened-handle stat of the store directory. */
|
|
9
|
+
directoryStat: () => Promise<WakeAcceptanceStat>;
|
|
10
|
+
/** Record file names, after the store's own root validation and bounds. */
|
|
11
|
+
files: () => Promise<readonly string[]>;
|
|
12
|
+
/** Acceptance id of one record, read through every safety check of the store. */
|
|
13
|
+
readId: (file: string) => Promise<string>;
|
|
14
|
+
/** Identity stamp of one record file; undefined when it is gone. */
|
|
15
|
+
fileStat: (file: string) => Promise<WakeAcceptanceStat | undefined>;
|
|
16
|
+
}>;
|
|
17
|
+
/**
|
|
18
|
+
* Acceptance-id → record-file index. Own writes keep it current; a directory
|
|
19
|
+
* whose stamp moved since the last sync (another process, or this one) is
|
|
20
|
+
* re-listed, and only record files whose own stamp moved are read again. A miss
|
|
21
|
+
* against an unchanged directory reads no record file.
|
|
22
|
+
*/
|
|
23
|
+
export declare class WakeAcceptanceIndex {
|
|
24
|
+
private readonly root;
|
|
25
|
+
private readonly source;
|
|
26
|
+
private readonly nowNs;
|
|
27
|
+
private readonly byId;
|
|
28
|
+
private readonly byFile;
|
|
29
|
+
private synced;
|
|
30
|
+
/** Bumped by every binding change made outside a sync; a sync that saw one never vouches for the directory. */
|
|
31
|
+
private mutations;
|
|
32
|
+
private refreshing;
|
|
33
|
+
constructor(root: string, source: WakeAcceptanceIndexSource, nowNs?: () => bigint);
|
|
34
|
+
/**
|
|
35
|
+
* The record bound to this id, verified to still carry it. Unknown and
|
|
36
|
+
* compacted ids are polled, so a miss against an unchanged directory reads
|
|
37
|
+
* no record file.
|
|
38
|
+
*/
|
|
39
|
+
find<T extends Readonly<{
|
|
40
|
+
acceptance_id: string;
|
|
41
|
+
}>>(acceptanceId: string, read: (file: string) => Promise<T | undefined>): Promise<T | undefined>;
|
|
42
|
+
/** Binds a record this process wrote; its file stamp is learned on the next sync. */
|
|
43
|
+
set(acceptanceId: string, file: string): void;
|
|
44
|
+
/** Drops a record file this process deleted. */
|
|
45
|
+
forget(file: string): void;
|
|
46
|
+
/** Brings the index level with the directory; a no-op while the directory is unchanged. Single-flight. */
|
|
47
|
+
refresh(): Promise<void>;
|
|
48
|
+
private refreshNow;
|
|
49
|
+
private scan;
|
|
50
|
+
/** A binding found stale: drop only what still says so, never a newer binding of the same file. */
|
|
51
|
+
private unbind;
|
|
52
|
+
private drop;
|
|
53
|
+
private bind;
|
|
54
|
+
}
|
|
55
|
+
//# sourceM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,CAAC,SAAS,QAAQ,CAAC;QAAE,aAAa,EAAE,MAAM,CAAA;KAAE,CAAC,EAAE,YAAY,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC,CAAC,GAAG,SAAS,CAAC,GAAG,OAAO,CAAC,CAAC,GAAG,SAAS,CAAC;IAYvJ,qFAAqF;IACrF,GAAG,CAAC,YAAY,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,IAAI;IAK7C,gDAAgD;IAChD,MAAM,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI;IAC1B,0GAA0G;IACpG,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC;YAMhB,UAAU;YAiBV,IAAI;IAiBlB,mGAAmG;IACnG,OAAO,CAAC,MAAM;IAMd,OAAO,CAAC,IAAI;IAMZ,OAAO,CAAC,IAAI;CAMb"}
|
|
@@ -0,0 +1,158 @@
|
|
|
1
|
+
import path from "node:path";
|
|
2
|
+
import { MAX_WAKE_ACCEPTANCE_RECORDS } from "./wakeAcceptanceRetention.js";
|
|
3
|
+
/**
|
|
4
|
+
* A stamp younger than this may share a coarse filesystem timestamp tick with
|
|
5
|
+
* a write that lands after it was taken, so it is never trusted to prove that
|
|
6
|
+
* nothing changed (the racy-timestamp rule).
|
|
7
|
+
*/
|
|
8
|
+
const RACY_WINDOW_NS = 2000000000n;
|
|
9
|
+
/**
|
|
10
|
+
* Own writes bind without a sync, so another process compacting behind a host
|
|
11
|
+
* that only ever hits could leave bindings for files that are gone. Past this
|
|
12
|
+
* many the index is dropped and the next miss rebuilds it from the directory.
|
|
13
|
+
*/
|
|
14
|
+
const MAX_INDEX_ENTRIES = MAX_WAKE_ACCEPTANCE_RECORDS * 2;
|
|
15
|
+
/**
|
|
16
|
+
* Acceptance-id → record-file index. Own writes keep it current; a directory
|
|
17
|
+
* whose stamp moved since the last sync (another process, or this one) is
|
|
18
|
+
* re-listed, and only record files whose own stamp moved are read again. A miss
|
|
19
|
+
* against an unchanged directory reads no record file.
|
|
20
|
+
*/
|
|
21
|
+
export class WakeAcceptanceIndex {
|
|
22
|
+
root;
|
|
23
|
+
source;
|
|
24
|
+
nowNs;
|
|
25
|
+
byId = new Map();
|
|
26
|
+
byFile = new Map();
|
|
27
|
+
synced;
|
|
28
|
+
/** Bumped by every binding change made outside a sync; a sync that saw one never vouches for the directory. */
|
|
29
|
+
mutations = 0;
|
|
30
|
+
refreshing;
|
|
31
|
+
constructor(root, source, nowNs = () => BigInt(Date.now()) * 1000000n) {
|
|
32
|
+
this.root = root;
|
|
33
|
+
this.source = source;
|
|
34
|
+
this.nowNs = nowNs;
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* The record bound to this id, verified to still carry it. Unknown and
|
|
38
|
+
* compacted ids are polled, so a miss against an unchanged directory reads
|
|
39
|
+
* no record file.
|
|
40
|
+
*/
|
|
41
|
+
async find(acceptanceId, read) {
|
|
42
|
+
for (let attempt = 0; attempt < 2; attempt += 1) {
|
|
43
|
+
const known = this.byId.get(acceptanceId);
|
|
44
|
+
if (known !== undefined) {
|
|
45
|
+
const record = await read(known);
|
|
46
|
+
if (record?.acceptance_id === acceptanceId)
|
|
47
|
+
return record;
|
|
48
|
+
this.unbind(acceptanceId, known);
|
|
49
|
+
}
|
|
50
|
+
if (attempt === 0)
|
|
51
|
+
await this.refresh();
|
|
52
|
+
}
|
|
53
|
+
return undefined;
|
|
54
|
+
}
|
|
55
|
+
/** Binds a record this process wrote; its file stamp is learned on the next sync. */
|
|
56
|
+
set(acceptanceId, file) {
|
|
57
|
+
this.mutations += 1;
|
|
58
|
+
if (this.byFile.size >= MAX_INDEX_ENTRIES) {
|
|
59
|
+
this.byFile.clear();
|
|
60
|
+
this.byId.clear();
|
|
61
|
+
this.synced = undefined;
|
|
62
|
+
}
|
|
63
|
+
this.bind(file, acceptanceId, undefined);
|
|
64
|
+
}
|
|
65
|
+
/** Drops a record file this process deleted. */
|
|
66
|
+
forget(file) { this.mutations += 1; this.drop(file); }
|
|
67
|
+
/** Brings the index level with the directory; a no-op while the directory is unchanged. Single-flight. */
|
|
68
|
+
async refresh() {
|
|
69
|
+
while (this.refreshing !== undefined)
|
|
70
|
+
await this.refreshing.catch(() => undefined);
|
|
71
|
+
const run = this.refreshNow();
|
|
72
|
+
this.refreshing = run;
|
|
73
|
+
try {
|
|
74
|
+
await run;
|
|
75
|
+
}
|
|
76
|
+
finally {
|
|
77
|
+
if (this.refreshing === run)
|
|
78
|
+
this.refreshing = undefined;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
async refreshNow() {
|
|
82
|
+
const startedAt = this.nowNs();
|
|
83
|
+
const directory = await this.source.directoryStat();
|
|
84
|
+
const directoryStamp = stampOf(directory);
|
|
85
|
+
if (this.synced === directoryStamp)
|
|
86
|
+
return;
|
|
87
|
+
const mutations = this.mutations;
|
|
88
|
+
const listed = (await this.source.files()).map((name) => path.join(this.root, name));
|
|
89
|
+
// Prune what the directory no longer lists even when a record below fails to
|
|
90
|
+
// read, so the maps stay bounded by the store's own record bound.
|
|
91
|
+
const present = new Set(listed);
|
|
92
|
+
try {
|
|
93
|
+
await this.scan(listed, present);
|
|
94
|
+
}
|
|
95
|
+
finally {
|
|
96
|
+
for (const file of [...this.byFile.keys()])
|
|
97
|
+
if (!present.has(file))
|
|
98
|
+
this.drop(file);
|
|
99
|
+
}
|
|
100
|
+
// Vouch for the directory only if nothing rebound while listing and its stamp
|
|
101
|
+
// was already settled when it was taken (the racy-timestamp rule).
|
|
102
|
+
this.synced = this.mutations === mutations && !racy(directory, startedAt) ? directoryStamp : undefined;
|
|
103
|
+
}
|
|
104
|
+
async scan(listed, present) {
|
|
105
|
+
for (const file of listed) {
|
|
106
|
+
const seenAt = this.nowNs();
|
|
107
|
+
const stat = await this.source.fileStat(file);
|
|
108
|
+
if (stat === undefined) {
|
|
109
|
+
present.delete(file);
|
|
110
|
+
continue;
|
|
111
|
+
}
|
|
112
|
+
const stamp = racy(stat, seenAt) ? undefined : stampOf(stat);
|
|
113
|
+
const known = this.byFile.get(file);
|
|
114
|
+
if (known !== undefined && known.stamp !== undefined && known.stamp === stamp)
|
|
115
|
+
continue;
|
|
116
|
+
let id;
|
|
117
|
+
try {
|
|
118
|
+
id = await this.source.readId(file);
|
|
119
|
+
}
|
|
120
|
+
catch (error) {
|
|
121
|
+
if (error.code !== "ENOENT")
|
|
122
|
+
throw error;
|
|
123
|
+
present.delete(file);
|
|
124
|
+
continue;
|
|
125
|
+
}
|
|
126
|
+
this.bind(file, id, stamp);
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
/** A binding found stale: drop only what still says so, never a newer binding of the same file. */
|
|
130
|
+
unbind(acceptanceId, file) {
|
|
131
|
+
this.mutations += 1;
|
|
132
|
+
if (this.byId.get(acceptanceId) === file)
|
|
133
|
+
this.byId.delete(acceptanceId);
|
|
134
|
+
if (this.byFile.get(file)?.id === acceptanceId)
|
|
135
|
+
this.byFile.delete(file);
|
|
136
|
+
this.synced = undefined;
|
|
137
|
+
}
|
|
138
|
+
drop(file) {
|
|
139
|
+
const entry = this.byFile.get(file);
|
|
140
|
+
if (entry !== undefined && this.byId.get(entry.id) === file)
|
|
141
|
+
this.byId.delete(entry.id);
|
|
142
|
+
this.byFile.delete(file);
|
|
143
|
+
this.synced = undefined;
|
|
144
|
+
}
|
|
145
|
+
bind(file, acceptanceId, stamp) {
|
|
146
|
+
const prior = this.byFile.get(file);
|
|
147
|
+
if (prior !== undefined && prior.id !== acceptanceId && this.byId.get(prior.id) === file)
|
|
148
|
+
this.byId.delete(prior.id);
|
|
149
|
+
this.byFile.set(file, { id: acceptanceId, ...(stamp === undefined ? {} : { stamp }) });
|
|
150
|
+
this.byId.set(acceptanceId, file);
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
/** A stamp taken within the window of its own last change may share a tick with a later write. */
|
|
154
|
+
function racy(stat, observedAt) {
|
|
155
|
+
const changed = stat.mtimeNs > stat.ctimeNs ? stat.mtimeNs : stat.ctimeNs;
|
|
156
|
+
return observedAt - changed < RACY_WINDOW_NS;
|
|
157
|
+
}
|
|
158
|
+
function stampOf(stat) { return `${stat.ino}:${stat.size}:${stat.mtimeNs}:${stat.ctimeNs}`; }
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export type TransitionLock = Readonly<{
|
|
2
|
+
owner_id: string;
|
|
3
|
+
generation: string;
|
|
4
|
+
pid: number;
|
|
5
|
+
process_start: string;
|
|
6
|
+
boot_id: string;
|
|
7
|
+
pid_namespace_dev: number;
|
|
8
|
+
pid_namespace_ino: number;
|
|
9
|
+
}>;
|
|
10
|
+
type BlockedLockDetail = Readonly<{
|
|
11
|
+
step: string;
|
|
12
|
+
acceptance_id: string;
|
|
13
|
+
expected: Omit<TransitionLock, "owner_id" | "generation">;
|
|
14
|
+
current: TransitionLock;
|
|
15
|
+
}>;
|
|
16
|
+
export declare class WakeTransitionLockBlockedError extends Error {
|
|
17
|
+
readonly detail?: BlockedLockDetail | undefined;
|
|
18
|
+
readonly code: "offline_reconciliation_required";
|
|
19
|
+
constructor(detail?: BlockedLockDetail | undefined);
|
|
20
|
+
}
|
|
21
|
+
export declare function sameNamespace(left: Pick<TransitionLock, "pid_namespace_dev" | "pid_namespace_ino">, right: Pick<TransitionLock, "pid_namespace_dev" | "pid_namespace_ino">): boolean;
|
|
22
|
+
export declare function currentProcessIdentity(): Promise<Omit<TransitionLock, "owner_id" | "generation">>;
|
|
23
|
+
export declare function processIsAlive(lock: TransitionLock): Promise<boolean>;
|
|
24
|
+
export {};
|
|
25
|
+
//# sourceMappingURL=wakeAcceptanceProcessIdentity.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"wakeAcceptanceProcessIdentity.d.ts","sourceRoot":"","sources":["../../src/runtime/wakeAcceptanceProcessIdentity.ts"],"names":[],"mappings":"AACA,MAAM,MAAM,cAAc,GAAG,QAAQ,CAAC;IAAE,QAAQ,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAC;IAAC,aAAa,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAC;IAAC,iBAAiB,EAAE,MAAM,CAAC;IAAC,iBAAiB,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AAC3L,KAAK,iBAAiB,GAAG,QAAQ,CAAC;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,aAAa,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,IAAI,CAAC,cAAc,EAAE,UAAU,GAAG,YAAY,CAAC,CAAC;IAAC,OAAO,EAAE,cAAc,CAAA;CAAE,CAAC,CAAC;AAC/J,qBAAa,8BAA+B,SAAQ,KAAK;IAE3C,QAAQ,CAAC,MAAM,CAAC,EAAE,iBAAiB;IAD/C,QAAQ,CAAC,IAAI,EAAG,iCAAiC,CAAU;gBACtC,MAAM,CAAC,EAAE,iBAAiB,YAAA;CAChD;AACD,wBAAgB,aAAa,CAAC,IAAI,EAAE,IAAI,CAAC,cAAc,EAAE,mBAAmB,GAAG,mBAAmB,CAAC,EAAE,KAAK,EAAE,IAAI,CAAC,cAAc,EAAE,mBAAmB,GAAG,mBAAmB,CAAC,GAAG,OAAO,CAAqH;AAC1S,wBAAsB,sBAAsB,IAAI,OAAO,CAAC,IAAI,CAAC,cAAc,EAAE,UAAU,GAAG,YAAY,CAAC,CAAC,CAKvG;AACD,wBAAsB,cAAc,CAAC,IAAI,EAAE,cAAc,GAAG,OAAO,CAAC,OAAO,CAAC,CAO3E"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { readFile, stat } from "node:fs/promises";
|
|
2
|
+
export class WakeTransitionLockBlockedError extends Error {
|
|
3
|
+
detail;
|
|
4
|
+
code = "offline_reconciliation_required";
|
|
5
|
+
constructor(detail) {
|
|
6
|
+
super(`wake transition lock requires offline reconciliation${detail === undefined ? "" : `: step=${detail.step} assertion=transition_lock_namespace ${JSON.stringify(detail)}`}`);
|
|
7
|
+
this.detail = detail;
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
export function sameNamespace(left, right) { return left.pid_namespace_dev === right.pid_namespace_dev && left.pid_namespace_ino === right.pid_namespace_ino; }
|
|
11
|
+
export async function currentProcessIdentity() {
|
|
12
|
+
if (process.platform !== "linux")
|
|
13
|
+
throw new Error("wake transition locks require Linux process identity");
|
|
14
|
+
const boot_id = (await readFile("/proc/sys/kernel/random/boot_id", "utf8")).trim();
|
|
15
|
+
if (!boot_id)
|
|
16
|
+
throw new Error("wake transition owner identity is invalid");
|
|
17
|
+
return { pid: process.pid, process_start: await linuxProcessStart(process.pid), boot_id, ...await linuxPidNamespace() };
|
|
18
|
+
}
|
|
19
|
+
export async function processIsAlive(lock) {
|
|
20
|
+
if (process.platform !== "linux")
|
|
21
|
+
throw new Error("wake transition lock liveness is unsupported");
|
|
22
|
+
if (!sameNamespace(lock, await linuxPidNamespace()))
|
|
23
|
+
throw new WakeTransitionLockBlockedError();
|
|
24
|
+
const boot = (await readFile("/proc/sys/kernel/random/boot_id", "utf8")).trim();
|
|
25
|
+
if (!boot)
|
|
26
|
+
throw new Error("wake transition owner liveness cannot be proven");
|
|
27
|
+
if (boot !== lock.boot_id)
|
|
28
|
+
return false;
|
|
29
|
+
try {
|
|
30
|
+
return await linuxProcessStart(lock.pid) === lock.process_start;
|
|
31
|
+
}
|
|
32
|
+
catch (error) {
|
|
33
|
+
if (error.code === "ENOENT")
|
|
34
|
+
return false;
|
|
35
|
+
throw new Error("wake transition owner liveness cannot be proven");
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
async function linuxProcessStart(pid) {
|
|
39
|
+
const stat = await readFile(`/proc/${pid}/stat`, "utf8");
|
|
40
|
+
const close = stat.lastIndexOf(")");
|
|
41
|
+
const fields = stat.slice(close + 2).trim().split(/\s+/u);
|
|
42
|
+
const start = fields[19];
|
|
43
|
+
if (close < 0 || start === undefined || !/^\d+$/u.test(start))
|
|
44
|
+
throw new Error("wake transition owner identity is invalid");
|
|
45
|
+
return start;
|
|
46
|
+
}
|
|
47
|
+
async function linuxPidNamespace() {
|
|
48
|
+
const identity = await stat("/proc/self/ns/pid");
|
|
49
|
+
const pid_namespace_dev = Number(identity.dev);
|
|
50
|
+
const pid_namespace_ino = Number(identity.ino);
|
|
51
|
+
if (!Number.isSafeInteger(pid_namespace_dev) || !Number.isSafeInteger(pid_namespace_ino) || pid_namespace_dev < 1 || pid_namespace_ino < 1)
|
|
52
|
+
throw new Error("wake transition owner identity is invalid");
|
|
53
|
+
return { pid_namespace_dev, pid_namespace_ino };
|
|
54
|
+
}
|
|
@@ -0,0 +1,211 @@
|
|
|
1
|
+
import { open } from "node:fs/promises";
|
|
2
|
+
import { type StoreHostRegistration, type StoreHostRegistrationIdentity } from "./storeCoordination.js";
|
|
3
|
+
export declare const OFFLINE_RECONCILIATION_VERSION: "noopolis.daimon.offline-transition-reconciliation.v1";
|
|
4
|
+
export declare const OFFLINE_RECONCILIATION_BLOCKED_CODE: "offline_reconciliation_required";
|
|
5
|
+
declare const RECEIPT_VERSION: "noopolis.daimon.offline-transition-reconciliation-receipt.v1";
|
|
6
|
+
export declare const OFFLINE_RECONCILIATION_REQUEST_SCHEMA: {
|
|
7
|
+
readonly $schema: "https://json-schema.org/draft/2020-12/schema";
|
|
8
|
+
readonly $id: "noopolis.daimon.offline-transition-reconciliation.v1";
|
|
9
|
+
readonly type: "object";
|
|
10
|
+
readonly additionalProperties: false;
|
|
11
|
+
readonly required: readonly ["version", "agent_id", "delivery_id", "store", "lock", "attestation"];
|
|
12
|
+
readonly properties: {
|
|
13
|
+
readonly version: {
|
|
14
|
+
readonly const: "noopolis.daimon.offline-transition-reconciliation.v1";
|
|
15
|
+
};
|
|
16
|
+
readonly agent_id: {
|
|
17
|
+
readonly type: "string";
|
|
18
|
+
readonly minLength: 1;
|
|
19
|
+
readonly maxLength: 16384;
|
|
20
|
+
};
|
|
21
|
+
readonly delivery_id: {
|
|
22
|
+
readonly type: "string";
|
|
23
|
+
readonly minLength: 1;
|
|
24
|
+
readonly maxLength: 16384;
|
|
25
|
+
};
|
|
26
|
+
readonly store: {
|
|
27
|
+
readonly type: "object";
|
|
28
|
+
readonly additionalProperties: false;
|
|
29
|
+
readonly required: readonly ["dev", "ino"];
|
|
30
|
+
readonly properties: {
|
|
31
|
+
readonly dev: {
|
|
32
|
+
readonly type: "integer";
|
|
33
|
+
readonly minimum: 1;
|
|
34
|
+
};
|
|
35
|
+
readonly ino: {
|
|
36
|
+
readonly type: "integer";
|
|
37
|
+
readonly minimum: 1;
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
readonly lock: {
|
|
42
|
+
readonly type: "object";
|
|
43
|
+
readonly additionalProperties: false;
|
|
44
|
+
readonly required: readonly ["dev", "ino", "owner_id", "generation", "pid", "process_start", "boot_id", "pid_namespace_dev", "pid_namespace_ino"];
|
|
45
|
+
readonly properties: {
|
|
46
|
+
readonly dev: {
|
|
47
|
+
readonly type: "integer";
|
|
48
|
+
readonly minimum: 1;
|
|
49
|
+
};
|
|
50
|
+
readonly ino: {
|
|
51
|
+
readonly type: "integer";
|
|
52
|
+
readonly minimum: 1;
|
|
53
|
+
};
|
|
54
|
+
readonly owner_id: {
|
|
55
|
+
readonly type: "string";
|
|
56
|
+
};
|
|
57
|
+
readonly generation: {
|
|
58
|
+
readonly type: "string";
|
|
59
|
+
};
|
|
60
|
+
readonly pid: {
|
|
61
|
+
readonly type: "integer";
|
|
62
|
+
readonly minimum: 1;
|
|
63
|
+
};
|
|
64
|
+
readonly process_start: {
|
|
65
|
+
readonly type: "string";
|
|
66
|
+
};
|
|
67
|
+
readonly boot_id: {
|
|
68
|
+
readonly type: "string";
|
|
69
|
+
};
|
|
70
|
+
readonly pid_namespace_dev: {
|
|
71
|
+
readonly type: "integer";
|
|
72
|
+
readonly minimum: 1;
|
|
73
|
+
};
|
|
74
|
+
readonly pid_namespace_ino: {
|
|
75
|
+
readonly type: "integer";
|
|
76
|
+
readonly minimum: 1;
|
|
77
|
+
};
|
|
78
|
+
};
|
|
79
|
+
};
|
|
80
|
+
readonly attestation: {
|
|
81
|
+
readonly type: "object";
|
|
82
|
+
readonly additionalProperties: false;
|
|
83
|
+
readonly required: readonly ["version", "authority_id", "attestation_id", "state", "proof"];
|
|
84
|
+
readonly properties: {
|
|
85
|
+
readonly version: {
|
|
86
|
+
readonly const: "noopolis.deployment.container-quiescence.v1";
|
|
87
|
+
};
|
|
88
|
+
readonly authority_id: {
|
|
89
|
+
readonly type: "string";
|
|
90
|
+
readonly minLength: 1;
|
|
91
|
+
readonly maxLength: 16384;
|
|
92
|
+
};
|
|
93
|
+
readonly attestation_id: {
|
|
94
|
+
readonly type: "string";
|
|
95
|
+
readonly minLength: 1;
|
|
96
|
+
readonly maxLength: 16384;
|
|
97
|
+
};
|
|
98
|
+
readonly state: {
|
|
99
|
+
readonly enum: readonly ["absent", "quiescent"];
|
|
100
|
+
};
|
|
101
|
+
readonly proof: {
|
|
102
|
+
readonly type: "string";
|
|
103
|
+
readonly minLength: 1;
|
|
104
|
+
readonly maxLength: 16384;
|
|
105
|
+
};
|
|
106
|
+
};
|
|
107
|
+
};
|
|
108
|
+
};
|
|
109
|
+
};
|
|
110
|
+
type Identity = Readonly<{
|
|
111
|
+
dev: number;
|
|
112
|
+
ino: number;
|
|
113
|
+
}>;
|
|
114
|
+
type Lock = Readonly<{
|
|
115
|
+
dev: number;
|
|
116
|
+
ino: number;
|
|
117
|
+
owner_id: string;
|
|
118
|
+
generation: string;
|
|
119
|
+
pid: number;
|
|
120
|
+
process_start: string;
|
|
121
|
+
boot_id: string;
|
|
122
|
+
pid_namespace_dev: number;
|
|
123
|
+
pid_namespace_ino: number;
|
|
124
|
+
}>;
|
|
125
|
+
type Lease = Readonly<{
|
|
126
|
+
owner_id: string;
|
|
127
|
+
pid: number;
|
|
128
|
+
process_start: string;
|
|
129
|
+
boot_id: string;
|
|
130
|
+
pid_namespace_dev: number;
|
|
131
|
+
pid_namespace_ino: number;
|
|
132
|
+
}>;
|
|
133
|
+
export type OfflineDeploymentAttestation = Readonly<{
|
|
134
|
+
version: "noopolis.deployment.container-quiescence.v1";
|
|
135
|
+
authority_id: string;
|
|
136
|
+
attestation_id: string;
|
|
137
|
+
state: "absent" | "quiescent";
|
|
138
|
+
proof: string;
|
|
139
|
+
}>;
|
|
140
|
+
export type OfflineTransitionReconciliationRequest = Readonly<{
|
|
141
|
+
version: typeof OFFLINE_RECONCILIATION_VERSION;
|
|
142
|
+
agent_id: string;
|
|
143
|
+
delivery_id: string;
|
|
144
|
+
store: Identity;
|
|
145
|
+
lock: Lock;
|
|
146
|
+
attestation: OfflineDeploymentAttestation;
|
|
147
|
+
}>;
|
|
148
|
+
export type OfflineTransitionReconciliationAuthorizationContext = Readonly<{
|
|
149
|
+
version: "noopolis.daimon.offline-transition-authorization-context.v1";
|
|
150
|
+
deployment_identity: string;
|
|
151
|
+
deployment_state: "absent" | "quiescent";
|
|
152
|
+
nonce: string;
|
|
153
|
+
request_digest: string;
|
|
154
|
+
agent_id: string;
|
|
155
|
+
delivery_id: string;
|
|
156
|
+
store: Identity;
|
|
157
|
+
lock: Lock;
|
|
158
|
+
stale_host_registrations: readonly StoreHostRegistrationIdentity[];
|
|
159
|
+
}>;
|
|
160
|
+
export type OfflineTransitionReconciliationProofReceipt = Readonly<{
|
|
161
|
+
request_digest: string;
|
|
162
|
+
nonce: string;
|
|
163
|
+
exclusive_store: true;
|
|
164
|
+
authorized_registration_digests: readonly string[];
|
|
165
|
+
}>;
|
|
166
|
+
export type OfflineTransitionReconciliationReceipt = Readonly<{
|
|
167
|
+
version: typeof RECEIPT_VERSION;
|
|
168
|
+
reconciliation_id: string;
|
|
169
|
+
request_digest: string;
|
|
170
|
+
state: "reconciled";
|
|
171
|
+
reconciled_at: string;
|
|
172
|
+
cleared_registration_digests: readonly string[];
|
|
173
|
+
}>;
|
|
174
|
+
export type OfflineTransitionReconciliationResult = OfflineTransitionReconciliationReceipt | Readonly<{
|
|
175
|
+
version: typeof OFFLINE_RECONCILIATION_VERSION;
|
|
176
|
+
state: "blocked";
|
|
177
|
+
code: typeof OFFLINE_RECONCILIATION_BLOCKED_CODE;
|
|
178
|
+
}>;
|
|
179
|
+
export type OfflineTransitionReconciliationOptions = Readonly<{
|
|
180
|
+
storePath: string;
|
|
181
|
+
verifyDeploymentAttestation: (context: OfflineTransitionReconciliationAuthorizationContext, attestation: OfflineDeploymentAttestation) => Promise<OfflineTransitionReconciliationProofReceipt>;
|
|
182
|
+
leaseIdentity?: () => Promise<Lease>;
|
|
183
|
+
leaseLiveness?: (lease: Lease) => Promise<boolean>;
|
|
184
|
+
hostLiveness?: (host: StoreHostRegistration) => Promise<boolean>;
|
|
185
|
+
}>;
|
|
186
|
+
/** Deployment-only: caller must exclusively mount the private store offline. */
|
|
187
|
+
export declare function reconcileOfflineWakeTransition(value: unknown, options: OfflineTransitionReconciliationOptions): Promise<OfflineTransitionReconciliationResult>;
|
|
188
|
+
export declare function parseOfflineTransitionReconciliationRequest(value: unknown): OfflineTransitionReconciliationRequest;
|
|
189
|
+
export declare class OfflineTransitionReconciliationBlockedError extends Error {
|
|
190
|
+
readonly code: "offline_reconciliation_required";
|
|
191
|
+
constructor();
|
|
192
|
+
}
|
|
193
|
+
/** Normal hosts may start only after the durable offline lease is absent. */
|
|
194
|
+
export declare function assertOfflineReconciliationLeaseAvailable(root: string): Promise<void>;
|
|
195
|
+
/**
|
|
196
|
+
* Publishes `value` at `target` only if `target` does not already exist, and
|
|
197
|
+
* only ever under complete, fsynced content — the name never appears holding a
|
|
198
|
+
* partial or zero-byte document, which `readLease` would otherwise accept as a
|
|
199
|
+
* safe file and then fail to `JSON.parse`.
|
|
200
|
+
*
|
|
201
|
+
* `link(2)` is mandatory here and `rename(2)` is FORBIDDEN. rename overwrites
|
|
202
|
+
* its destination unconditionally, so two acquirers that both pass the
|
|
203
|
+
* (non-atomic) `readLeaseOptional` pre-check would both publish and both
|
|
204
|
+
* believe they hold the exclusive offline-reconciliation lease. link fails with
|
|
205
|
+
* EEXIST when the target exists, which is the mutual exclusion `acquireLease`
|
|
206
|
+
* converts into a blocked result. Exported solely so that contract can be
|
|
207
|
+
* asserted directly; it is not re-exported from `./index.ts`.
|
|
208
|
+
*/
|
|
209
|
+
export declare function publishExclusive(target: string, value: unknown, directory: Awaited<ReturnType<typeof open>>): Promise<void>;
|
|
210
|
+
export {};
|
|
211
|
+
//# sourceMappingURL=wakeAcceptanceReconciliation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"wakeAcceptanceReconciliation.d.ts","sourceRoot":"","sources":["../../src/runtime/wakeAcceptanceReconciliation.ts"],"names":[],"mappings":"AAEA,OAAO,EAAe,IAAI,EAA4C,MAAM,kBAAkB,CAAC;AAE/F,OAAO,EAA6E,KAAK,qBAAqB,EAAE,KAAK,6BAA6B,EAAE,MAAM,wBAAwB,CAAC;AAEnL,eAAO,MAAM,8BAA8B,EAAG,sDAA+D,CAAC;AAC9G,eAAO,MAAM,mCAAmC,EAAG,iCAA0C,CAAC;AAE9F,QAAA,MAAM,eAAe,EAAG,8DAAuE,CAAC;AAEhG,eAAO,MAAM,qCAAqC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAQxC,CAAC;AAEX,KAAK,QAAQ,GAAG,QAAQ,CAAC;IAAE,GAAG,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AACvD,KAAK,IAAI,GAAG,QAAQ,CAAC;IAAE,GAAG,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,MAAM,CAAC;IAAC,GAAG,EAAE,MAAM,CAAC;IAAC,aAAa,EAAE,MAAM,CAAC;IA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