pub enum Response {
Show 14 variants
Hello {
protocol_version: u32,
kind: Kind,
name: String,
version: String,
capabilities: Vec<String>,
provides: Vec<PluginId>,
},
VersionMismatch {
min_version: u32,
max_version: u32,
},
Describe {
connection_fields: Vec<ConnectionField>,
option_fields: Vec<OptionField>,
identifier_quote: Option<String>,
message_limit: Option<u64>,
},
Validated {
errors: Vec<String>,
warnings: Vec<String>,
},
Ok {},
Result {
columns: Vec<String>,
},
ResultEnd {
rows: u64,
},
NoResult {
rows_affected: Option<u64>,
},
Written {
files: Vec<String>,
warnings: Vec<String>,
},
Delivered {
location: String,
attempts: Option<u32>,
},
Loaded {
relation: String,
rows: u64,
warning: Option<String>,
},
Error {
message: String,
kind: Option<String>,
code: Option<String>,
},
Log {
level: LogLevel,
message: String,
fields: Map<String, Value>,
},
Progress {
message: Option<String>,
done: Option<u64>,
total: Option<u64>,
},
}Expand description
Plugin → core.
Variants§
Hello
Fields
VersionMismatch
Describe
Fields
connection_fields: Vec<ConnectionField>option_fields: Vec<OptionField>Validated
Every problem with the options, each a sentence naming the key; empty when they’re fine.
Fields
Ok
Result
A result set follows as Arrow frames, ended by result_end.
ResultEnd
NoResult
Written
Fields
Delivered
Fields
Loaded
relation is what SQL uses to read the loaded rows. warning, when set, is shown to the
user (e.g. the database has no bulk path, so a load this size is slow).
Error
The request failed. kind is one of ERROR_KINDS; code names the problem,
namespaced by the plugin (sftp/host-key-mismatch). Both are optional (protocol 0 has
neither): without a code, core reports the failure under its own code for the step;
a code without a kind counts as internal.
Log
Protocol 1: a log line, while a request runs (with its id) or between requests.
Fields
Progress
Protocol 1, optional: how far a long request has got. Core shows it when present.