Repository navigation
feat(den): run Cloud instances through the runtime contract with Daytona as an adapter - #4445
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
@OmarMcAdam Please review the Cloud lifecycle orchestration and provider configuration alias in this stack. Live lifecycle journey proof is explicitly incomplete. Keep the dependency on #4444 until it is reviewed and merged. Holding for your review under the current merge instructions. |
b4dde7f to
778acbd
Compare
4a24ba4 to
58f2312
Compare
778acbd to
a79ef27
Compare
a79ef27 to
2e51daa
Compare
2e51daa to
e93e332
Compare
There was a problem hiding this comment.
Warden security clearance: clear. No blocking findings (security or desktop↔den sync) in this diff (3dcfcfbfb8a252e4a7a10b745ea99308de8823bc). Automated clearance satisfies the required-review gate only — a human still reviews and merges. Analysis run
…ona as an adapter Move Den's Cloud lifecycle policy (provision, adopt on conflict, wake, version-aware recycle, idle stop, checkpoint flush, deprovision) into a provider-neutral orchestrator in @openwork-ee/cloud-runtime, driven only by the SandboxProvider contract and a RuntimeInstanceStore. The former Daytona module becomes @openwork-ee/cloud-runtime-daytona: SDK calls, state and error mapping, signed preview endpoints, session exec, shared-volume storage, and the short-lived probe and cleanup helpers. Den's lifecycle, access resolver, cloud routes, automation executor, and remote-session gate now ask the runtime registry whether a provider is configured instead of comparing the provisioner name, and startup failures classify from typed error codes before falling back to message text. CLOUD_RUNTIME_PROVIDER names the host; PROVISIONER_MODE remains an alias. The Daytona SDK is a dependency of the adapter package only. Instance records keep their current table; the record type read by Den is already neutral (endpointUrl, endpointExpiresAt, opaque sandbox reference). The provisioning, wake-convergence, recycle, and name-lookup scenarios move from the Daytona test file to the orchestrator suite against the in-memory fake provider; the adapter carries its own mapping tests; the lifecycle tests drive a real orchestrator over the fake host.
Capture checkpoint probe and cleanup command outcomes while the helper toolbox still exists. Make the existing provider fixture reject result reads after deletion.
Cover same-worker wake, endpoint refresh, failed restore preservation, and version recycle with an unaffected second member. Use a stateful SDK HTTP witness with ambient assertions, not Linux bootstrap execution. Local Den proof remains incomplete: MySQL refuses connections, Docker storage is read-only, and Redis rejects writes. Provider regression tests and direct SDK HTTP lifecycle smoke pass; rerun the Den journey after local services recover.
Keep bootstrap credentials out of command arguments, match legacy names only within owner-scoped results, and preserve desktop dispatch without Cloud hosting. Align the covering fixtures and their verification claims with these boundaries.
There was a problem hiding this comment.
Warden security clearance: clear. No blocking findings (security or desktop↔den sync) in this diff (83b0d755c283acd8317b847b793c201d036a299f). Automated clearance satisfies the required-review gate only — a human still reviews and merges. Analysis run
Merge status
Merged into
devon September 14 asf2fb0c861140022d9c6d7ed928416b500e8e82f0, after current-head Warden approval of83b0d755c283acd8317b847b793c201d036a299fand passing required, API, SDK and database CI checks. The explicitly deferred full Cloud lifecycle integration run below remains unclaimed. #4446 is the remaining neutral-storage layer.Summary
Part 2 of the Cloud runtime provider stack: Daytona implements
SandboxProvider, while provisioning, adoption, wake, checkpoint/recycle, idle-stop and deletion policy live in the provider-neutral orchestrator. Existing configuration aliases, ownership checks, bounded caching and recovery behavior remain supported.September 14 review fixes
Head:
83b0d755c283acd8317b847b793c201d036a299f.Base:
dev@d3e5f28aa325d363ee5be7283f542199ac410258.The runtime/privacy fixes were approved at
3dcfcfbfb; that clearance is historical after this CI refresh. The current head additionally refreshes generated Gateway request-count SDK fields and fixes existing migration-history tests so valid migrations after 0097 remain pending rather than failing an end-of-history assumption. No production authentication behavior, CI workflow or checker policy was changed for generation; fresh current-head CI and review remain authoritative.session.list_sessionsaction.The three inline review conversations have specific commit/test replies and are resolved. Fresh review clearance and repository approval remain separate from resolving those conversations.
Verification
Verdict: Incomplete for the full Cloud lifecycle journey. Scoped checks below passed; missing integration execution is not represented as a pass.
Passed on this head:
Commands:
Deferred / known limits:
remote-session-first-use.test.tsjourney, actual connected-desktop delivery and live Web/VM canary were not run. Local MySQL/Redis remain unavailable; no replacement services or paid sandbox were started. Previous journey receipts apply only to their recorded heads.dev@6ef027216; no layer/checker policy was weakened. A separate inherited environment-fixture type error was reproduced on that clean control and fixed without changing values or assertions.Stack
#4444 is merged. This PR targets
dev; #4446 remains stacked on this branch. Merge this layer first, then rebase/retarget #4446 to freshdevand refresh its checks.UI/UX impact
No layout, icon, color or navigation changes. Authorized desktop handoffs remain discoverable on deployments without Cloud hosting; unsupported Cloud targets receive a Cloud-specific error. Existing Cloud worker naming and endpoint behavior are retained. Launch failure diagnostics are sanitized rather than exposing provider request contents.
Risk and rollback
This is a substantial lifecycle extraction. The integration gap remains explicit. Reverting this PR restores the direct Daytona path without a schema migration; legacy
PROVISIONER_MODEremains accepted. A new production hosting adapter is outside this PR.