airflow.providers.common.ai.managed_agents.failover

Attributes

log

Classes

FailoverManagedAgentClient

Active/passive failover across interchangeable managed agents.

Module Contents

airflow.providers.common.ai.managed_agents.failover.log[source]
class airflow.providers.common.ai.managed_agents.failover.FailoverManagedAgentClient(members, *, failover_on=(Exception,))[source]

Active/passive failover across interchangeable managed agents.

Members are tried in order and the first answer wins. The group is itself a ManagedAgentClient, so a toolset built over it presents a single tool and the calling model has no say in which provider serves the request: the policy stays deterministic Python rather than a prompt instruction a model may ignore. Groups nest.

Members must be substitutable: the same agent deployed twice, not two specialists over different data. Two containerized agents built from one image qualify; an agent bound to one platform’s own objects does not, because there is nothing equivalent to fail over to. The group cannot check this.

What it can check is conversation state. A failover starts a fresh conversation on the standby, which is correct for a one-shot consultation and wrong for a multi-turn one, so the group never reports capabilities.sessions and refuses a request that carries a session_id, whatever its members support.

Parameters:
property members: tuple[airflow.providers.common.ai.managed_agents.base.ManagedAgentClient, ...][source]
property ref: airflow.providers.common.ai.managed_agents.base.ManagedAgentRef[source]
property capabilities: airflow.providers.common.ai.managed_agents.base.ManagedAgentCapabilities[source]

The intersection of the members’, except sessions, which a group never offers.

invoke(request)[source]

Was this entry helpful?