Dashboard › opencode › Distillation
b927eae9-ff12-434a-b445-f3b68264c92a["lore_tm_v1_ztgXCtc1vIgbliPa2CENbt_PIpK7vJ8sUQXneWIAA3o","lore_tm_v1_wH9Q1TNCLthbEgpItDa7NinupPmS_Wn5ZCsFDWcpJS4","lore_tm_v1_V0m6qB6ljXeQXfp8F83qbAD1znxOIwa4-86idhEzKpo","lore_tm_v1_IxlMru7WQVbBURKZVqk7iVGOmcPsJsb-KDPezF8A7Sw","lore_tm_v1_NwQ-1YAWPi7xv8b4kinV8algyV_2vYq99S5EErpT-us","lore_tm_v1_-aea34Ng4rQUDTFBineRsrwq19Ids3EZofa5K68aTSM"]
Date: Sep 17, 2026
packages/server/src/routes.ts adds SessionRecovery to applicationServices alongside SessionV2; AppNodeBuilder.build(applicationServices, [[SessionExecution.node, SessionExecutionLocal.node]]) substitutes local session execution. createRoutes(password?) uses username "opencode" with the supplied password or ServerAuth.Config.layer; createEmbeddedRoutes() uses username "opencode" with Option.none(). The API exposes OpenAPI at /openapi.json, and webHandler() disables logging./doc route is loaded lazily so processes that “never serve it (CLI, scripts) don't pay at module load.”SessionRecovery and build LayerNode.group([SessionV2.node, SessionRecovery.node]), integrating recovery into the server’s session service layer.interrupt(key) to interrupt(key, cleanup = Effect.void). If no active owner exists it runs cleanup; concurrent interruption callers share entry.interruption; interruption marks stopping = true and clears pendingWake, interrupts the owner, captures the cleanup exit, requires the execution to have settled, then either deletes the active entry or creates and starts a successor when a wake became pending. It completes entry.done with the settled exit, propagates cleanup failure, runs uninterruptibly, and resolves the interruption deferred on exit.packages/core/src/database/schema.gen.ts reflects the recovery migration in the generated full-schema initializer, including session_execution, session_recovery, session_input.wake_pending, session.wake_attempts, their foreign keys/check constraints, and all associated recovery and wake-scanning indexes.