Skip to content

v0.2.2 — Async Gateway Task Cache

Choose a tag to compare

@Alexli18 Alexli18 released this 05 Apr 14:06
· 3 commits to master since this release

What's New

Async Gateway Task Cache

The King MCP gateway now handles dispatch_task, get_task_status, and abort_task without blocking:

  • dispatch_task returns immediately with a gt-* task ID — no waiting for vassal response
  • get_task_status reads from local SQLite cache — no round-trip to vassal for completed tasks
  • abort_task updates status immediately — async best-effort cancel delivered to vassal
  • Background reconciler polls active tasks every 10s to keep status fresh
  • Backward compatible: t-* vassal task IDs still proxied directly

Bug Fixes

  • Vassal process leak: kills existing process before launching new one on daemon restart
  • Empty task output: switched Claude CLI to --output-format json with proper fallbacks
  • Hung log spam: hang detection fires once per idle period (not every 5 min), disabled by default for shell vassals
  • kingctl report-done: added --king-dir flag + auto-discovery by walking directory tree
  • register_artifact FK error: correctly resolves producer vassal name → UUID
  • Shell vassal visibility in attach mode: RPC PTY proxy with retry logic
  • king-vassal stdio mode: --stdio flag for direct MCP over stdin/stdout (no socket)

SQLite Migration

Migration v3 runs automatically on king up — adds gateway_tasks table.