Spokes.wiki Search About
Blog Posting source ↗ source url updated Mon Jun 01 2026 00:00:00 GMT+0000 (Coordinated Universal Time)

Build Long-running AI Agents that Pause, Resume, and Never Lose Context with ADK

Google Developers Blog on using adk to build durable-agents — turning agents from stateless chatbots into production background processes that run for days/weeks, pause, and resume without losing context. The key move: separate workflow state from conversation history.

Mechanisms

  • Durable state machines — explicit state schemas with named checkpoints; “the agent can’t skip a step or hallucinate progress because the state machine enforces the sequence.” Current state vars are injected into the prompt so the model always knows its position.
  • Persistent session storage — ADK’s DatabaseSessionService backs sessions with SQLite (local) / Cloud SQL (prod); every tool call durably writes state, so a crash mid-workflow resumes from the right checkpoint.
  • Event-driven resumption — webhooks fire state_delta transitions that wake dormant agents; run_async atomically applies the transition before the next inference (no polling/blocked threads).
  • Multi-agent delegation — focused sub-agents prevent prompt bloat over long workflows (agent-orchestration).

Why it belongs here

The deepest treatment so far of agent durability — the durable-agents concept. Use cases: HR onboarding (weeks), invoice disputes (days), sales sequences — all human-in-the-loop with long idle gaps. Extends adk beyond skills (adk-agents-with-skills) into stateful, resumable execution; the durable counterpart to the self-driven heartbeat model in claude-code-channels-vs-openclaw. (Caveat: vendor tutorial.)

durable-agents · adk · google · agent-orchestration · adk-agents-with-skills