kdb-connection 0.1.0

kDB connection.
Documentation
use std::convert::Infallible;

#[derive(thiserror::Error, Debug)]
pub enum Error
{
    // #[error("The remote service failed.")]
    // ServiceFailed(String),
    // #[error("Received an invalid message.")]
    // InvalidMessage(String),
    // #[error("Failed to parse a message.")]
    // MessageParseError(String),
    // #[error("An error occured when parsing bytes as Utf-8.")]
    // Utf8Error(String),
    // #[error("Future was cancelled.")]
    // CancelledFuture(String),
    #[error("Cannot cast {type_name} to {value}")]
    InvalidValueCast
    {
        type_name: &'static str,
        value: String,
    },
    #[error("IOError {0}")]
    StdIO(#[from] std::io::Error),
    #[error("Serialization error: {0}")]
    JsonSerialization(#[from] serde_json::Error),
    #[error("Serialization error: {0}")]
    YamlSerialization(#[from] serde_saphyr::ser::Error),
    // #[error("Serialization error: {0}")]
    // CborSerializationError(#[from] ciborium::ser::Error<std::io::Error>),
    #[cfg(feature = "mqtt")]
    #[error("An error occured in the MQTT Service middleware: {0}.")]
    MqttService(#[from] mqtt_service::Error),
    #[cfg(feature = "http")]
    #[error("An error occured during an HTTP Service request: {0}.")]
    HttpService(#[from] reqwest::Error),
    // #[error("Execution of the query failed with given error.")]
    // QueryExecutionFailed(String),
    #[error("UnsupportedNumber")]
    UnsupportedNumber,
    #[error("Infallible")]
    Infallible(#[from] Infallible),
}