anzar-shared 0.9.21

Anzar is a lightweight authentication and authorization framework that runs as a separate microservice
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use crate::error::CoreError;

pub struct MemCache {}
impl MemCache {
    pub async fn start(conn: &str) -> Result<memcache::Client, CoreError> {
        let db = memcache::connect(conn).inspect_err(|e| {
            tracing::error!(
                error_code = "InternalError::Database",
                "Failed to connect to database - {e}"
            );
        })?;

        Ok(db)
    }
}