1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
/*
* Hanzo Cloud API
*
* The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
*
* The version of the OpenAPI document: v1
*
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct Fusion {
/// Backends is the per-leg report. Always populated.
#[serde(rename = "backends", skip_serializing_if = "Option::is_none")]
pub backends: Option<Vec<models::BackendStatus>>,
/// Hits is the fused, ranked result set.
#[serde(rename = "hits", skip_serializing_if = "Option::is_none")]
pub hits: Option<Vec<models::Hit>>,
/// Mode is the mode actually used after `auto` resolution.
#[serde(rename = "mode", skip_serializing_if = "Option::is_none")]
pub mode: Option<String>,
/// Status is the query's overall honesty signal: ok every consulted leg answered. partial at least one leg failed; Hits holds the survivors' results. unavailable every consulted leg failed; Hits is empty AND that is stated.
#[serde(rename = "status", skip_serializing_if = "Option::is_none")]
pub status: Option<String>,
/// TookMS is the whole query's wall time in milliseconds — every leg it consulted, plus fusion and paging. Each leg's own share is in Backends[].TookMS; the legs run in sequence, so this is at least their sum.
#[serde(rename = "took_ms", skip_serializing_if = "Option::is_none")]
pub took_ms: Option<i32>,
}
impl Fusion {
pub fn new() -> Fusion {
Fusion {
backends: None,
hits: None,
mode: None,
status: None,
took_ms: None,
}
}
}