pub struct ProxyStatus {
pub strategy: RoutingStrategy,
pub fallback_on_error: bool,
pub total_tools: usize,
pub routable_locally: Vec<String>,
pub remote_only: Vec<String>,
pub local_only: Vec<String>,
pub incompatible: Vec<IncompatibleTool>,
pub override_rules: Vec<(String, RoutingStrategy)>,
}Expand description
Human-friendly summary of the current routing state. Used by the proxy status CLI
command and any dashboard that wants to inspect how the proxy is configured.
Fields§
§strategy: RoutingStrategy§fallback_on_error: bool§total_tools: usize§routable_locally: Vec<String>§remote_only: Vec<String>§local_only: Vec<String>§incompatible: Vec<IncompatibleTool>§override_rules: Vec<(String, RoutingStrategy)>Implementations§
Source§impl ProxyStatus
impl ProxyStatus
Sourcepub fn from_engine(engine: &RoutingEngine) -> Self
pub fn from_engine(engine: &RoutingEngine) -> Self
Compute a status snapshot from the engine’s current config + match report.
Sourcepub fn to_text_report(&self) -> String
pub fn to_text_report(&self) -> String
Render a plain-text report suitable for CLI output.
The strategy is formatted via routing_strategy_slug (kebab-case),
consistently with to_json() and TOML serialization — the user sees the same
spelling in every output format.
Sourcepub fn to_json(&self) -> Value
pub fn to_json(&self) -> Value
JSON form — convenient for machine-readable CLI output (--json flag).
Strategy values are serialized in the same kebab-case form as in the TOML
config (local-first, not LocalFirst); otherwise proxy status --json | jq
clients would have to deal with two spellings of the same value.
Trait Implementations§
Source§impl Clone for ProxyStatus
impl Clone for ProxyStatus
Source§fn clone(&self) -> ProxyStatus
fn clone(&self) -> ProxyStatus
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ProxyStatus
impl RefUnwindSafe for ProxyStatus
impl Send for ProxyStatus
impl Sync for ProxyStatus
impl Unpin for ProxyStatus
impl UnsafeUnpin for ProxyStatus
impl UnwindSafe for ProxyStatus
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more