pub fn new(db_url: &str) -> Result<SqliteMiddleware, Box<Error>> {
        let manager = SqliteConnectionManager::file(db_url);
        let pool = Pool::builder().build(manager)?;
        Ok(SqliteMiddleware { pool })
    }
/// Create middleware using defaults
///
/// The middleware will be setup with the r2d2 defaults.
Create middleware using defaults
The middleware will be setup with the r2d2 defaults.
Create middleware using defaults The middleware will be setup with the r2d2 defaults .
pub fn new(db_url: &str) -> Result<SqliteMiddleware, Box<Error>> {
        let manager = SqliteConnectionManager::file(db_url);
        let pool = Pool::builder().build(manager)?;
        Ok(SqliteMiddleware { pool })
    }
pub fn new ( db_url : & str ) -> Result < SqliteMiddleware , Box < Error > > { let manager = SqliteConnectionManager :: file ( db_url ) ; let pool = Pool :: builder ( ) . build ( manager ) ? ; Ok ( SqliteMiddleware { pool } ) }
Create middleware using defaults
The middleware will be setup with the r2d2 defaults.
Create middleware using defaults The middleware will be setup with the r2d2 defaults .
db_url
&str
db_url
&str