Status: Accepted · 2026-08-20
Context
Tinycloud needs a narrow execution environment for short-lived TypeScript HTTP workers. Depending on a third-party worker platform would leave isolation, recovery, policy enforcement, and unit economics outside the product boundary.Decision
All execution goes throughRuntimeProvider: capabilities, plan,
reconcile, inspect, route, sleep, wake, destroy, logs, usage.
Resource provisioning goes through ResourceProvider. Both are semantic, not a
lowest-common-denominator wrapper over cloud APIs.
Every implementation must pass runProviderContractTests unchanged. The suite
encodes the properties the orchestrator relies on:
idempotency under a stable operation key
adoption after a lost response
atomic route switching
a destroy receipt that names anything it could not remove
Consequences
- Provider-specific features are only reachable through
x-providerescape hatches, which are disabled by default and make portability status visible. capabilities()pluscheckCompatibilityreject an incompatible manifest before any artifact upload or provider mutation.- The Firecracker implementation runs through the same provider contract suite using an injected fake backend without requiring KVM in unit tests; Linux integration tests validate the privileged backend separately.