rs-zero 0.1.1

Rust-first microservice framework inspired by go-zero engineering practices
Documentation
use thiserror::Error;

/// Redis adapter result type.
pub type RedisCacheResult<T> = Result<T, RedisCacheError>;

/// Redis adapter errors.
#[derive(Debug, Error)]
pub enum RedisCacheError {
    /// Redis URL is not usable.
    #[error("invalid redis url `{url}`")]
    InvalidUrl {
        /// Redis URL.
        url: String,
    },

    /// Redis backend returned an error.
    #[error("redis backend error: {0}")]
    Backend(String),
}