#[non_exhaustive]pub enum DynamicError {
UnsupportedType {
column: String,
type_str: String,
},
EncodingError {
column: String,
message: String,
},
SchemaMismatch {
table: String,
message: String,
},
SchemaFetch {
table: String,
source: Error,
},
EmptySchema {
table: String,
},
}Available on crate feature
dynamic only.Expand description
Errors specific to dynamic schema-driven inserts.
#[non_exhaustive]: a caller matching on this must carry a _ arm. The
variants stay constructible so a consumer can build one in its own tests.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
UnsupportedType
Column type string could not be parsed.
Fields
EncodingError
Value could not be encoded for the target column type.
Fields
SchemaMismatch
Schema mismatch detected – server rejected the insert. Retriable once the cached schema is invalidated.
SchemaFetch
Schema fetch from system.columns failed. Retriable: a cold cache
after a restart hits this on a transport blip.
Fields
EmptySchema
Table has no columns (or does not exist). Retriable against a cluster that is still replicating the DDL.
Trait Implementations§
Source§impl Debug for DynamicError
impl Debug for DynamicError
Source§impl Display for DynamicError
impl Display for DynamicError
Source§impl Error for DynamicError
impl Error for DynamicError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl From<DynamicError> for Error
impl From<DynamicError> for Error
Source§fn from(source: DynamicError) -> Self
fn from(source: DynamicError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl !RefUnwindSafe for DynamicError
impl !UnwindSafe for DynamicError
impl Freeze for DynamicError
impl Send for DynamicError
impl Sync for DynamicError
impl Unpin for DynamicError
impl UnsafeUnpin for DynamicError
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