Struct l337_redis::RedisConnectionManager
source · pub struct RedisConnectionManager { /* private fields */ }
Expand description
A ManageConnection
for RedisConnections
s.
Implementations§
source§impl RedisConnectionManager
impl RedisConnectionManager
sourcepub fn new(
params: impl IntoConnectionInfo
) -> Result<RedisConnectionManager, RedisError>
pub fn new( params: impl IntoConnectionInfo ) -> Result<RedisConnectionManager, RedisError>
Create a new RedisConnectionManager
.
Trait Implementations§
source§impl Debug for RedisConnectionManager
impl Debug for RedisConnectionManager
source§impl ManageConnection for RedisConnectionManager
impl ManageConnection for RedisConnectionManager
§type Connection = AsyncConnection
type Connection = AsyncConnection
The connection type this manager deals with.
§type Error = RedisError
type Error = RedisError
The error type returned by
Connection
s.source§fn connect<'life0, 'async_trait>(
&'life0 self
) -> Pin<Box<dyn Future<Output = Result<Self::Connection, Error<Self::Error>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn connect<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Self::Connection, Error<Self::Error>>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait,
Attempts to create a new connection. Read more
source§fn is_valid<'life0, 'life1, 'async_trait>(
&'life0 self,
conn: &'life1 mut Self::Connection
) -> Pin<Box<dyn Future<Output = Result<(), Error<Self::Error>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn is_valid<'life0, 'life1, 'async_trait>( &'life0 self, conn: &'life1 mut Self::Connection ) -> Pin<Box<dyn Future<Output = Result<(), Error<Self::Error>>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,
Determines if the connection is still connected to the database. Read more
source§fn has_broken(&self, conn: &mut Self::Connection) -> bool
fn has_broken(&self, conn: &mut Self::Connection) -> bool
Quick check to determine if the connection has broken