c6b0e3a80e
Phase 2 (production features): - SSE streaming: message/stream endpoint with proper event formatting (submitted → working → completed → done), keepalive pings - Push notifications: HMAC-SHA256 signed webhooks via tasks/pushNotification/set, auto-fired on task completion - Rate limiting: token-bucket per peer (A2A_RATE_LIMIT, default 60/min) - Metrics: /metrics endpoint with counters, latency tracking, uptime - Orphaned task watchdog: background thread cleans stale tasks (>300s) Phase 3 (OpenClaw patterns): - Anti-loop ping-pong: per-context turn counter with configurable max (A2A_MAX_PINGPONG_TURNS, default 5, max 20) - Async durable messaging: pending task registry with register/ complete/orphaned/clear lifecycle - Capability-based routing: a2a_orchestrate tool with fan-out modes (all/first/best), matches peers by capabilities in config - Dynamic Agent Cards: skills_from_real_toolsets() builds skill cards from actual toolset registry, not just names - Trusted-peer approval (#56434): A2A_TRUSTED_PEERS env/config, is_trusted_peer() gate in inbound handler - Task completion notifications (#56435): build_task includes status.message + artifacts for completed/failed states Agent Card version bumped to 0.2.0, capabilities now advertise streaming=True and pushNotifications=True. Tests: 81 passed (45 existing + 36 new), 0 failed.