#[non_exhaustive]pub struct Response {
pub request_id: String,
pub status: String,
pub kind: String,
pub data: Value,
pub route: Option<String>,
pub elapsed_ms: Option<i64>,
pub warnings: Vec<String>,
pub error_code: Option<String>,
pub leader_hint: Option<String>,
}Expand description
A decoded RESPONSE frame.
Response::data is the payload of whichever variant the operation
produced, and Response::kind names that variant — "Json",
"CacheValue", "Rows", "Documents", "Message", "Toon" or
"Empty". The typed methods on crate::Client decode this for you; it is
public so an operation this crate has no method for is still reachable
through crate::Client::request.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.request_id: StringThe request_id the server echoed back.
status: StringThe server’s status. "ok" on success; any other value is reported as
an error rather than returned.
kind: StringThe name of the data variant, or an empty string when there was no data.
data: ValueThat variant’s payload, still as JSON.
route: Option<String>Which route served the request.
elapsed_ms: Option<i64>How long the server took.
warnings: Vec<String>Non-fatal warnings. Not decorative: a broadcast DDL that could not reach
every shard reports it here while the status is still "ok".
error_code: Option<String>The server’s machine-readable failure code, when it failed.
leader_hint: Option<String>On a not_leader refusal, the leader’s host:port when the cluster
knows one.