Skip to main content

build_graph_node_handler

Function build_graph_node_handler 

Source
pub async fn build_graph_node_handler(
    graphs: HashMap<String, GraphConfig>,
    audit_sink: Option<AuditSink>,
) -> Option<Arc<dyn GraphNodeHandler>>
Expand description

Build the production DwAgentGraph handler if the environment is configured. Mirrors super::super::agent_node::build_agent_node_handler: it returns None (so DwAgentGraph flow dispatch errors clearly) under any of these graceful-degradation conditions:

  • graphs is empty (no graphs from any pack sidecar);
  • GREENTIC_AW_REDIS_URL is unset/empty;
  • the AW Redis connection fails;
  • the extension runtime fails to initialise.

The shared runtime Arcs (state store, ext runtime, LLM backend, telemetry, token meter, ledger) are built exactly as for the single-agent path; the durable checkpoint store reuses the same multiplexed Redis connection manager.