Skip to main content

Module bus

Module bus 

Source
Expand description

Central in-process agent message bus

Provides a broadcast-based pub/sub bus that all local agents (sub-agents, workers, the A2A server) can plug into. Remote agents talk to the bus through the gRPC / JSON-RPC bridge; local agents get zero-copy clones via BusHandle.

§Topic routing

Every envelope carries a topic string that follows a hierarchical scheme:

PatternSemantics
agent.{id}Messages to a specific agent
agent.{id}.eventsEvents from a specific agent
task.{id}All updates for a task
swarm.{id}Swarm-level coordination
broadcastGlobal announcements
tools.{name}Tool-specific channels

Modules§

registry
Agent registry — tracks connected agents and their cards.
relay
Protocol-first relay runtime for multi-agent handoff flows.

Structs§

AgentBus
The central in-process message bus.
BusEnvelope
Metadata wrapper for every message that travels through the bus.
BusHandle
A scoped handle that a single agent uses to send and receive messages.

Enums§

BusMessage
The set of messages the bus can carry.